如何更改locate中用户绑定的客户端端口
场景
我正在测试UDP服务器的性能。它是用locust
+ 自定义客户端
实现的。
当自定义客户端判断数据包丢失时,它记录了已发送的数据并将异常归为locust
。
当locust
捕获异常时,它将停止执行任务集后面的任务,跳过当前任务集,然后选择一个新任务集以执行。
如果只有一个任务集,则将当前任务集重新执行。
问题
我想替换用户绑定的套接字端口时,locust
re执行任务集。
但是,在插座绑定到端口之后,无法更改端口(我找不到可以更改的示例。)
我尝试在用户约束的任务集中绑定自定义客户端,但是我收到了一个locust
的错误。
有什么方法可以意识到我的需求吗?
还有其他观点吗?
例如:
locust
捕获异常,结束当前用户,然后启动新用户。
最后的
英语不是我的母语,请原谅我的语法错误。
感谢您的阅读!如果您可以提供帮助,那就更好了。
scene
I am testing the performance of UDP server. It is implemented with Locust
+ custom client
.
When the custom client judges the packet loss, it records the sent data and throws an exception to Locust
.
When Locust
catches the exception, it will stop executing the tasks behind the task set, skip the current task set and select a new task set for execution.
If there is only one task set, the current task set is re executed.
problem
I want to replace the socket port bound by user when Locust
re executes the task set.
However, the port cannot be changed after the socket is bound to the port (I can't find an example on Google that can be changed.)
I tried to bind a custom client in the task set bound by user, but I received an error from Locust
.
Is there any way to realize my demand?
Are there any other perspectives?
For example:
- After
Locust
catches an exception, end the current user, and then start a new user.
last
English is not my native language, please forgive my grammar mistakes.
Thanks for reading! It would be better if you could help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论