Git Product home page Git Product logo

jmeter-analysis-maven-plugin's Introduction

JMeter Result Analysis Plugin

Maven Central

A Maven plugin that parses JMeter result XML files and generates detailed reports with charts

Can be used in combination with the JMeter Maven Plugin that is developed by the same authors

Features

  • Text and HTML output of certain statistics (minimum, maximum, average, standard deviation, quantiles) for response duration and response size
  • Output is rendered with Freemarker and can be customized
  • Chart containing request duration and average of all requests
  • CSV file containing durations of all response (by URL)
  • CSV file containing sizes of all responses (by URL)
  • Statistics and charts can be generated per request group. Request groups are defined by URL patterns.
  • Download of resources from remote systems for the JMeter execution interval

Build status

Travis CI: Build Status

Help

Run the HelpMojo of this plugin: mvn jmeter-analysis:help -Ddetail=true -Dgoal=analyze

Release Notes

See Release Notes in the Wiki.

Usage Example

<plugin>
  <groupId>com.lazerycode.jmeter</groupId>
  <artifactId>jmeter-analysis-maven-plugin</artifactId>
  <executions>
    <execution>
      <goals>
        <goal>analyze</goal>
      </goals>
      <configuration>
        <!--
        An AntPath-Style pattern matching a JMeter XML result file to analyze. Must be a fully qualified path.
        File may be GZiped, must end in .gz then.

        Default: not set.
        Required.
        -->
        <source>${project.build.directory}/**/*.jtl</source>

        <!--
        directory where to store analysis result files.

        Default: ${project.build.directory}
        Required.
        -->
        <targetDirectory>${project.build.directory}/results</targetDirectory>

        <!--
        Build failed if source directory is not found.

        Default: true
        -->
        <sourceDirFailed>true</sourceDirFailed>

        <!--
        Check analysis result files. If threshold is not correct, maven build failed.

        Default: not set.
        -->
        <checkResult>
          <!-- Optional : check throughput. -->
          <throughput>
            <!-- Default: -1 (disabling) -->
            <threshold>-1</threshold>

            <!-- Default: UPPER_LOWER_TOLERANCE
            Values could be : 
            * UPPER :                 minValue = threshold, maxValue = Double.MAX_VALUE
            * LOWER :                 minValue = 0, maxValue = threshold
            * UPPER_TOLERANCE :       minValue = threshold, maxValue = (threshold + (threshold * tolerance / 100))
            * LOWER_TOLERANCE :       minValue = (threshold - (threshold * tolerance / 100)), maxValue = threshold
            * UPPER_LOWER_TOLERANCE : minValue = (threshold - (threshold * tolerance / 100)), maxValue = (threshold + (threshold * tolerance / 100))
            * EQUALS :                minValue = maxValue = threshold

            If throughput result test is between minValue and maxValue, maven build is OK otherwise, build failed.
            -->
            <toleranceDirection>UPPER_LOWER_TOLERANCE</toleranceDirection>

            <!-- Default: 5 (percent)
            Used for calculate min et max values.
            -->
            <tolerance>5</tolerance>
          </throughput>
          <!-- Optional : check percent errors. -->
          <errors>
            <!-- As above -->
            <threshold>-1</threshold>
            <toleranceDirection>UPPER_LOWER_TOLERANCE</toleranceDirection>
            <tolerance>5</tolerance>
          </errors>
        </checkResult>

        <!--
        Request groups as a mapping from "group name" to "ant pattern".
        A request uri that matches an ant pattern will be associated with the group name.
        Request details, charts and CSV files are generated per requestGroup.

        The order is honored, a sample will be added to the first matching pattern. So it's possible
        to define various patterns and one catch all pattern.

        If not set, the threadgroup name of the request will be used.

        Default: not set.
        -->
        <requestGroups>
          <requestGroup>
            <name>pages</name>
            <pattern>/page/**</pattern>
            <!-- Optional -->
            <checkResult>
              <!-- As above -->
            </checkResult>
          </requestGroup>
          <requestGroup>
            <name>binaries</name>
            <pattern>/binary/**</pattern>
            <!-- Optional -->
            <checkResult>
              <!-- As above -->
            </checkResult>
          </requestGroup>
        </requestGroups>

        <!--
        Change default value for generating charts.

        Default: width=950, height=500
        -->
        <configurationCharts>
          <width>950</width>
          <height>500</height>
        </configurationCharts>

        <!--
        Maximum number of samples to keep (in main memory) before compressing. -1 disabling compression.

        Default: 50000
        -->
        <maxSamples>50000</maxSamples>

        <!--
        If set to true, the directory structure relative to source will be preserved during output.

        Default: false
        -->
        <preserveDirectories>false</preserveDirectories>

        <!--
        Set<String> of sample names that should be processed when analysing a results file.

        Default: sample, httpSample
        -->
        <sampleNames>
          <sampleName>sample</sampleName>
          <sampleName>httpSample</sampleName>
        </sampleNames>

        <!--
        If set to true will process all files found by the pattern defined in <source>.
        If set to false (the default) it will only process the first file found.

        *SETTING TO TRUE IS NOT RECOMMENDED*
        It can substantially impact performance, if you do this you do it at your own risk!

        Default: false
        -->
        <processAllFilesFound>false</processAllFilesFound>

        <!--
        Template directory where custom freemarker templates are stored.
        Freemarker templates are used for all generated output. (CSV files, HTML files, console output)
        Templates must be stored in one of the following three subfolders of the templateDirectory:

        csv, html, text

        The entry template must be called "main.ftl".

        For example,
        templateDirectory/text/main.ftl will be used for generating the console output.

        Default: not set.
        -->
        <templateDirectory>${project.basedir}/src/main/resources/</templateDirectory>

        <!--
        Mapping from resource URL to file name. Every resource will be downloaded and stored in 'targetDirectory'
        with the given filename. Tokens "_FROM_" and "_TO_" can be used as placeholders. These placeholders will
        be replaced by timestamps of execution interval (formatted as ISO8601, e.g. '20111216T145509+0100').

        Default: not set.
        -->
        <remoteResources>
          <property>
            <name>http://yourhost/path?from=_FROM_&amp;to=_TO_</name>
            <value>my_resource.txt</value>
          </property>
        </remoteResources>

        <!--
        Specify custom date format for resources not supporting ISO8601.
		
        Default IOS8601
        -->
        <remoteResourcesFromUntilDateFormat>HH:mm_yyyyMMdd</remoteResourcesFromUntilDateFormat>
		
        <!--
        List of writers that handle all output of the plugin.
       Defaults to:
       * com.lazerycode.jmeter.analyzer.writer.ChartWriter (generates detailed charts as PNGs),
       * com.lazerycode.jmeter.analyzer.writer.DetailsToCsvWriter (generates CSV files for every request group),
       * com.lazerycode.jmeter.analyzer.writer.DetailsToHtmlWriter (generates HTML files for every request group),
       * com.lazerycode.jmeter.analyzer.writer.HtmlWriter (generates an HTML overview file),
       * com.lazerycode.jmeter.analyzer.writer.SummaryTextToFileWriter (generates a TXT overview file),
       * com.lazerycode.jmeter.analyzer.writer.SummaryTextToStdOutWriter (generates overview output to stdout)

       If one of those should be deactivated or a new com.lazerycode.jmeter.analyzer.writer.Writer implementation should be added,
       all desired writers need to be configured!
        -->
        <!--<writers>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.SummaryTextToStdOutWriter/>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.SummaryTextToFileWriter/>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.HtmlWriter/>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.DetailsToCsvWriter/>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.DetailsToHtmlWriter/>-->
          <!--<com.lazerycode.jmeter.analyzer.writer.ChartWriter/>-->
        <!--</writers>-->

      </configuration>
    </execution>
  </executions>
</plugin>

Example Output

An analysis summary text output looks like this:

time: 20111216T145509+0100 - 20111216T145539+0100
requests:             36049
requests per second:  1201
total duration:       30
response duration (ms)
  min:                0
  average:            0
  max:                1352
  standard deviation: 7
  quantiles (ms)
       10%        0
       20%        0
       30%        0
       40%        0
       50%        1
       60%        1
       70%        1
       80%        1
       90%        1
       99%        6
     99.9%       19
    100.0%     1352 (max. value)
response size (bytes)
  total:              750210890
  min:                20480
  average:            20810
  max:                53890
  standard deviation: 3308
response status codes
  200:               36049 (100%)

Credits

Part of the development of this plugin is sponsored by CoreMedia

jmeter-analysis-maven-plugin's People

Contributors

afranken avatar ardesco avatar cboris avatar ccancellieri avatar dependabot[bot] avatar djangofan avatar gbatalski avatar lumnitzf avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

jmeter-analysis-maven-plugin's Issues

When a sample is failed the analyzer thrwos exception [Null or zero length 'values' argument.]

My jtl is as follows

<?xml version="1.0" encoding="UTF-8"?>
<testResults version="1.2">
<sample t="81" it="0" lt="0" ct="0" ts="1481591282275" s="true" lb="TestPreperation" rc="200" rm="Number of samples in transaction : 2, number of failing samples : 0" tn="Test Preparation Activities 1-1" dt="" de="" by="0" sc="1" ec="0" ng="1" na="1" hn="WIN100">
  <responseFile class="java.lang.String"></responseFile>
</sample>
<sample t="5623" it="0" lt="0" ct="0" ts="1481591292900" s="false" lb="02_Test_TestCase" rc="200" rm="Number of samples in transaction : 19, number of failing samples : 8" tn="02_Test 1-1" dt="" de="" by="246659" sc="1" ec="1" ng="1" na="1" hn="WIN100">
  <responseFile class="java.lang.String"></responseFile>
</sample>

</testResults>

My Analyzer plugin is configured as below

			<plugin>
				<groupId>com.lazerycode.jmeter</groupId>
				<artifactId>jmeter-analysis-maven-plugin</artifactId>
				<version>1.0.6</version>
				<configuration>
					<source>${project.build.directory}/jmeter/results/top_level_table.jtl</source>
				</configuration>
				<executions>
					<execution>
						<id>create-html-report</id>
						<phase>verify</phase>
						<goals>
							<goal>analyze</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

When run the below exception thrown.

[INFO] --- jmeter-analysis-maven-plugin:1.0.6:analyze (create-html-report) @ ccs-regression ---
[INFO]
[INFO] -------------------------------------------------------
[INFO] A N A L Y S I N G J M E T E R R E S U L T S
[INFO] -------------------------------------------------------
[INFO]
[INFO] Start index.
[INFO] End index.
[INFO] Analysing 'top_level_table.jtl'...
[INFO] Finished Parsing 2 entries.
Group: Test
time: 20161213T120802+1100 - 20161213T120802+1100
total duration: 0
requests: 1
requests per second: 0
response duration (ms)
min: 81
average: 81
max: 81
standard deviation: 0
quantiles (ms)
10% 0
20% 0
30% 0
40% 0
50% 0
60% 0
70% 0
80% 0
90% 0
99% 0
99.9% 0
100.0% 81 (max. value)
response size (bytes)
total: 0
min: 0
average: 0
max: 0
standard deviation: 0
response status codes
200: 1 (100%)
Group: 02_Test
time: 20161213T120812+1100 - 20161213T120812+1100
total duration: 0
requests: 0
requests per second: 0
errors: 100%
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 10:40 min
[INFO] Finished at: 2016-12-13T12:17:58+11:00
[INFO] Final Memory: 30M/485M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze (create-html-report) on project ccs-regression: Error analysing: Null or zero length 'values' argument. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze (create-html-report) on project ccs-regression: Error analysing
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error analysing
at com.lazerycode.jmeter.analyzer.AnalyzeMojo.execute(AnalyzeMojo.java:233)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
... 20 more
Caused by: java.lang.IllegalArgumentException: Null or zero length 'values' argument.
at org.jfree.data.statistics.HistogramDataset.getMinimum(HistogramDataset.java:221)
at org.jfree.data.statistics.HistogramDataset.addSeries(HistogramDataset.java:136)
at com.lazerycode.jmeter.analyzer.writer.ChartWriter.createResponseTimesPlot(ChartWriter.java:188)
at com.lazerycode.jmeter.analyzer.writer.ChartWriter.writeCharts(ChartWriter.java:95)
at com.lazerycode.jmeter.analyzer.writer.ChartWriter.write(ChartWriter.java:65)
at com.lazerycode.jmeter.analyzer.ResultAnalyzer.analyze(ResultAnalyzer.java:47)
at com.lazerycode.jmeter.analyzer.AnalyzeMojo.analyze(AnalyzeMojo.java:318)
at com.lazerycode.jmeter.analyzer.AnalyzeMojo.execute(AnalyzeMojo.java:217)
... 22 more
[ERROR]

Result Rendering should be easily extendible

while it's already possible to write custom Freemarker templates to customize the output to stdout, textfile and HTML, it's not possible to add custom output.

Currently, it's only possible to completely replace one or more templatesets.
It should be possible to easily add new ways to render output.

Reporter fails to generate results on large .jtl file

Hi,

I'm using the jmeter-maven-plugin with the jmeter-analyis-maven-plugin, on a long running test (30 mins, > 40,000 requests) the report which relies on the standard generated JTL file, fails to read in the results and thus jmeter fails to exit. It just hangs. On reducing the test time to about 8 mins (20,000 requests) its fine. Is this something with the reporter at play here, or some tweaking that can be done to allow for large files to be parsed in? There are no service errors, or memory problems and can complete without the reporter, if its removed.

Let me know what files you need for investigation.

Using the latest versions of both maven plugins mentioned.

It hangs here, and never continues to next step when things go wrong:
[INFO]
[INFO] -------------------------------------------------------
[INFO] P E R F O R M A N C E T E S T S
[INFO] -------------------------------------------------------
[INFO]
[INFO]
[info]
[debug] JMeter is called with the following command line arguments: -n -t c:\dev
\workspace\services\jmeter-myapi-api-performance\src\test\jmeter\myapi-perform
ance.jmx -l c:\dev\workspace\services\jmeter-myapi-api-performance\target\jmete
r\results\20150218-myapi-performance.jtl -d c:\dev\workspace\services\jmeter-bo
otam-api-performance\target\jmeter -j c:\dev\workspace\services\jmeter-myapi-ap
i-performance\target\jmeter\logs\myapi-performance.jmx.log
[info] Executing test: myapi-performance.jmx

Optimize logging / fix logging

Mark wrote:

From the logging point of view, it would seem that SLF4J is overriding all other logging the first time the code goes into JMeterResultParser and not handing control back to anything. So I see the following:

· Plugin starts to analyse results

· I see the first file get picked up

· I then the Summary of the first file analysed (produced by SLF4J)

· I then see no additional logging, nothing is printed out to screen until control of the cursor is returned.

I’m a bit stumped at the moment, the easy fix would seem to be just pull SLF4J out and use default maven logging since it’s only used in one class. I’m guessing you probably know more about SLF4J than me though so I’m just leaving it as it is for now.

see
https://groups.google.com/d/topic/maven-jmeter-plugin-devs/5Uo8Uv2jn1M/discussion

Results output is always called summary.html

The output of the jmeter-ananlysis-maven-plugin is always called:

summary.html
summary.txt
etc.

We should be using the filename we read in to name the output file to ensure we don't overwrite the results if multiple files are parsed.

Unable to parse jtl file

When we run performance tests, and if we have errors on jmeter run or if jtl file is large, we see below error while parsing the jtl file.

[ERROR] Failed to execute goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze (default) on project jmeter-maven: Error analysing: Character reference "&# -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Check result in ResultGroup doesnt work

This is how it looks in the pom


GetCodeWithoutcookie
/2.0/oauth/authorize



250
LOWER
25


Error output
[ERROR] Failed to execute goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze (default) on project jmeter-demo: Unable to parse configuration of mojo com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze for parameter threshold: Cannot find 'threshold' in class com.lazerycode.jmeter.analyzer.CheckResult -> [Help 1]

Preserve directory structure relative to source pattern

When the jmeter-maven-plugin still had the analysis integration, report files would be written to the results directory preserving the original directory structure relative to the source pattern.

For example:

/src/main/resources/test1/test.jmx

with a source pattern of
/src/main/resources/test1/

would generate a report below
/target/results/test1/test-report.html


this does not work any more, the relative path to the source pattern is completely ignored.

Re-implement this feature.

Errors are not added to HTML report.

When a test has responses with errors, they are not added to the html report, only successful results are present.

How to reproduce:

  1. Clone this test repo - https://github.com/ostap-oleksyn/analysis_errors
  2. Run mvn verify
  3. Open the html report in target/jmeter/results

Build will fail since there are responses with errors but no errors will be present in the report.
Issue seems similar to this #31
Maybe there are some settings that I need to configure to include errors in reports?

Report doesn't display thread group name with spaces in it

Report doesn't display thread group name with spaces in it.

If my Jmeter thread group is called "Thread Group - Whatever" then the report shows "Thread" as the thread group name. If the thread group name is called "setUp - Do First" , then the report shows "setUp" as the thread group name.

Automatic fail build based on threshold in Jenkins?

Hi,

I am wondering if it is possible to automatic fail a build based on predefined threshold when running Jmeter test with Jmeter mave plugin?

Some use scenario:

  1. HTTP response time is above an absolute threshold
  2. response time is above a relative threshold compared with previous build

For scenario 1), easiest way is probably to use autostop-plugin. A more complex way is to use Taurus PassFail criteria, which seems to be overkill if only need such feature.

For scenario 2), I have not found any ready solution yet. Jenkins performance plugin can generate performance trend, has anyone tried this, any feedback?

Rename AnalyzeCommand

and adjust JavaDoc.
This class was executable in the beginning, but not any more.

Execution does not finish correctly / System.out is closed

The System.out is closed (by closing the PrintWritter) in "renderTextToStdOut()" function in AnalyzeCommand.java.
The Writer should not be closed here. The maven execution is then not finished correctly and it causes problems in build tools (e.g. Jenkins).
The patch is below.
Anyway I think it should not print the result to stdout anyway (you have it in the file - no need to print it into maven output).

--- afranken-jmeter-analysis-maven-plugin-367a2db/src/main/java/com/lazerycode/jmeter/analyzer/AnalyzeCommand.java.orig 2012-09-25 16:48:32.541318349 +0200
+++ afranken-jmeter-analysis-maven-plugin-367a2db/src/main/java/com/lazerycode/jmeter/analyzer/AnalyzeCommand.java  2012-09-25 16:48:40.373318116 +0200
    @@ -147,7 +147,6 @@
     resultRenderHelper.renderText(testResults, out);

     out.flush();
-    out.close();
   }

//====================================================================================================================

Errors are always 0 for "Samples by uri"

We recognized that the count of errors in csv-reports show always "0" though errors happened in the jmeter-tests.

The errors are only listed in the "global-report":
response status codes
200: 80 (80.00%)
500: 20 (20.00%)

But not in the "csv-report" (or other uri splitted reports):
uri;count;total;min;average;max;standarddeviation;persecond;errors
Request;1000;27000;5;25;100;5;5;0

Is there any configuration missing to solve this problem?

Best Regards,
Weissmann

Add option for using requests/min in addition to requests per second. Also a Check for avgresponse time.

For those of us with lower traffic services, it would be helpful to have the option of expressing our throughput in requests/minute vs requests/second and have that be a better scale for showing requests. Especially when it's less than 60 RPM.

Also would be great to have AvgResponseTime be a check.

I've coded this up and just need to update the tests and this could be ready for a pull requests in the next 24 hours.

Running `jmeter-analysis:analyze` without a phase doesn’t read the configuration

I’m playing with jmeter-maven-plugin-example and if I run mvn -Pperformance verify both jmeter-maven-plugin and jmeter-analysis-maven-plugin are run and everything’s fine.

However, if I run first mvn -Pperformance jmeter:jmeter and then mvn -Pperformance jmeter-analysis:analyze I get this error:

[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building jmeter-maven-plugin-example DEV-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- jmeter-analysis-maven-plugin:1.0.6:analyze (default-cli) @ jmeter-maven-plugin-example ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.236 s
[INFO] Finished at: 2016-07-06T14:56:56+01:00
[INFO] Final Memory: 9M/309M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze (default-cli) on project jmeter-maven-plugin-example: The parameters 'source' for goal com.lazerycode.jmeter:jmeter-analysis-maven-plugin:1.0.6:analyze are missing or invalid -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginParameterException

My source parameter, according to the POM file, is:

<source>${project.build.directory}/jmeter/results/*</source>

And target/jmeter/results contains the jtl file.

Is there anything I’m not doing right?

Thanks in advance.

How to run JUST the analyzer

Hi, I'm using in conjunction with the jmeter-plugin and I would like run the analyser again on some existing results. How can I do this please?

I've tried failsafe:post-integration-test without any luck.

Running plugin without X11 in server fails

If I run the plugin when connected through SSH to a remote server I get the following exception and stack trace:

Exception in thread "main" java.lang.InternalError: Can't connect to X11 window server using '' as the value of the DISPLAY variable.
    at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
    at sun.awt.X11GraphicsEnvironment.access$200(X11GraphicsEnvironment.java:65)
    at sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:110)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:74)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:186)
    at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:102)
    at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:81)
    at sun.swing.SwingUtilities2.isLocalDisplay(SwingUtilities2.java:1448)
    at javax.swing.plaf.metal.MetalLookAndFeel.initComponentDefaults(MetalLookAndFeel.java:1556)
    at javax.swing.plaf.basic.BasicLookAndFeel.getDefaults(BasicLookAndFeel.java:148)
    at javax.swing.plaf.metal.MetalLookAndFeel.getDefaults(MetalLookAndFeel.java:1592)
    at javax.swing.UIManager.setLookAndFeel(UIManager.java:536)
    at javax.swing.UIManager.setLookAndFeel(UIManager.java:576)
    at javax.swing.UIManager.initializeDefaultLAF(UIManager.java:1345)
    at javax.swing.UIManager.initialize(UIManager.java:1455)
    at javax.swing.UIManager.maybeInitialize(UIManager.java:1422)
    at javax.swing.UIManager.getDefaults(UIManager.java:656)
    at javax.swing.UIManager.getColor(UIManager.java:698)
    at org.jfree.chart.JFreeChart.<clinit>(JFreeChart.java:262)
    at com.lazerycode.jmeter.analyzer.writer.ChartUtil.createJFreeChart(ChartUtil.java:151)
    at com.lazerycode.jmeter.analyzer.writer.ChartWriter.renderChart(ChartWriter.java:248)
    at com.lazerycode.jmeter.analyzer.writer.ChartWriter.writeCharts(ChartWriter.java:105)
    at com.lazerycode.jmeter.analyzer.writer.ChartWriter.write(ChartWriter.java:65)
    at com.lazerycode.jmeter.analyzer.ResultAnalyzer.analyze(ResultAnalyzer.java:47)
    at com.lazerycode.jmeter.analyzer.AnalyzeMojo.analyze(AnalyzeMojo.java:318)
    at com.lazerycode.jmeter.analyzer.AnalyzeMojo.execute(AnalyzeMojo.java:217)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:601)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

Does the plugin require to have a X11 windows session manager running?

Invalid requests count for group - version 1.0.6

Hi,

I have 4 groups: "check test file existence" (sample), "put" (httpSample), "get" (httpSample) and "delete" (httpSample), each of them consist of 9 requests. Somehow "check test file existence" and "get" are aggregated to one group named "get" even when I set only httpSample in sampleNames in pom.xml.
Why it is grouped by response code instead of label?
How can I change it?

Jtl file has got exactly 9 elements labeled with "get".
In Jmeter-analysis-maven-plugin csv file count is 9.
run.jtl.txt

Output and result json have invalid value:

08:57:01 Group: get
08:57:01 time: 20160901T095644+0200 - 20160901T095654+0200
08:57:01 total duration: 9
08:57:01 requests: 18
08:57:01 requests per second: 2
08:57:01 response duration (ms)
08:57:01 min: 4
08:57:01 average: 152
08:57:01 max: 1256
08:57:01 standard deviation: 289
08:57:01 quantiles (ms)
08:57:01 10% 4
08:57:01 20% 5
08:57:01 30% 6
08:57:01 40% 9
08:57:01 50% 15
08:57:01 60% 70
08:57:01 70% 134
08:57:01 80% 142
08:57:01 90% 171
08:57:01 99% 457
08:57:01 99.9% 457
08:57:01 100.0% 1256 (max. value)
08:57:01 response size (bytes)
08:57:01 total: 151001836
08:57:01 min: 0
08:57:01 average: 8388990
08:57:01 max: 16777996
08:57:01 standard deviation: 8388990
08:57:01 response status codes
08:57:01 200: 18 (100%)

{
"performanceData":
[
{
"min": 4,
"max": 1256,
"quantile90": 171,
"average": 152,
"total": 18,
"statusCodes":{
"200": 18
},
"uriByStatusCode":{
"200": [
"get",
"check test file existence"

]
}
} {
"min": 431,
"max": 4618,
"quantile90": 4087,
"average": 1695,
"total": 9,
"statusCodes":{
"201": 9
},
"uriByStatusCode":{
"201": [
"put"
]
}
} {
"min": 10,
"max": 35,
"quantile90": 27,
"average": 15,
"total": 9,
"statusCodes":{
"204": 9
},
"uriByStatusCode":{
"204": [
"delete"
]
}
}
]
}

Best regards and thanks for any advice

Assertions Result

How can I visualize the assertions errors in HTML report criated by jmeter-analysis-maven-plugin ?

Thanks for advance.

Add rultor.com to collaborators

I've added config for ruler.com to perform releases to maven central. To enable it you will need to:

Go into Settings -> Collaborators & teams
Add rultor.com as a collaborator with write access

Then you can talk to rultor in the comments to get it to perform releases. For example if you want it to release version 1.0.8 of the meter-analysis-maven-plugin and push it into maven central you would just type the following in a comment to an issue:

@rultor release, tag is 1.0.8

Make sample names configurable

at the moment, both "sample" and "httpSample" are analysed.
People may not always want that.

Add a property Set that defaults to "sample" and "httpSample" to make this configurable.
This way, if a custom sample name is ever inserted into a results file, it could be analysed too without code changes.

Unable to generate reports

Hi,

I am using Jmeter with webdriver sampler plugin.
I have integrated with Maven for reports I am using jmeter-analysis-maven-plugin.
When run tests, I am able to execute tests but not able to generate reports

It always says

[INFO] -------------------------------------------------------
[INFO] A N A L Y S I N G J M E T E R R E S U L T S
[INFO] -------------------------------------------------------
[INFO]
[INFO] Start index.
[INFO] End index.
[INFO] Analysing '20150320-SmartCare_Service_Performance.jtl'...
[INFO] Finished Parsing 0 entries.
Results file is empty.

But .jtl file is not empty.

-Sharan

bugs for jmeter-analysis-maven-plugin while parser jtl

HI,Sir:
I found some bugs in the plugin for the latest version,those occur in the following situation:
bug one:
1.while I set the "Transaction Controller" in the jmx file,the plugin parser the jtl file failed....

bug two:
1.while the jtl file contains some errors(eg:the response message gives errors.),maven build failed and the jtl file was locked by java process and can't remove until kill the java process.

Test suite errors do not show up on the HTML reports

Test suite errors do not show up on the HTML reports.
What I see instead is that when an error occurs, it seems to leave that request out of the report and so it doesn't show up on the report at all. On a test suite with 50% errors, I only see 50% of the requests on the report and they are all the successful ones.

NOTE: If I am not understanding something, does anyone know why i might experience something like this? There doesn't seem to be a jmeter property that controls showing errors or not and so I have no idea why errors are being filtered out.

[Question] How to use jmeter-analysis-maven-plugin to generate specify graph report?

Dear all,
Now I added "jmeter-analysis-maven-plugin" to my maven Jmeter project for generate the graph report, but I find that, the graph png or report is not enough to check the performance.
I would like more graph PNG in report, for example, HitsPerSecond, ThroughputVsThreads, ResponseCodesPerSecond, etc..
So how I can do it?

Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.