You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by James Bull <jb...@thoughtworks.com> on 2005/11/11 11:22:46 UTC

Getting sample time from a variable


Hi,

I've got a jmeter web script that works fine. At the moment it writes its
results out to a file. I want to do an automated report web page that takes
it's results from a DB.

I thought after each sample has completed there might be a variable which
contains the time for the last sample that I could just pop into a jdbc
request to store the data.

Is this possible? Does such a variable exist and if so what is it called?

Thanks for reading,

James


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


Re: Getting sample time from a variable

Posted by sebb <se...@gmail.com>.
On 11/11/05, James Bull <jb...@thoughtworks.com> wrote:
>
>
> Hi,
>
> I've got a jmeter web script that works fine. At the moment it writes its
> results out to a file. I want to do an automated report web page that takes
> it's results from a DB.
>
> I thought after each sample has completed there might be a variable which
> contains the time for the last sample that I could just pop into a jdbc
> request to store the data.
>
> Is this possible? Does such a variable exist and if so what is it called?

There is no such variable at present.

You could probably persuade the BeanShell Assertion to extract the
information and put it in a variable.

However for performance testing storing the data would add quite an overhead.
Effectively you would also be testing the JDBC connection as well.

Why not just write a script to load the data into the database at the
end of a test? Most databases can easily be populated from CSV files,
and it would be much more efficient to load all the data at once.

If you really want to use a database to store the data, it would be
best implemented as a Listener. There has been some discussion on
implementing this - see the JMeter Developer list.

S.

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