tags:

views:

72

answers:

1

I am using JMeter to do some load testing on a SOAP webservice. Currently I am running 5 servers. I would like to distinguish the requests based on which server the request came from. An easy way to do this would be to stick some unique identifier into the email address field for a register request. I was hoping to use hostname or ip address like so [email protected] / [email protected]

Then, as my database is populated on the server being tested, I can see which of the servers have hit the service.

Any idea what the best solution would be?

I have already added a User Paramaters pre-processor, however that only applies to individual threads, not individual servers.

Thanks.

EDIT

@ar: Where can I find a reference to those built-ins? Also, any idea how I would do something like this for a user paramater:

Name:         User_1:
emailPrefix   ${__Random(1, 100000, emailPrefix)}
email         ${__machineName}_${emailPrefix}_${counter}@domain.com

I want to set email so I can use it in a bunch of different reuqests like ${email}. Right now it just ends up being myMachineName_${emailPrefx}_{$counter}@domain.com rather than doing the replacement.

EDIT 2

I found the reference.

I got the second part of my question. I just used this

Name:         User_1:
email         ${__machineName}_${__Random(1, 100000)}_${counter}@domain.com
+1  A: 

You can use ${__machineName} in your script. This will get replaced by JMeter with the hostname of the machine it is running on.

ar
+1 That is perfect - exactly what I wanted. Please see edits in question.
sberry2A
It's always nice to see people using JMeter.
ar