jMeter + Eclipse HOWTO
NOTE: As I see, I broke this wiki page It refers to images on my updated home page - this images no longer exist. Please refer to the original document (jMeter + Eclipse HOWTO
Michal Kostrzewa (firstname.lastname@example.org)
Special thanks to Janka Kostrzewa for correcting this text.
Link to original: jMeter + Eclipse HOWTO
This document describes briefly how to develop the jMeter project with Eclipse IDE. Eclipse is a very powerful development environment with following features:
- It's fast! Although it's written in JAVA like many other development platforms, it doesn't use SWING, which is big and slow; it uses an especially created SWT widget toolkit instead. This tookit doesn't emulate widgets in java, but it uses native system widgets (GTK on linux), which improves performance substantially.
- Very functional editor/package browser with syntax highlighting and syntax hints.
- Compiles java classes on the fly (when waiting for user input or saving a file), so one doesn't have to wait when launching an application. Furthermore, one sees errors immediately.
- Very nice debugger.
- Powerful code refactoring: when you want to change the name of a method or change parameters, don't hesitate to do it. *Eclipse intelligently changes appropriate things regarding to java syntax (you won't get this result using simple search/replace).
- CVS integration.
- Can automatically create getter and setter methods.
- CPL licence (OSI approved).
- Last but not least: search with regard to java syntax. You can just mark an identificator and click "open super implementation" or "find any reference to.." or "find declaration of...". It helps very much when exploring the internals of an unknown application.
- Many (many) more...
Eclipse is available for download for different platforms at http://www.eclipse.org
Setting up jMeter + Eclipse
I assume you downloaded Eclipse IDE and have it working.
The directions below are for cvs, but JMeter now uses Subversion. You will need to use the Eclipse pluging Subclipse to get JMeter from the repository.
0. Install Subclipse.
1. Open the SVN perspective with and "SVN Repository Exploring"
- 2. Invoke the popup menu and select "New"/"Repository location"
- 3. Fill in the latest branch and click OK
- 4. The repository should appear in a list. Right click it and go to "Checkout...".
- 5. Select Check out as a project configured using the New Project Wizard"
- 6. Select "JAVA project", and give a name for the project in next dialogs.
- 7. Wait for the SVN checkout to complete.
Setting up paths
Open "Java browser perspective" with and buttons Find your project and create a folder named lib/ext (lib already exists) Find your project root element, invoke the pop-up menu and select project properties Select "JAVA build path" side tree element Select "Source" tab Click "Add Existing Folders" and select as follows Enter "Build output folder" as project-name/lib/ext NOTE: this path is important, don't change it to any other directory The source tab should look like this: Select "Libraries" tab Select "Add jars" Select following jars: Click "OK" and wait for the entire source tree to compile
Running and debugging jMeter
Find the NewDrive class on "Java browser perspective" Select "Run"/"Run ..." from the menu Select "Java application" from the side tree and click "New". JMeter running configuration will be added Important: Select "Arguments" tab, uncheck "Use default working directory" and correct working directory field to project-name/bin Click "Run" From this time you can run and debug jMeter simply by pressing and buttons
Please send your comments concerning eclipse+jMeter as well as grammar/spelling issues either to jmeter mailing list or to me (email@example.com).