I use the following two methods:
- You can run Jmeter in non-GUI mode using command line ("Execute Windows batch command" or "Execute Shell" build step in Jenkins job settings)
jmeter.bat -n -t path_to_your_jmx_script.jmx
Of course, you can do the same by launching Jmeter as a java application or within shell script.
By "Invoke Ant" build step.
This method provides you all the benefits of ant. So, just include jmeter in appropriate ant target in your build.xml file. Here is an example (jvmarg and jmeterarg are not required):
<target name="test" depends="clean">
<jmeter jmeterhome="${jmeter-home}"resultlogdir="results/jtl">
<testplans dir="scripts" includes="*.jmx"></testplans>
<jmeterarg value="-Jbackend=${env.Backend_Address}"/>
<jvmarg value="-Xmx512m"/>
<jvmarg value="-Xdebug"/>
</jmeter>
</target>
And that's how you can generate nice report:
<target name="report" depends="test">
<xslt classpathref="xslt.classpath"
basedir="results/jtl"
destdir="results/html"
includes="*.jtl"
style="${jmeter-home}/extras/jmeter-results-detail-report_21.xsl">
<param name="showData" expression="${show-data}"/>
</xslt>
<copy file="${jmeter-home}/extras/expand.png" tofile="results/html/expand.png"></copy>
<copy file="${jmeter-home}/extras/collapse.png" tofile="results/html/collapse.png"></copy>
</target>
Regarding Jenkins plugins - the only one I know (and use) is Performance Plugin that can mark your build as failed/passed based on Jmeter results and generate nice graphs.