JMeter Interview Question and Answers
1Q) What is JMeter?
Ans: Apache JMeter is an open-source load testing application that is purely developed in Java. Apache JMeter is mainly used to test the performance and stability of an application.
2Q) What is the protocol JMeter supports?
Ans: IT support more than 10 protocols, here are some of the protocols that JMeter supports.
- Web Protocol: To test the web applications, it supports both HTTP and HTTPS protocols.
- Web Services: To test web services applications, it supports both SOAP and REST.
- FTP: File Transfer Protocol, it is used to test the FTP servers and applications.
- Database via JDBC: It is used to test the database applications.
- LDAP: Lightweight Directory Access Protocol
- Message-oriented middleware (MOM) via JMS
- Mail – It is used to test mail servers such as SMTP(S), POP3(S), and IMAP(S)
- MongoDB (NoSQL): it is a recently supported protocol by JMeter.
- Native commands or shell scripts
3Q) Why do you choose JMeter as your performance testing tool?
Ans: JMeter is an open-source tool and is a widely used tool in the market and it has the large online community support and is developed in pure Java and you can test more than 10 protocols.
4Q) What is an assertion and what are the different types of assertions available in JMeter?
Ans: Assertions are used to define the checkpoints in different parts of the script, there are different type of assertions available Bean Shell Assertion, BSF Assertion, Compare Assertion, Duration Assertion, HTML Assertion, JSR223 Assertion, MD5Hex Assertion, Response Assertion, Size Assertion, SMIME Assertion, XML Assertion.
5Q) Explain what is Post-processor?
Ans: To perform any action after making a request, Postprocessor is used. For example, if JMeter sends an HTTP request to the web server, and if you want JMeter to stop sending the request if the webserver shows an error, then you will use post-processor to perform this action.
Learn JMeter by Tekslate - Fastest growing sector in the industry. Explore Online "JMeter Training" and course is aligned with industry needs & developed by industry veterans. Tekslate will turn you into JMeter Expert.
6Q) What are the benefits that JMeter offers for performance testing?
Ans: JMeter offers benefits on performance testing like
It can be used to test performance for both, static resources as well as dynamic resources It can handle a maximum number of concurrent users then your website can handle It provides the graphical analyses of performance reports
7Q) List out a few JMeter Listeners?
Ans: Some of the JMeter Listeners are
Spline Visualizer Aggregate Report View Result Tree View Result in Table Monitor Results Distribution Graph BeanShell Listener Summary Report and so on
8Q) Explain what is Assertion in JMeter? What are the types of assertions?
Ans: Assertion helps to verify that your server under test returns the expected results
Some commonly used Assertion in JMeter are
Response Assertion Duration Assertion Size Assertion XML Assertion HTML Assertion
9Q) Explain what is configuration elements?
Ans: A configuration element works parallel with a Sampler. To set up defaults and variables for later use by samplers configuration elements can be used. At the start of the scope, theExplain how you can reduce the resource requirement in JMeter?
10Q) Explain how you can reduce the resource requirement in JMeter?
Ans: To reduce the resource requirements in JMeter
Use non-GUI mode: jmeter –n –t test.jmx –l test.jtl
During the load, the test doesn’t use “view results tree” or “view results in the table” listeners, use them only during the scripting phase
Don’t use functional mode
Instead of using lots of similar samplers, use the same sampler in the loop and use a variable to vary the sample
11Q) Explain what is Post-processor?
Ans: To perform any action after making a request, Postprocessor is used. For example, if JMeter sends an Http request to the web server, and if you want JMeter to stop sending the request if the webserver shows an error, then you will use post-processor to perform this action.
12Q) What are timers and what are the different timers available?
Ans: Timers is waiting time between requests, these timers are used to simulate real user behavior during each request, this helps to simulate real-time production load on the server.
There are different timers available in JMeter: Bean Shell Timer, BSF Timer, Constant Throughput Timer, Constant Timer, Gaussian Random Timer, JSR223 Timer, Poisson Random Timer, Synchronizing Timer, and Uniform Random Timer.