jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <>
Subject Re: timestamps out of sync with system clock
Date Tue, 09 Nov 2010 14:55:31 GMT
On 9 November 2010 12:43, Andrej van der Zee <> wrote:
> Hi,
> We experienced that JMeter's timestamps get out-of-sync with the
> system clock. Is it true that JMeter does not read the system clock,
> but uses performance counters or something like that to calculate the
> difference between the start time and the current time? If so, can I
> overwrite this behavior and force JMeter to use the system clock
> instead? The platform is Windows XP.

JMeter saves both System.currentTimeMillis() and System.nanoTime() at
the start of a run.

It then uses System.nanoTime()  differences to arrive at the current
time with a resolution of 1ms.

System.nanoTime() Javadoc says "The value returned represents
nanoseconds since some fixed but arbitrary time".

If this is not true, or if the nanosecond clock is not very accurate,
then of course the JMeter timestamps can drift.

Are you running in a virtual environment? Some are known to have timer issues.

There's no option to change the JMeter behaviour currently, but of
course you can always edit the source, in this case

And you can raise a Bugzilla enhancement request to make the use of
nanoTime optional.

> Thank you,
> Andrej
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message