JMeter Interview Question

Following are the some basic and advanced Top JMeter Interview Question and answer for both beginner and experience Automation Tester. We have focused on JMeter basic, Listener , Thread etc.

Before going ahead to JMeter Interview Question, please have a look on JMeter to have some better understanding on the JMeter basic. Let’s have a look on JMeter Interview Question

1. What is Performance Testing?

Ans. Performance Testing is known as non-functional testing. So as this is a non functional testing, this deals with response time, speed, stability of the website. This is verify whether the website is pinging within a certain amount of time under various workload. Addition to tracking response time, Performance Testing measures the quality of the system such as scalability, reliability and resource usage.

2. What is Load Testing?

Ans. Load Testing is checking the system stability, reliability under a specific workload. This load testing can be performed when multiple user access the site simultaneously. The main target of the load testing is to to ensure smooth functioning with stable software under real life scenario.

3. What is difference between Performance Testing and Load Testing ?

Ans. Performance testing is the non functional testing type where we need to check the response time, stability under varying load. Where as Load testing the the testing type where we need to ensure the smooth functioning with stable software when multiple user access the same site same time in real life scenario.

4. What is Stress Testing?

Ans. Stress testing is same as load testing with some additional condition. This verifies the stability of software under the heavy loaded to find the maximum load point. Beyond that point site will broken. This maximum load point is known as stress point.

5. What are the tools for Load Testing ?

Ans. There are lots of tools available for Load testing. Some of are,

  • Apache JMeter
  • WebLOAD from RadView.
  • Locust
  • Load Multiplier
  • WAPT
  • Load Runner
  • NeoLoad etc.

6. What is JMeter?

Ans. JMeter is the open source popular tool for performance/ Load Testing which was developer by Stefano Mazzocchi of the Apache software Foundation, JMeter is easy to use can be downloaded free of cost. his is purely Java based application used for performance testing and monitoring the speed, response time , stability etc. of the application You can analyze and performance of the application by using the JMeter Open source tool. There are lots of plugins available freely in market. We can use theme to extend the functionality. So JMeter is the best tool for Performance Testing.

7. What Testing can be performed in JMeter?

Ans. You can perform Non functional testing like Performance Testing, Load Testing. Stress Testing etc. and some extend of unit testing.

8. What are the protocols supported by JMeter?

Ans. Some protocols which are supported by JMeter are:

  • LDAP
  • HTTP / HTTPS
  • Web Services
  • FTP Services
  • JMS
  • SMTP
  • JDBC etc.

9. What is the feature of JMeter?

Ans. JMeter features are describes as below:

  • License: This is available freely as this is an Opensource software
  • User Interface: The GUI of JMeter is very simple and User friendly. A layman without coding knowledge can understand and use this tool as compared to Other Performance Testing tools.
  • Reporting: JMeter provides CSV and XML reports only by default. We can use additional plugin to generate the customized graph result for better understanding of the result
  • Supported Testing: In JMeter we can perform both functional testing and Regression apart from the Performance Testing and Load Testing. This also supports the distributed testing where master will spread the tests among all slave and slaves will execute the functionality.
  • Server Supported: JMeter support LDAP, HTTP/HTTPS, SMTP, FTP, Web Services etc for conducting the Performance Testing.
  • Threading: JMeter is a multi threading framework in which samplers are running in concurrent manner.
  • Configuration: JMeter is very simple to use and install. There is no programming knowledge required to configure the JMeter.
  • Platform:  Java is 100% purely java-based software. So this is platform independent and support each and every platform. On windows, we can execute JMeter by opening the jmeter.bat file and on UNIX/LINUX, by clicking on jmeter.sh.
  • Format: The format of JMeter is XML format. Which means we can generate our test plan using normal text editor.
  • Highly Extensible: JMeter support the visualization plugins which allow you to extend the basic functionality.
  • Customization: Developer can customize the source code as per the requirement as this is Open source and its plugins are available freely in market.
  • Community Support:  JMeter has big community support and also lots of tutorial videos are available.

10. What are the disadvantages of JMeter?

Ans. Though JMeter has lots of features with open source, it has some drawback as compared to other licensed tool like load runner.

  • Unlike Load Runner, it is not supporting Network Visualization feature.
  • JMeter is not supporting ajax. Flash and JavaScript.
  • As compared to other paid tool it provides very limited real time test monitoring capability.
  • So to execute JMeter script for high load,  the normal configuration machine is not sufficient enough.  In such case distributed testing  is performed or high configuration cloud environment required

