A first I recorded the traffic in fiddler and tried to login where all samplers were http request sampler, but as it wasn't. But it was something like this in view results tree
http request 3 : {"negotiateVersion":1,"connectionId":"NRb_1qElNVM4HbeHirpOvQ","connectionToken":"X8NRLicmYXHs7bV9mWsqRA","availableTransports":[{"transport":"WebSockets","transferFormats":["Text","Binary"]},{"transport":"ServerSentEvents","transferFormats":["Text"]},{"transport":"LongPolling","transferFormats":["Text","Binary"]}]}
http request 4 : Cannot change transports mid-connection
and this is the path of http request 4
"/_blazor?id=Mwb6bAF5K79ifIuhLGNDWQ"
As you can see in path there is an ID to correlate, But in the response of http request 3 there is no ID, one "Connectionid" and one "connectiontoken", so with which value I will correlate?
However, this is the header manager of HTTP request 4:
Pragma no-cache Cache-Control no-cache User-Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36 Accept-Language en-US,en "Upgrade: websocket" Origin http://172.16.22.62:7010 Sec-WebSocket-Version 13 Accept-Encoding gzip, deflate "Sec-WebSocket-Key: lXf82G8p9tSCTH6FqB9LyA==" Sec-WebSocket-Extensions permessage-deflate; client_max_window_bits
As you can see there are upgrade : websocket
I have installed websocket sampler by "peter Dornboosh". Although but as you realize It's not quite clear to me which websocket sampler I should use? And should I just replace HTTP request 4 with websocket sampler or all HTTP request needed to be replaced. One other thing is, if I use websocket sampler do I have to co-rrelate?
I am trying to load test "Login". Thank you all
My expectation is that you need to use:
Make sure that:
You can use the same Fiddler to compare the network footprint of JMeter and the real browser, you can set Fiddler as the proxy for JMeter and Fiddler will capture JMeter's requests, once JMeter will start sending the same requests - your login will be successful.