Uses of Controllers in JMeter

JMeter has two types of Controllers:

  1. Samplers
  2. Logic Controllers


  • Samplers allow JMeter to send specific types of requests to a server.
  • They simulate a user’s request for a page from the target server.
  • For example, you can add a HTTP Request sampler if you need to perform a POST, GET, DELETE on a HTTP service
  • Some useful samplers are:
    – HTTP Request
    – FTP Request
    – JDBC Request
    – BSF Request
    – SOAP/XML Request
    – RPC Requests
FTP Request:
This controller lets you send an FTP “download file” or “upload file” request to an FTP server.

For example, if you want to download a file “Test.txt” from a FTP server under test, you need to configure some parameters in JMeter as figure below-

FTP Request

JMeter will send FTP command to FTP server, and then download a file Test.txt from that server.

HTTP Request:
  • This sampler lets you send an HTTP/HTTPS request to a web server.
  • JMeter send a HTTP request to Google website and retrieve HTML files or image from this website.

HTTP Reuquest

JDBC Request:
  • This sampler lets you execute Database Performance Testing. It sends a JDBC Request (an SQL query) to a database.

JDBC Request

For example, a database server has a field test result stored in a table name test_tbl. You want to query this data from the database server; you can configure JMeter to send a SQL query to this server to retrieve data.


  • Logic Controllers let you control order of processing of Samplers in a Thread.
  • Logic Controllers can change the order of request coming from any of their child elements.
  • Some examples are: For Each Controller, While Controller, Loop Controller, IF Controller, Run Time Controller, Interleave Controller, Throughput Controller, and Run Once Controller.
  • A Loop Controller Control Panel looks like the following figure:

Logic Controller

The following list consists of all the Logic Controllers JMeter provides:

  • Simple Controller
  • Loop Controller
  • Once Only Controller
  • Interleave Controller
  • Random Controller
  • Random Order Controller
  • Throughput Controller
  • Runtime Controller
  • If Controller
  • While Controller
  • Switch Controller
  • For Each Controller
  • Module Controller
  • Include Controller
  • Transaction Controller


  • Listeners: shows the results of the test execution.
  • They can show results in different format such as tree, table, graph or log file

The following list consists of all the Listeners JMeter provides:




  • By default, a JMeter thread will send requests without pausing between each sampler.
  • This may not be what you want. We can add a timer element which will allow us to define a period to wait between each request.



Thanks for viewing and Please share your comments….