You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by "Wen, Fred TRAN:EX" <Fr...@gov.bc.ca> on 2009/07/02 19:56:09 UTC

how to detect end of thread/test in beanshell listener script?

I use jmeter for function testing purpose (i.e. one thread loops once)
on a sequence of http samplers. So to me end of test/thread are the
same. I want to use beanshell listener to write something to stdout at
the end of the test. I've tried ctx.ThreadGroup.isDone() or
ctx.ThreadGroup.next() but they cannot distinguish if the listener is
invoked at the last sampler. 
Is there any way to achieve my objective?

Thanks
Fred Wen



Re: how to detect end of thread/test in beanshell listener script?

Posted by sebb <se...@gmail.com>.
2009/7/2 Wen, Fred TRAN:EX <Fr...@gov.bc.ca>:
> I use jmeter for function testing purpose (i.e. one thread loops once)
> on a sequence of http samplers. So to me end of test/thread are the
> same. I want to use beanshell listener to write something to stdout at
> the end of the test. I've tried ctx.ThreadGroup.isDone() or
> ctx.ThreadGroup.next() but they cannot distinguish if the listener is
> invoked at the last sampler.
> Is there any way to achieve my objective?

Why not use a final BeanShell sampler to write the message instead?

> Thanks
> Fred Wen
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org