You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by Milamber <mi...@apache.org> on 2016/04/13 21:07:20 UTC

Dashboard errors

Hello,

When I try to have a generated report from command line, if the 
directory toto don't exists:

milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ 
./jmeter -n -t 
/home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
Writing log file 
to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
An error occurred: null

If I create the directory toto:

milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ 
mkdir toto

milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ 
./jmeter -n -t 
/home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
Writing log file 
to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
Incorrect Usage:Option -101 requires -108 option
     --?
         print command line options and exit
[etc....]

Same results (Incorrect usage) with only the -e option....

Ok with -l /tmp/results.csv option that's works.

So 2 issues :

1/ if the output dir don't exists (and -l option isn't provide) : null 
exception
2/ if -l option is missing, the error message isn't very clear.


Milamber



Re: Dashboard errors

Posted by Milamber <mi...@apache.org>.
Thanks for the fixes. Works better now.

Milamber



On 14/04/2016 01:08, sebb wrote:
> On 14 April 2016 at 00:12, sebb <se...@gmail.com> wrote:
>> On 13 April 2016 at 23:55, sebb <se...@gmail.com> wrote:
>>> On 13 April 2016 at 20:07, Milamber <mi...@apache.org> wrote:
>>>> Hello,
>>>>
>>>> When I try to have a generated report from command line, if the directory
>>>> toto don't exists:
>>>>
>>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>>>> ./jmeter -n -t
>>>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>>>> Writing log file
>>>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>>>> An error occurred: null
>>>>
>>>> If I create the directory toto:
>>>>
>>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ mkdir
>>>> toto
>>>>
>>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>>>> ./jmeter -n -t
>>>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>>>> Writing log file
>>>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>>>> Incorrect Usage:Option -101 requires -108 option
>>>>      --?
>>>>          print command line options and exit
>>>> [etc....]
>>>>
>>>> Same results (Incorrect usage) with only the -e option....
>>>>
>>>> Ok with -l /tmp/results.csv option that's works.
>>>>
>>>> So 2 issues :
>>>>
>>>> 1/ if the output dir don't exists (and -l option isn't provide) : null
>>>> exception
>>>> 2/ if -l option is missing, the error message isn't very clear.
>>>>
>>> Both fixed.
>>>
>>> However, there is another problem.
>>>
>>> If the -o option is not used, the report unconditionally overwrites
>>> the default directory.
>>> That is inconsistent.
>> I thought it had, but turns out it did not ...
>>
>>> The generate report code also does something odd.
>>> I noticed that the "... end of run" message was followed by a slight
>>> pause before the CLI prompt returned.
>>> So I moved the println to the end of the testEnded() method.
>>> But then it no longer appeared.
>>> Nor does a println appear if placed after the generateReport() method.
>>> That suggests that generateReport is preventing
>>> checkForRemainingThreads from working; not good.
>> ... the problem is that if the -o option is not specified, the code
>> checks the default directory at the end of the run.
>> It then throws an IAE which is not caught by testEnded().
>>
>> The stack trace appears in the log, but the shell does not show
>> anything, unlike with the -o case
> The code now catches Exceptions thrown by the report generation, and
> prints a message.
> So at least it's a bit more obvious what has happened.
>
>> Also it seems wrong to wait until the end of the test run to complain.
>> Though the problem is recoverable; it should be possible to re-run the
>> report independently.
> I did not attempt to fix that.
>
>>>> Milamber
>>>>
>>>>


Re: Dashboard errors

Posted by sebb <se...@gmail.com>.
On 14 April 2016 at 00:12, sebb <se...@gmail.com> wrote:
> On 13 April 2016 at 23:55, sebb <se...@gmail.com> wrote:
>> On 13 April 2016 at 20:07, Milamber <mi...@apache.org> wrote:
>>> Hello,
>>>
>>> When I try to have a generated report from command line, if the directory
>>> toto don't exists:
>>>
>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>>> ./jmeter -n -t
>>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>>> Writing log file
>>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>>> An error occurred: null
>>>
>>> If I create the directory toto:
>>>
>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ mkdir
>>> toto
>>>
>>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>>> ./jmeter -n -t
>>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>>> Writing log file
>>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>>> Incorrect Usage:Option -101 requires -108 option
>>>     --?
>>>         print command line options and exit
>>> [etc....]
>>>
>>> Same results (Incorrect usage) with only the -e option....
>>>
>>> Ok with -l /tmp/results.csv option that's works.
>>>
>>> So 2 issues :
>>>
>>> 1/ if the output dir don't exists (and -l option isn't provide) : null
>>> exception
>>> 2/ if -l option is missing, the error message isn't very clear.
>>>
>>
>> Both fixed.
>>
>> However, there is another problem.
>>
>> If the -o option is not used, the report unconditionally overwrites
>> the default directory.
>> That is inconsistent.
>
> I thought it had, but turns out it did not ...
>
>> The generate report code also does something odd.
>> I noticed that the "... end of run" message was followed by a slight
>> pause before the CLI prompt returned.
>> So I moved the println to the end of the testEnded() method.
>> But then it no longer appeared.
>> Nor does a println appear if placed after the generateReport() method.
>> That suggests that generateReport is preventing
>> checkForRemainingThreads from working; not good.
>
> ... the problem is that if the -o option is not specified, the code
> checks the default directory at the end of the run.
> It then throws an IAE which is not caught by testEnded().
>
> The stack trace appears in the log, but the shell does not show
> anything, unlike with the -o case

