You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to do something similar to cURL local DNS: curl --resolve www.my_host.com:443:1.2.3.4 https://www.my_host.com:443/something
I.e. host www.my_host.com should be resolved by locust to 1.2.3.4.
I can do it via host header for http, but not for https with SNI...
It’s doable via local hosts entry easily.
I guess it’s doable via locust httpclient fiddling too, probably...
Is there another relatively easy way without messing up with local hosts files?
Found somewhat related already closed issues: #326#96
The text was updated successfully, but these errors were encountered:
The DNS resolution is currently out of Locust's control, and I currently don't see us changing that.
Jonatan,
I’m not talking about “full blown” DNS.
Basically, we have a dictionary {name0: IP0, name1: IP1, …}
“Local DNS” can be done easily for HTTP protocol:
HttpClient needs to connect to IP, not name and add “host: name” header.
AFAIK, it’s trickier, but possible for HTTPS still.
I think, it won’t be much Locust code changes to implement such logic.
I can try writing examples to prove, it’s doable for both HTTP and HTTPS for Python3 standard HttpClient, any advanced HttpClient should be able to handle it too.
That is if somebody willing to integrate it into Locust later.
Don’t want to waste my time otherwise.
Ah, now I think I understand what you mean. You should be able to implement that in your own test scripts pretty easily. I don't think it's a common enough use-case for us to include it in Locust itself.
Is it possible to do something similar to cURL local DNS:
curl --resolve www.my_host.com:443:1.2.3.4 https://www.my_host.com:443/something
I.e. host www.my_host.com should be resolved by locust to 1.2.3.4.
I can do it via host header for http, but not for https with SNI...
It’s doable via local hosts entry easily.
I guess it’s doable via locust httpclient fiddling too, probably...
Is there another relatively easy way without messing up with local hosts files?
Found somewhat related already closed issues: #326 #96
The text was updated successfully, but these errors were encountered: