Highlighted
Regular Contributor.
Regular Contributor.
492 views

I have to capture Websocket response time in my API performance test.

Hello,

 I have to capture Websocket response time in my API performance test. Please guide me how to use the socket connection and execute in the script. I have copied webscoket calls from one of the UI recorded script but that is not working. Error -26421: Failed to locate Vuser script function "OnOpenCB0", specified via the "OnOpenCB" argument  [MsgId: MERR-26421]

 

0 Likes
2 Replies
Highlighted
Frequent Contributor.
Frequent Contributor.

Hi,

Are you using HTTP protocol ?

I mean you need to specify the port on port mapping settings, standar ports are 443 and 80 .

you have to go to Recording options --- Network--- Mapping and Filtering --- set Capture level to "Socket level data", click on new entry, complete target server and Port, on service ID select webs.

After that try to record again.

0 Likes
Highlighted
Regular Contributor.
Regular Contributor.

Hello below URI, i will be getting form WebsocketCB.c whcih needs to pass on Web_websocket_connect. After live all the values are dynamic. How extract the value from websocketcb.c

web_websocket_connect("ID=1",
"URI=wss://dev.videolive1.xyz.com/live/171f29e1-51ee-e811-810b-000d3a300318_1_1_b0d9c8b9-6df0-451b-8acf-04283b08b72b",
"Origin=https://developers.xyz.com",
"OnOpenCB=OnOpenCB1",
"OnMessageCB=OnMessageCB1",
"OnErrorCB=OnErrorCB1",
"OnCloseCB=OnCloseCB1",
LAST);

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.