Warning: fopen(/tmp/SghXTngBZPli-UDuh3z.tmp): failed to open stream: Disk quota exceeded in /home/executea/public_html/blog/wp-admin/includes/class-wp-filesystem-ftpext.php on line 139

Warning: unlink(/tmp/SghXTngBZPli-UDuh3z.tmp): No such file or directory in /home/executea/public_html/blog/wp-admin/includes/class-wp-filesystem-ftpext.php on line 142
Site Loader
Auckland, New Zealand
Last post on JMeter introduction, we saw what JMeter is and different kinds of protocol it supports. In this post we are going to discuss on different components of JMeter.

JMeter

This is how JMeter looks like

And you can see different JMeter components by right clicking on the Test Plan as shown below (Each of these components has different sub components as shown)

As you can see above these are the following components which we are going to work in this series
  • Threads
  • Test Fragments
  • Config Element
  • Timer
  • Pre Processor
  • Post Processors
  • Assertions
  • Listener
We will use all the components in most of our Stress test plans, which we will discuss in our later post of this series. Let’s start with some of the most important components in JMeter

Most Important Component in JMeter

Threads (Users)

Threads are nothing but Virtual users in JMeter (Same as Virtual User Generator VUGen in Load runner) and they used to execute the load and performance test created within the Test Plan. You can create Threads (Thread Group) as shown below

 

Creating Users

And you can create users and number of time each user has to perform operations, and also what should happen for test if there happens anything in sampler (Which we will discuss later)

Config Element

Config Element in JMeter are like Set up elements, they are used as a configuration values for the test we are going to execute. It can be for any protocol we are going to work with, but for each protocol there resides a config Element as shown below

Example 1 – CSV Data Set Config

Let’s take an example config Element of CSV Data Set Config If we are going to retrieve data from external source, say CSV, then first we do need to import the CSV file and get we need to store the values of CSV (As parameters) for usage with test plan. In order to do that, we can use CSV Data Set Config as shown below

We can now use the variable names username and password in JMeter as ${username} and ${password} in any component like sampler, Assertion etc with the test plan

Example 2 – HTTP Request Default

Let’s say we want to test following pages in Executeautomation.com web site As you can see above all the pages (in JMeter context they are called as HTTP Request (part of Sampler Component)) have domain name and sub-directory in common, which is http://executeautomation.com/blog , instead of having each request with full path, we can just give part of it path to HTTP Request by using HTTP Request Default. This we can do by first creating HTTP Request Default and then create different HTTP Requests as shown below Now the HTTP Request Default will look like this

And HTTP Request will look like this (We will talk above sampler in later post of this series)

As you can see in HTTP Request, we have just passed the partial path, since HTTP Request Default config element will take care of the rest.

Timers

Timers are used to create different kinds of delay in each user request (based on the configuration)

Some of the most commonly used timers are Gaussian Random Timer, Constant Timer and Uniform Random Timer. I hope this post might have given you all what JMeter Components really does. We will discuss rest of the most commonly used Components in next part of same topic in this series. Please leave your comments and Thanks for reading !! Thanks, Karthik KK

Post Author: Karthik kk

2 Replies to “An Introduction to Components in JMeter – Part 1 (Series)”

Leave a Reply

Your email address will not be published. Required fields are marked *