question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

FastHttpLocust + SNI

See original GitHub issue

Getting weird issue with FastHttpLocust again. It works fine from client. But server (OpenResty) has SNI based bindings and show tons of errors like … failed to get SNI … and falls back to default certificate. 😦

Same exact code works fine with HttpLocust. Don’t know how to help somebody to reproduce…

Am I missing something (simple?) with FastHttpLocust? AFAIR, it’s up to the https client to send SNI or not, right?

url = f'{https}://{host}{url}'
headers = {
	'Host': host,
}
self.client.get(url, name=url, headers=headers)
(locust382) ubuntu@...:~$ conda list
# packages in environment at /home/ubuntu/anaconda3/envs/locust382:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
ca-certificates           2020.1.1                      0  
certifi                   2020.4.5.1               py38_0  
chardet                   3.0.4                    pypi_0    pypi
click                     7.1.1                    pypi_0    pypi
configargparse            1.2.1                    pypi_0    pypi
flask                     1.1.2                    pypi_0    pypi
flask-basicauth           0.2.0                    pypi_0    pypi
gevent                    1.5.0                    pypi_0    pypi
geventhttpclient-wheels   1.3.1.dev3               pypi_0    pypi
greenlet                  0.4.15                   pypi_0    pypi
idna                      2.9                      pypi_0    pypi
itsdangerous              1.1.0                    pypi_0    pypi
jinja2                    2.11.2                   pypi_0    pypi
ld_impl_linux-64          2.33.1               h53a641e_7  
libedit                   3.1.20181209         hc058e9b_0  
libffi                    3.2.1                hd88cf55_4  
libgcc-ng                 9.1.0                hdf63c60_0  
libstdcxx-ng              9.1.0                hdf63c60_0  
locustio                  1.0.0                     dev_0    <develop>
markupsafe                1.1.1                    pypi_0    pypi
msgpack                   1.0.0                    pypi_0    pypi
ncurses                   6.2                  he6710b0_0  
openssl                   1.1.1g               h7b6447c_0  
pip                       20.0.2                   py38_1  
psutil                    5.7.0                    pypi_0    pypi
python                    3.8.2                hcf32534_0  
pyzmq                     19.0.0                   pypi_0    pypi
readline                  8.0                  h7b6447c_0  
requests                  2.23.0                   pypi_0    pypi
setuptools                46.1.3                   py38_0  
six                       1.14.0                   pypi_0    pypi
sqlite                    3.31.1               h62c20be_1  
tk                        8.6.8                hbc83047_0  
urllib3                   1.25.9                   pypi_0    pypi
werkzeug                  1.0.1                    pypi_0    pypi
wheel                     0.34.2                   py38_0  
xz                        5.2.5                h7b6447c_0  
zlib                      1.2.11               h7b6447c_3  

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
heymancommented, May 13, 2020

HttpLocust has been renamed to HttpUser (and the Locust class has been renamed to User) in 1.0.

For all backwards incompatible changes see: https://docs.locust.io/en/latest/changelog.html

I’m fairly hopeful that your SNI problem should go away if you switch to 1.0.

0reactions
ecc256commented, May 18, 2020

Tested Locust 1.0.1 No more SNI with FastHttpUser! Thanks a lot!

Read more comments on GitHub >

github_iconTop Results From Across the Web

FastHttpUser doesn't use the SNI TLS extension #1360 - GitHub
The FastHttpUser client send the SNI extension as host , and the TLS ... from locust import task, between from locust.contrib.fasthttp ...
Read more >
Increase performance with a faster HTTP client
Send and HTTP request Returns locust.contrib.fasthttp.FastResponse object. Parameters. method – method for the new Request object.
Read more >
https://raw.githubusercontent.com/locustio/locust/...
[2.13.0](https://github.com/locustio/locust/tree/2.13.0) (2022-10-28) [Full ... Bump default concurrency for fast http user to 10 ...
Read more >
2014-October.txt - Python mailing list
I'm trying to use locust (http://locust.io/) to run load test of one site we're ... SNI is not officially supported in python 2.7.5...
Read more >
Run A Custom Code With Locust Performance Testing ...
If you specify `-f` with a Python locustfile, it will be the same as `locust`, while if you 1.5.5 ... Send and HTTP...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found