Get Knowledge from Video instead of Content:

Friday, 27 January 2017

JMeter - Thread Group - "Arrivals Thread Group"

This thread group element is specially created for the case where no. of orders to be submitted in an hour; is known. For example, 2000 orders are purchased on an e-commerce every day, 1000 movie tickets are booked every hour on a movie ticket booking application, 10 licenses of a software are purchased every minute etc. In such type of scenarios, more preference is given to quantity of order irrespective no. of users. Apache JMeter adjust the number of Threads according to the target arrival rate. Now, here it is necessary to understand the arrival rate. "Arrivals Rate" word is used for the rate of iteration (order submission). If I say 10 licenses are purchased in a minute which signifies that 10 iterations need to be started and completed in 1 minute. Hence arrival rate will be 10/min. If I say 1000 movie tickets booking in an hour (16.6 = ~17/min), then it signifies that around 17 iterations should be started and completed in 1 minute, so arrival rate will be 17. 

One point to be noted here, I did not talk about the number of users in the above-mentioned scenarios, it means that arrival rate can be controlled by 1 or multiple threads. In case the arrival rate is too high then you can cap the number of threads. This option is available. Another best thing about Arrivals Thread Group is all the active threads are stopped in a graceful manner at the end of the test. i.e. all the threads complete their iteration and then exit from the test. Now, let's try to discuss more in detail.

How to download “Arrivals Thread Group” plug-in?
1. Click on the link to download Arrivals Thread Group JMeter Plugin
2. Unzip the folder
3. Copy the file jmeter-plugins-cmn-jmeter-<version>.jar to lib folder of Apache JMeter

           apache-jmeter-<version> –>lib –> Paste jmeter-plugins-cmn-jmeter-<version>.jar

4. Copy the files jmeter-plugins-casutg-<version>.jar and jmeter-plugins-manager-<version>.jar to ext folder of Apache JMeter

          apache-jmeter-<version> –>lib –>ext -> Paste jmeter-plugins-casutg-<version>.jar and jmeter-plugins-manager-<version>.jar

That’s it!

Please note .jar file version may change as per plug-in update.

How to open/add “Arrivals Thread Group” in Test Plan?
1. Select "Test Plan" node
2. Right click on "Test Plan" node
3. Mouse hover "Add"
4. Mouse hover "Thread (Users)"
5. Click "bzm - Arrivals Thread Group"

How to configure Work Load using “Arrivals Thread Group”?
1. Let's consider, the requirement is to order 3000 products in an hour which means 50 products/minute. 
2. The ramp-up time is 5 minutes and step count is 5.
3. To control the number of threads, concurrency limit is given to 50 users.
4. Thread Iteration limit is blank to make infinite iterations by the users during test duration.
5. Hold target rate time is 60 minutes.
6. Please refer to the configuration given below:

How to remove “Arrivals Thread Group”?
     1. Select "bzm - Arrivals  Thread Group" node
2. Right click on "bzm - Arrivals Thread Group" node
3. Click "Remove" (Mouse) or "Delete" button from keyboard
4. Click "Yes"

What are the attributes of “Arrivals Thread Group”?
a.  Name: To provide Thread Group name. It may be your Test Case/Test Scenario name
b.  Comments: To provide comments
c.   Action to be taken after a Sampler error: Actions taken in case of sampler error occurs, either because the sample itself failed or an assertion failed etc. The possible choices are:
                         i.      Continue - ignore the error and continue with the test
                         ii.      Start Next Loop - ignore the error, start next loop and continue with the test
                         iii.      Stop Thread - current thread exits
                         iv.      Stop Test - the entire test is stopped at the end of any current samples.
                          v.      Stop Test Now - the entire test is stopped abruptly. Any current samplers are interrupted if possible.
Apache Jmeter - Ultimate Thread Group Plugin

d. Target Rate (arrivals/min): Total number of iterations to be started in 1 minute. You can also provide Target Rate in seconds by selecting "seconds" in Time Unit option.
e. Ramp-up Time (min): Total ramp-up duration of arrival rate in minutes. You can also provide ramp-up duration in seconds by choosing "seconds" in Time Unit option given below the scenario chart. 
f. Ramp-up Steps Count: Total number of steps in which arrival count (iteration count) will ramp-up. In above example, next 5 iterations (users) will be added after each 1 minutes interval (=Ramp-up Time/Ramp-up Steps Count).
g. Hold Target Rate Time (min): The steady state when all the threads are active. This is also called as system monitoring window. If you want to monitor the system/application performance for 1 hour then the value for hold target rate time will be 60 minutes or 3600 seconds. The ramp-up time does not add to this time.
h. Time Unit: To change the input time unit either in minute or in second.
i. Thread Iterations Limit: To define the number of iterations completed by each thread. If you leave it blank then thread will continue the iteration until the test ends.
j. Log Thread Status into File: Provide the full path of the file along with the name where you want to save the log file. e.g. C:\PerfMatrix\Result\testLogFile.log

Next Topic:
Free-Form Arrivals Thread Group

Previous Topic:
Concurrency Thread Group

Related Topics:

6 comments :

  1. hi,
    can you plz explain more on how the graph is plotted i.e which value is considered where?

    ReplyDelete
    Replies
    1. Please refer the attribute section for detailed explanation of each field and also refer and sync the GIF.

      Delete
    2. Actually i have checked that but i m not getting clear idea, could you plz explain

      Delete
    3. i did not understand - Rampup time in min which is 5 & Ramp up steps count which is 5 , i m unable to find it on graph

      Delete
    4. Target Rate: 50 product/munute
      Ramp-up: 5 minutes (in 5 minutes all the users will ramp-up)
      Ramp-up Step count: 5 (means each minute 10 users will ramp-up, so in 5 minutes 50 users will be ramped-up)
      Hold Target Rate: Duration of Steady State
      Concurrency Limit: 50 (to maintain 50 users concurrency)

      Delete