views:

136

answers:

1

I've just started using jMeter and the plan is to do some load testing. I have the GUI effectively logging into the site for one user. One of the params sent back on the login post action is a value for creationTime that is set on form creation.

The problem is that our app checks against the last login time and refuses you if the time on the form is earlier than the last login time. This is preventing me from hardcoding the creationTime in the jMeter HTTP Request Parameters box.

Since the object is to test the login scalability, not the ability to run through 200 users logging in and out of the system quickly, I need to figure out a way to have a bunch of users. Would I make a login group for each user? What are the strategies I could try to accomplish this?

+2  A: 

Having had to conquer similar problems dozens of times, I have a few solutions to offer:

  1. What happens if you give creationTime a blank value on the post?
  2. If a value is required, send the current time stamp: http://jakarta.apache.org/jmeter/usermanual/functions.html#__time
  3. If a system provided token is required, split your request into the following:
Step 1: GET the login page (no parameters are required)
Step 2: As a post processor of Step 1, use a REGEX to extract the token (creationTime)
Step 3: POST the login page, using the value from the REGEX

4. Use a hardcoded value for creationTime that is a year in the future.

BlackGaff