11. What is the latest version of the JMeter?

Ans. The latest version of the JMeter is 5.2 which was released on November 4, 2019.

12. What OS are compatible with JMeter?

Ans. Most of the OS are compatible with JMeter.

  • Windows
  • Linux
  • Mac OS
  • Ubuntu

13. What is the difference between Load Runner and JMeter?

Ans. Below are some difference between Load Runner and JMeter.

  • JMeter is Open source performance testing tool where are Load Runner is the licensed performance Testing tool and expensive.
  • JMeter was developed by Apache Software Foundation, Jakarta, or Apache JMeter for short where as Load Runner was developed by Mercury Interactive.
  • JMeter has unlimited load generation where as Load runner has the limited load generation.
  • if we consider from technical point of view JMeter is less proficient as compared to Load Runner.
  • If we consider from the user friendly or user interface, Load runner is more impressive than JMeter.

14. What is Thread in JMeter?

Ans. Thread group will simulate virtual Users and run the required test on the application. Thread is generally subset of Thread Group in JMeter Test plan. Thread group is generally created based on the scenario. This will execute a set of thread of same scenario.

15. Explain the component of Thread in JMeter.

Ans. Below screenshot is the example of Thread Group. It has some component we should aware of. Let’s discuss the significance of each component.

  • Name: This field signifies the name of the assertion which will be listed under the Thread. Name field is so crucial if you will be working with a big application having lots of validation and functionalities.
  • Comments: Comments field is usually used to give comments to our Assertion. This field is optional.
  • Action to be taken after a Sampler error: This field is used to specify that which action should be taken if sampler error occurs.E.g. Continue, Start Next Thread loop, Stop Thread, Stop Test, Stop Test Now etc.
  • Number of Threads: This field simulates the number of virtual users to be tested.
  • Ramp up period: Ramp up period is a crucial part of JMeter Thread. This defines how long to take enter all threads enter to the system. For example, if we configured the “Number of Thread” as 100 and “Ramp up Period” as 300, this will take 300 seconds to make all 100 thread users up and running. This means each will start 3 seconds after the previous thread started.
  • In general form we can define this scenario that Ramp up Period / Number of Thread will be the time difference between each consecutive threads.
  • Loop Count: From the name you can guess the significance of Loop Count. Loop count is nothing but running the test multiple time. If we want to run our test 5 times, then we need to give 5 in Loop count field. If we need to run the test infinity times / forever, then we need to check the “Forever” check box.
  • Same User in each iteration:  If we check “Same User in each Iteration” then JMeter will use same user details to run the test in each iteration. If we don’t want that then we can leave this field unchecked.
  • Delay Thread creation until needed: This signifies to add delay the thread creation until needed.
  • Specify Thread lifetime: This will enable delays field if we check this check box. It will allow user to specify delay duration and start-up delay.
  • Duration: This allows JMeter to run the test within the defined duration whatever mentioned in this field. The unit of this field is Seconds. 
  • For Example, if we set Duration as 120, then JMeter will run the test for 120 seconds. After 120 seconds test will end
  • Startup Delay: Startup delay is the time duration which used to delay the thread initiation. If we want to initiate the thread after 5 second, then we need to give 5 in Startup delay field.

16. What is config Element in JMeter?

Ans. Config Element in JMeter allows us to modify the samplers we have added. You can create custom and default variable through Config Element which can modify samplers. The scope of this element is the start of the scope where they are located.

17. What are the config element exist in JMeter?

Ans. Below is the list of config element JMeter supports.

  • CSV Data Set Config
  • FTP Request Defaults
  • HTTP Authorization Manager
  • HTTP Cache Manager
  • KeyStore Configuration
  • HTTP Proxy Server
  • HTTP Request Defaults
  • Counter
  • HTTP Header Manager
  • Java Request Defaults
  • HTTP Cookie Manager
  • JDBC Connection Configuration
  • Login Config Element
  • LDAP Request Defaults
  • LDAP Extended Request Defaults
  • TCP Sampler Config
  • User Defined Variables
  • Simple Config Element
  • Random Variable

18. What is Timer in Selenium?

Ans. Timer in JMeter is easy but crucial part of JMeter where we have to manage the thread user count and time to apply the load to the application. Below screenshot is list of all Timers provided by JMeter to control the load. If you want to use the thread user with some interval, then Timer helps you to spaceout your sampler requests.  We can called this as “Think Time” We can user both static and variable time to separate request.

19. What are the Timers available in JMeter?

