topcan5
topcan5

Reputation: 1707

jMeter Soap test with multiple requests

I want to test a SOAP function through iMeter Soap/XML-RPC Data. The logic is simple, I am passing a user id and want to get the user profile back. I want to test 100 users, user id from 1 to 100. And I want to create 50 threads, each thread run through these 100 ids for 2 hours. My question is how can I make jMeter to call all these 100 user request. The request XML is something like this. Should I just create 100 of these xml request with id from 1 to 100?

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://server.smartleads.alliancetech.com" xmlns:data="http://data.post.server.smartleads.alliancetech.com" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <soapenv:Header/>
  <soapenv:Body>
     <ser:getRegistration>
        <ser:aaGetRegReqObj>
           <data:action>0</data:action>
           <data:version xsi:nil="true"/>
           <data:debug>true</data:debug>
           <data:id>55</data:id>
        </ser:aaGetRegReqObj>
     </ser:getRegistration>
  </soapenv:Body>
</soapenv:Envelope>

Upvotes: 2

Views: 5064

Answers (3)

topcan5
topcan5

Reputation: 1707

I think I will use CSV Data Set Config in this case. Thanks all!

Upvotes: 1

Jay
Jay

Reputation: 1409

There are a lot of ways to get your goal. Some of them:

  1. Use __counter() function
  2. Use config emelment - Counter

For example, if you'll use counter, configure it like this: counterExample

Then, use specified reference name in your request:

<ser:aaGetRegReqObj>
           <data:action>0</data:action>
           <data:version xsi:nil="true"/>
           <data:debug>true</data:debug>
           <data:id>${userId}</data:id>
        </ser:aaGetRegReqObj>

Upvotes: 3

Ophir Prusak
Ophir Prusak

Reputation: 1447

A simple loop from 1 to 100 with SOAP/XML sampler:

Loops:
http://2min2code.com/articles/jmeter_intro/loop_controller

SOAP / XML:
http://jmeter.apache.org/usermanual/component_reference.html#SOAP/XML-RPC_Request

It looks like you're just getting started with JMeter, here is a JMeter getting started video tutorial:
http://blazemeter.com/blog/jmeter-tutorial-video-series

Upvotes: 2

Related Questions