JMeter essay How to write a database synchronously when writing a JTL file __ database

Source: Internet
Author: User
Story background


The former, which was discussed in the Flight Survey Group (283440449), synchronously writes the JTL file data of the aggregated report to the database. Specific benefits, we can diverge.
In addition to the previous experience of the revision of the source code, the solution to the idea, generally or from the source. Solving Ideas

1. Locate the Java file that writes the JTL file data.
2, write the JTL data at the same time, write MySQL database. Hands-on Practice 1 Find the location to write to JTL.

Roughly turned the table of contents, turned over here, and in the Resultcollector.java file, search the "JTL" keyword.
2 then looked at the approximate method.

Discover that the following method should be the method we want to change. (Sorry, put my debugging code in ...) )
3 View csvsaveservice.resulttodelimitedstring () method


In the method body, it means that all fields of the requested result are spliced together to return a string. 4 back to Resultcollector.java file

At this time we are
String savee = csvsaveservice.resulttodelimitedstring (event);
After this code, do two things:
1. Truncate the string
2. Write to MySQL Database
Modify the code as shown:

Need to write code and screenshots here is not on, not difficult. (Need to modify the class file and source code, the following will be uploaded to the flight test QQ Group)

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.