Ans. Below is the list of Timers available in JMeter.

  • Constant Timer
  • Uniform Random Timer
  • Precise Throughput Timer
  • Constant Random Timer
  • Gaussian Random Timer
  • JSR223 Timer
  • Poisson Random Timer
  • Synchronizing Timer
  • Beanshell Timer

20. What is Samplers ?

Ans. This defines what should happen. Several samplers are available which provides ability to send several request types like JDBC, HTTP etc

21. What is Logic Controller?

Ans. Logic controller is nothing but the control the sequence of request in a thread. For example, if you want to run the thread randomly or loop or simple, you can customize this in Logic controller.

Some commonly used logic controllers are

  • Simple controller
  • Recording Controller
  • Loop Controller
  • Random Controller
  • Module controller etc.

22. What is Assertion?

Ans. This is ability to validate test on response of the sampler request sent to server. When you would like to verify expected result and actual result then assertion is the correct option to choose. In JMeter, we can verify the assertion from the Assertion Listener which need to be added in Thread. Assertion is a part of Post Processor.

23. What are the types of Assertion in JMeter?

Ans. Generally, there are 4 types of Assertion in JMeter.

  • Response Assertion
  • Size Assertion
  • Duration Assertion
  • XML Assertion
  • HTML Assertion

24. What is Response Assertion?

Ans. Response Assertion is used to verify the server response is correct or not. If we click the Facebook link in URL and want to verify the response, then we should use Response Assertion. 

Above screenshot is the example of Response Assertion. It has some filed we should aware of. Let’s discuss the significance of each field.

  • Name: This field signifies the name of the assertion which will be listed under the Thread. Name field is so crucial if you will be working with a big application having lots of validation and functionalities.
  • Comments: Comments field is usually used to give comments to our Assertion. This field is optional.
  • Apply to: This field is used to specify that in which sampler the assertion should apply. Whether in Main Sampler or Sub Sampler or both. If we choose Main Sampler only then Assertion should apply to Main Sampler only, not in Sub Sampler.
  • Field to Test: This field allow us to specify the field in which the Assertion should apply. E.g. Text Response, Response Code, Response Message Response Header, Request Header, URL Sampler, Document(text). Ignore Status, Request Data etc.
  • Pattern Matching: This filed allow us to specify the rule to matching the pattern. E.g. Contains, Matches, Equals, Substring, Not, Or etc.
  • Pattern to Test:  This field allow us to specify the pattern to verify the response.

25. What is Size Assertion?

Size Assertion verify the size of the response. This checks whether the response contains expected number of byte or not. If not, then Assertion will fail.

Above screenshot is the example of Size Assertion. It has some filed we should aware of. Let’s discuss the significance of each field.

  • Name : This field signifies the name of the assertion which will be listed under the Thread. Name field is so crucial if you will be working with a big application having lots of validation and functionalities.
  • Comments: Comments field is usually used to give comments to our Assertion. This field is optional.
  • Apply to: This field is used to specify that in which sampler the assertion should apply. Whether in Main Sampler or Sub Sampler or both. If we choose Main Sampler only then Assertion should apply to Main Sampler only, not in Sub Sampler.
  • Response Size Field to Test: This field allow us to specify the field in which the Assertion should apply. E.g. Full Response, Response Headers, Response Body, Response Code, Response Message etc.
  • Size to Assert: This field allow us to specify the size to verify the response.

26. What is Duration Assertion?

Duration Assertion verify the time constraint used to verify the response. This checks whether the response received within a time duration or not. If not, then Assertion will fail.

Above screenshot is the example of Duration Assertion. It has some filed we should aware of. Let’s discuss the significance of each field.

  • Name: This field signifies the name of the assertion which will be listed under the Thread. Name field is so crucial if you will be working with a big application having lots of validation and functionalities.
  • Comments: Comments field is usually used to give comments to our Assertion. This field is optional.
  • Apply to: This field is used to specify that in which sampler the assertion should apply. Whether in Main Sampler or Sub Sampler or both. If we choose Main Sampler only then Assertion should apply to Main Sampler only, not in Sub Sampler.
  • Duration in milliseconds: This field allow us to specify the time duration to verify the response.

27. What are the Listeners in JMeter?

Ans. From the name Listener in JMeter you can guess that it listens the result of the test and display in a graphical format or tabular format. Apart from displaying results, Listener also allow user to monitor the requests and analysed those responses in JMeter. In this element, User can monitor average time, minimum time, response time, maximum time etc. of a sampler request. Addition to graphical and tabular format, JMeter also display result in tree and log file also.

Leave a Reply

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