| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | Warning: The Eclipse.classpath file has been tested with Eclipse 3.2. | 
					
						
							|  |  |  | It may not work with other versions. | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2003-12-30 09:07:33 +08:00
										 |  |  | Eclipse.classpath | 
					
						
							|  |  |  | ----------------- | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | The file eclipse.classpath is intended as a starter .classpath file  | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | for building JMeter using Eclipse version 3.   | 
					
						
							| 
									
										
										
										
											2003-12-30 09:07:33 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | It has exclusion filters for all the source files that depend on optional jars. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | The optional jars are: | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | * beanshell - see http://www.beansehll.org/ | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | The usage of the jars is as follows: | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | java | 
					
						
							|  |  |  | ---- | 
					
						
							|  |  |  | org/apache/jmeter/protocol/java/**/BeanShell*.java - requires beanshell | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Before use, delete or disable the exclusion filters that are not required. | 
					
						
							| 
									
										
										
										
											2003-12-30 09:07:33 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | Unlike Ant, Eclipse does not support conditional excludes. | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | Note that Eclipse does not handle RMI compilations,  | 
					
						
							|  |  |  | nor is it easy to use for creating jar files. | 
					
						
							| 
									
										
										
										
											2003-12-30 09:07:33 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | However, it is easy to use Eclipse to run Ant. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | The following targets may prove useful: | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  |   compile-rmi - compiles the RMI files that Eclipse ignores | 
					
						
							|  |  |  |   package-only - creates the jars | 
					
						
							|  |  |  |   package - compiles everything and then packages it | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | Finishing the build using Ant | 
					
						
							|  |  |  | ----------------------------- | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Find the build.xml file in the project,  | 
					
						
							|  |  |  | right click on it, and click "Run As --> Ant Build". | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Make sure you select the "package" target. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | This will compile any remaining classes (e.g. the RMI ones), | 
					
						
							|  |  |  | and then create all the jars. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Now refresh the project (you should add this to the Ant build properties) | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | Launching from Eclipse | 
					
						
							|  |  |  | ---------------------- | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | These instructions assume you checked out the JMeter code as an Eclipse project named "jmeter". | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | If you used something else, adjust accordingly. | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | Create a new Java Application launch configuration. | 
					
						
							| 
									
										
										
										
											2007-03-08 08:48:47 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | On the Main tab, enter the following as the main class: | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   org.apache.jmeter.NewDriver | 
					
						
							|  |  |  |    | 
					
						
							|  |  |  | On the Arguments tab, in the Working Directory area, pick the radio | 
					
						
							|  |  |  | button next to "Other" and enter the following in the text box: | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  |   ${workspace_loc:jmeter/bin} | 
					
						
							| 
									
										
										
										
											2003-12-30 09:07:33 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2007-03-10 03:55:18 +08:00
										 |  |  | On the Classpath tab,click on User Entries, click on the Add | 
					
						
							|  |  |  | Jars button, then navigate to the file lib/ext/ApacheJMeter_core.jar | 
					
						
							|  |  |  | Pick it, click Ok. |