简体   繁体   中英

Jmeter - Multiple user's session details retrieved incorrectly under "View results tree" listener

Scenario :

4 threads with different usernames and passwords to be used in jmeter to run concurrently to perform the following operations.

  • Login to the application
  • Proceed to chats module and send a msg to any user present in the chatroom.
  • Logout of the session.

I recorded the script for one user's operations using blazemeter and saved the jmx file.

Imported the jmx file into jmeter.

The multiple credentials(username,pwd) are fetched through a CSV file and variables for username and pwd have been configured in jmeter as well.

Problem is:

When I run the script successfully, Under view results tree, though the "login request" 's response body shows details of that particular user session correctly, but, all other http request's responses are fetching the recorded script user's data and session details.

I have even checked the box for clear cache and cookies too under HTTP cache and cookie manager.

Though the application asks for only "Username" and "password" details, during the subsequent operations, there are some session details that need to be dynamically generated and stored as response for that particular user session.

Ideally, For each user, session details in response body need to be belonging to that particular user's session itself. But view results tree shows the 1st users session details in the subsequent requests's response body for all other users as well.

Can anyone help me sort this out?

Looks like a typical not implemented or not properly working correlation .

Most probably there is a some form of identifier pointing to the session of the user which was doing the recording, for example:

  • session id as a part of the URL
  • a header which identifies the logged in user
  • etc.

Just record the same test scenario one more time and compare the generated .jmx scripts: all the values which will "differ" are a subject to correlation.

Also be aware that "blazemeter" is only capable of recording HTTP and HTTPS traffic so if your "chat" uses other protocols JMeter won't record it and will give you only "login" part. Check out 5 Ways to Load Test Popular Chat Plugins with JMeter article for more information

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM