我在Gatling脚本中设置socks5代理,如下所示
http("request1")
.post("https://myurl.com")
.proxy(Proxy("localhost", 7777).socks5)但在日志中,它显示为HttpProxyServer而不是Socks5ProxyServer
proxy=HttpProxyServer{realm=null, securedPort=7777, securedAddress=localhost/127.0.0.1:7777, host='localhost', port=7777}和我的请求超时
我验证了socks代理可以通过curl工作,也可以在使用-DsocksProxyHost=localhost -DsocksProxyPort=7777的jmeter中工作。
发布于 2019-08-02 07:36:59
现在修复了:https://github.com/gatling/gatling/issues/3777,谢谢斯蒂芬!
在从源代码构建Gatling之后,我现在验证了它是否有效*
我现在也可以看到正确的代理,并且请求通过
proxy=Socks5ProxyServer{realm=null, host='localhost', port=7777}*注意:要从源构建gatling,您需要构建3个项目(我希望这是文档的一部分):
1) git clone git@github.com:gatling/gatling.git
update gatling/version.sbt to e.g. 3.2.1-SNAPSHOT
cd gatling; sbt publishM2; cd ../
2) git clone git@github.com:gatling/gatling-highcharts.git
update gatling-highcharts/version.sbt to e.g. 3.2.1-SNAPSHOT
cd gatling-highcharts; sbt publishM2; cd ../
3) git clone git@github.com:gatling/gatling-highcharts-maven-archetype.git
update version in gatling-highcharts-maven-archetype/pom.xml to e.g. 3.2.1-SNAPSHOT
cd gatling-highcharts-maven-archetype; mvn clean install;
cd target/gatling-charts-highcharts-bundle-3.2.1-SNAPSHOT
bin/gatling.shhttps://stackoverflow.com/questions/57315700
复制相似问题