Analysis of jmeter test results (II)

Source: Internet
Author: User

Repeat the previous article and continue with the previous one. The previous article explains how to use assertion to preliminarily filter test results. So how should we view the test results? How did they come from?

I. Use of listener

People who have used LoadRunner should know that LoadRunner will provide us with a lot of icons and curves. But in jmeter, we can only find a few poor listener to help us view the test results. However, for beginners, some simple result analysis tools make it easier for us to understand the analysis principles of performance test results. Therefore, do not underestimate these simple listener.

A. Aggregate report aggregation report

We can see that through this report we can get the results that are most concerned about performance testing in the general sense.

Samples -- total number of transactions completed in this scenario

Average -- average response time

Median -- the value of the response time above.

90% line -- the response time of 90% transactions in all transactions is less than xx

Min -- minimum response time

Max -- maximum response time

PS: the unit of the above time is ms.

Error -- Error Rate

Troughput -- throughput, in the unit of transaction/sec

KB/sec-throughput measured by traffic

B. view results tree to view the result in a tree list

Through this listener, we can see the detailed results returned by each transaction. The red color indicates the wrong transaction, and the green color indicates the pass.

If many transactions are completed in the test scenario, we recommend that you record only the wrong transactions in the listener. To do this, you only need to check the errors in log/display.

Ii. Analysis of jtl files

In the performance testing process, we often need to save the test results in a file, which can save the test results and provide more materials for future performance testing reports.

In jmeter, results are stored in. jtl files. This. jtl files can be written in multiple formats. Generally, they are recorded as CSV files. This is because the CSV file format looks convenient, more importantly, this can facilitate secondary analysis.

In addition to using listener, we can perform secondary analysis on the. jtl file.

A. Set the jtl File Format

We can decompress the jmeter downloaded from the jmeter official website and use it directly. However, the contents of the jtl file generated using the default configuration cannot meet our needs. Therefore, we must make necessary settings. In version 2.2, If You Want To modify jtl settings, you must set them in the jmeter. properties file. But in Version 2.3, you only need to set the settings on the interface. You only need to select a listener and click the Configure button on the page. In this case, a setting interface will pop up. We recommend that you check the following items: Save field name and save assertion failure message.

B. Items in the jtl File

After the above settings, the saved jtl file has the following items:

Timestamp, elapsed, label, responsecode, responsemessage, threadname, datatype, success, failuremessage, bytes, latency

Absolute request time, response time, request tag, return code, returned message, request thread, data type, success, Failure Information, bytes, response time

In the aggregate report, the throughput = the number of completed transactions/the time required to complete these transactions; the average response time = the sum of all response times/The number of completed transactions; failure Rate = number of failures/transaction count

Tip: In jmeter2.2 and 2.3, a problem exists: When we re-open jmeter and use a listener to view jtl files, jmeter reports an error. Therefore, after testing a scenario using the command line method, all you get is a bunch of raw data stored in the jtl file. Therefore, it is easy for you to get rid of the test tools to analyze the results by knowing the sources of the aggregation reports.

 

In general, the result analysis of jmeter is mainly to organize the raw data in the jtl file. I use some small scripts for relevant analysis. I don't know how you plan to do it?

After practice, you can always find your own data analysis path.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.