JMeter - Ant Integration: JTL file does not exist

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

JMeter - Ant Integration: JTL file does not exist

Saraswathi Syam
Hi Team,

I am trying to integrate JMeter with Ant to generate html reports and few graphs.

But I am getting the error as "JTL file does not exist." and unable to generate the log file also.

This is the content available in my command prompt:

Buildfile: C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\build.xml

run:
     [echo] funcMode = false
   [jmeter] Executing test plan: C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jmx ==> C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jtl

_message_xalan:

xslt-report:

BUILD FAILED
C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\build.xml:133: input file C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jtl does not exist

Total time: 3 seconds

Few forums showing that the ANT itself generates the JTL file and HTML reports and few are showing that we need to create a JTL file before starting the execution.

Do I need to generate a JTL in advance and keep that file in JMeter extras folder before starting the actual execution???

For reference I am attaching my build.xml file and screenshot of ant.

Could anyone please help me to resolve this issue.

Thanks in advance!!

Regards,
Saraswathi MNSB


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

build.xml (8K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: JMeter - Ant Integration: JTL file does not exist

shettyd
The .jtl file should have been created when your test ran - So if its not
there there is probably some issue preventing it from being created.
The build file should create a ${testpath}/${test}.log file - if thats not
getting created there is a permissions issue or incorrect path or something
like that

If you still cant figure out you might need to add debug and verbose flags
to ANT to see the exact commands getting fired and then run them manually
and see

Check your options to the build file too. And finally 2.13 is really old

from build.xml
To run a test and create the output report:
        ant -Dtest=script

    To run a test only:
        ant -Dtest=script run

    To run report on existing test output
        ant -Dtest=script report

    The "script" parameter is the name of the script without the .jmx
suffix.

    Additional options:
        -Dshow-data=y - include response data in Failure Details
        -Dtestpath=xyz - path to test file(s) (default user.dir).
                         N.B. Ant interprets relative paths against the
build file
        -Djmeter.home=.. - path to JMeter home directory (defaults to
parent of this build file)
        -Dreport.title="My Report" - title for html report (default is
'Load Test Results')


On Fri, Nov 10, 2017 at 3:17 AM, Saraswathi Syam <[hidden email]
> wrote:

> Hi Team,
>
> I am trying to integrate JMeter with Ant to generate html reports and few
> graphs.
>
> But I am getting the error as "*JTL file does not exist.*" and unable to
> generate the log file also.
>
> This is the content available in my command prompt:
>
> *Buildfile:
> C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\build.xml*
>
> *run:*
> *     [echo] funcMode = false*
> *   [jmeter] Executing test plan:
> C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jmx
> ==>
> C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jtl*
>
> *_message_xalan:*
>
> *xslt-report:*
>
> *BUILD FAILED*
> *C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\build.xml:133:
> input file
> C:\Softwares\apache-jmeter-2.13\apache-jmeter-2.13\extras\CALive_localhost_1.jtl
> does not exist*
>
> *Total time: 3 seconds*
>
> Few forums showing that the ANT itself generates the JTL file and HTML
> reports and few are showing that we need to create a JTL file before
> starting the execution.
>
> Do I need to generate a JTL in advance and keep that file in JMeter extras
> folder before starting the actual execution???
>
> For reference I am attaching my build.xml file and screenshot of ant.
>
> Could anyone please help me to resolve this issue.
>
> Thanks in advance!!
>
> Regards,
> Saraswathi MNSB
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
Reply | Threaded
Open this post in threaded view
|

Re: JMeter - Ant Integration: JTL file does not exist

glinius@live.com
In reply to this post by Saraswathi Syam
My expectation is that JMeter execution fails therefore result file is not
being generated therefore  XSLT
<https://www.w3schools.com/xml/xsl_intro.asp>   conversion from JTL to HTML
is not happening.

So I would recommend amending your *<jmeter>* Ant  target in "build.xml"
file like


>        
> <jmeter
>             jmeterhome="${jmeter.home}"
>             testplan ="${testpath}/${test}.jmx"
>             resultlog="${testpath}/${test}.jtl"
>             jmeterlogfile="${testpath}/jmeter.log>
>  

The last line will enable JMeter logging and you should see /jmeter.log/
file under ${testpath}, normally it contains all the necessary information
to get to the bottom of your test failure.

More information:

 -  JMeter Ant Task Parameters
<https://github.com/jfifield/ant-jmeter#parameters>  
 -  Five Ways To Launch a JMeter Test without Using the JMeter GUI
<https://www.blazemeter.com/blog/5-ways-launch-jmeter-test-without-using-jmeter-gui>  




--
Sent from: http://www.jmeter-archive.org/JMeter-User-f512775.html

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]