【问题标题】:Locust, How to set source request ipLocust,如何设置源请求 ip
【发布时间】:2020-06-05 01:58:39
【问题描述】:

运行Locust的虚拟机有多个网卡

有没有办法设置Locust的源请求IP?

https://docs.locust.io/en/stable/configuration.html#command-line-options

【问题讨论】:

    标签: locust


    【解决方案1】:

    猴子修补socket.create_connection() 使用此处描述的解决方案应该是可能的,因为Locust 的HttpUser 使用requests

    Requests, bind to an ip

    我的原始答案因某种未知原因被模组删除。让我们希望它不会再次发生......

    【讨论】:

      猜你喜欢
      • 2016-09-28
      • 2016-02-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-02-27
      相关资源
      最近更新 更多