[JMeter Series] JMeter source code compilation steps

Source: Internet
Author: User

 Official website: http://jmeter.apache.org/building.html

1, in Apach official website download source code:

http://jmeter.apache.org/download_jmeter.cgi

Apache-jmeter-2.11_src.tgz(try to download the latest version), unzip it after downloading

2, this machine follows ant:

:http://ant.apache.org

Ant Installation Method:

Http://www.cnblogs.com/yuzhongwusan/archive/2013/03/26/2982411.html

3, the understanding and introduction of Build.xml file:

Http://zhidao.baidu.com/link?url=VG2fEkNGFv8aasF_f6crokn6CD7FnyDuv574eIsC6xoQC1QAWKQ-_2rJbNwKLXht9j91CxT33veXy3B9dwLDlq

4 open dos enter jmeter source directory, enter" ant download_jars" Get the code packages needed for compilation. (ps: If your network has an agent set up, The connection Time out may appear error, Solution: http://liu-hliang.iteye.com/blog/456664

When the word "build successful" appears , it is successful to take down the jar bag inside the warehouse .

5, compile jmeter:

First time compiling:ant [Install]

Re-compiling:ant clean install

There are other commands that you can refer to in the description section of Build.xml .

After the Build is complete, a hint of successful will appear

[options]  not with  -source 1.6  set the boot classpath together "

Workaround: Change the compiled Java version to 1.7 in build.xml

   6binjmeter.batjmeter   7jmetereclipse

1 ) New java project< Span style= "font-family: the song Body;"

2 ) using import < Span style= "font-family: the song Body;" >, choose file systemjmetereclipse

3 eclipse, will jmeter eclipse.classpath copy to java project .classpath file, click Save.

4) re-open Eclipse

 8eclipse build  (build) jmeter project

1) Select New ant-builder

2) set some parameters.

3) ant_build the build.xml file 4)after the build succeeds, the jmeter.bat file under the Bin folder can be executed. Jmeter importing Eclipse, how to compile2013-01-06 14:18 1926 people read comments (0) favorite reports Classification:Mobile Development ($)

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

1, download: to the Ant official website http://ant.apache.org/ Download the latest version, after decompression can.
2. Configure environment variables: My Computer----Properties-----Advanced----Environment Variables
such as: ant_home:c:\apache-ant-1.7.1
Path:%ant_home%\bin (for ease of operation in a DOS environment)
3. To see if the installation was successful: Enter the command in the DOS window ant, if the result appears
Buildfile:build.xml does not exist!
Build failed
Description ant installation is successful! Because ant runs the Build.xml file by default, this file needs to be created by us.

1. Create a new Java project in Eclipse, named JMeter, and in the next step Select "Allow output folders for source folders" to prevent the bin directory from being exported as output directory when importing the source code;

2, choose from the file system import apache-jmeter-2.7 source code;

3. Turn off Eclipse and rename Eclipse.classpath to. classpath under project directory;

4, in the project directory to execute Ant download_jars, or before the installation of the JMeter in the Lib directory files are copied over;

5. Execute the ant package under project directory;

6, open Eclipse, refresh the Lib directory and reload all LIB directories, you can compile the pass;

7, run as Java application, select "New Driver", the first run will fail;

8, Open Run dialog, select the working directory as "${workspace_loc:jmeter/bin}", you can run JMeter.

[JMeter Series] JMeter source Code compilation step (GO)

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.