The code now catches Exceptions thrown by the report generation, and
prints a message.
So at least it's a bit more obvious what has happened.

> Also it seems wrong to wait until the end of the test run to complain.
> Though the problem is recoverable; it should be possible to re-run the
> report independently.

I did not attempt to fix that.

>>> Milamber
>>>
>>>

Re: Dashboard errors

Posted by sebb <se...@gmail.com>.
On 13 April 2016 at 23:55, sebb <se...@gmail.com> wrote:
> On 13 April 2016 at 20:07, Milamber <mi...@apache.org> wrote:
>> Hello,
>>
>> When I try to have a generated report from command line, if the directory
>> toto don't exists:
>>
>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>> ./jmeter -n -t
>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>> Writing log file
>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>> An error occurred: null
>>
>> If I create the directory toto:
>>
>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ mkdir
>> toto
>>
>> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
>> ./jmeter -n -t
>> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
>> Writing log file
>> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
>> Incorrect Usage:Option -101 requires -108 option
>>     --?
>>         print command line options and exit
>> [etc....]
>>
>> Same results (Incorrect usage) with only the -e option....
>>
>> Ok with -l /tmp/results.csv option that's works.
>>
>> So 2 issues :
>>
>> 1/ if the output dir don't exists (and -l option isn't provide) : null
>> exception
>> 2/ if -l option is missing, the error message isn't very clear.
>>
>
> Both fixed.
>
> However, there is another problem.
>
> If the -o option is not used, the report unconditionally overwrites
> the default directory.
> That is inconsistent.

I thought it had, but turns out it did not ...

> The generate report code also does something odd.
> I noticed that the "... end of run" message was followed by a slight
> pause before the CLI prompt returned.
> So I moved the println to the end of the testEnded() method.
> But then it no longer appeared.
> Nor does a println appear if placed after the generateReport() method.
> That suggests that generateReport is preventing
> checkForRemainingThreads from working; not good.

... the problem is that if the -o option is not specified, the code
checks the default directory at the end of the run.
It then throws an IAE which is not caught by testEnded().

The stack trace appears in the log, but the shell does not show
anything, unlike with the -o case

Also it seems wrong to wait until the end of the test run to complain.
Though the problem is recoverable; it should be possible to re-run the
report independently.

>> Milamber
>>
>>

Re: Dashboard errors

Posted by sebb <se...@gmail.com>.
On 13 April 2016 at 20:07, Milamber <mi...@apache.org> wrote:
> Hello,
>
> When I try to have a generated report from command line, if the directory
> toto don't exists:
>
> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
> ./jmeter -n -t
> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
> Writing log file
> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
> An error occurred: null
>
> If I create the directory toto:
>
> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$ mkdir
> toto
>
> milamber@ender:~/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin$
> ./jmeter -n -t
> /home/milamber/Documents/5-Docs/JMETER_MODELES/Simple_blog.jmx -e -o toto
> Writing log file
> to:/home/milamber/temp/jmetertemp/dist/apache-jmeter-3.0-SNAPSHOT/bin/jmeter.log
> Incorrect Usage:Option -101 requires -108 option
>     --?
>         print command line options and exit
> [etc....]
>
> Same results (Incorrect usage) with only the -e option....
>
> Ok with -l /tmp/results.csv option that's works.
>
> So 2 issues :
>
> 1/ if the output dir don't exists (and -l option isn't provide) : null
> exception
> 2/ if -l option is missing, the error message isn't very clear.
>

Both fixed.

However, there is another problem.

If the -o option is not used, the report unconditionally overwrites
the default directory.
That is inconsistent.

The generate report code also does something odd.
I noticed that the "... end of run" message was followed by a slight
pause before the CLI prompt returned.
So I moved the println to the end of the testEnded() method.
But then it no longer appeared.
Nor does a println appear if placed after the generateReport() method.
That suggests that generateReport is preventing
checkForRemainingThreads from working; not good.

> Milamber
>
>