0
votes

I am trying to record a web application using Jmeter. I am able to record the launch of home page but facing error while logging in. I can see this error in the Network tab of chrome Dev Tools.

Error during WebSocket handshake: Unexpected response code: 400
main.js?v=1579205232764:2 WebSocket connection to 'wss://<server-ip>/study-search?authorization=<token-value>' failed: Error during WebSocket handshake: Unexpected response code: 400

Can someone please help me out?

Thanks!

1

1 Answers

0
votes

As of current JMeter version 5.2.1 JMeter cannot either capture or properly proxy the WebSocket traffic so I would recommend splitting the recording in 2 parts:

  1. Before the login (including the login)
  2. After the login (to wit: login without proxy, then turn on proxy, then continue recording)

In any case all the WebSocket calls needs to be captured separately using a 3rd-party sniffer tool like Fiddler or Wireshark and then properly simulated using JMeter WebSocket Samplers plugin