网站首页
编程语言
数据库
系统相关
其他分享
编程问答
FastHttpUser
2024-07-24
locust多进程实现分布式压测遇到的问题
多进程分布式的实现:locust分布式时,需借助命令locust一个一个启动worker,在使用中有点繁琐,下面借助于多进程,按既定worker数量,一键启动;fromlocustimportFastHttpUser,task,User,events,HttpUser#classWebsiteUser(FastHttpUser):错误的使用!!!classWebsiteUser(