Second--jmeter testing Java requests

Source: Internet
Author: User

Prerequisite: You need to prepare eclipse as a development tool, install the JDK, ready, and then start!

  

1, new Java Engineering bmirisjnijartest, new Lib directory, the JMeter installation directory under the Lib/ext package Apachejmeter_core.jar and Apachejmeter_ Java.jar copy to Lib, then import the jar package

2, Abstractjavasamplerclient is the core interface of Java request, implementation of interface Abstractjavasamplerclient,sampleresult between the start and end of the method can write test code

3. Generate the src code jar package Bmirisjnijartest.jar

4. Put the generated and referenced jar packages into the JMeter Lib/ext directory

5. Run Jmeter.bat under bin in JMeter installation directory

A. Test plan-Right-click-threads-thread Group

b, Thread group-right-click-sampler-java request

C, for example, you can select a custom test class at the class name, such as

6. After configuring the number and time of thread group execution, the test plan can be executed.

  A brief introduction to the use of Java requests, understand the entire process, more practice to familiarize yourself with the entire test process, the next article describes how to stress test the database.

Second--jmeter testing Java requests

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.