You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4cxx-user@logging.apache.org by "Drapal, Myron E (Myron)" <dr...@avaya.com> on 2005/04/06 22:56:01 UTC

Relative time (%r) rolls over very quickly in PatternLayout.

It looks like there might be an issue with the RelativeTime
(milliseconds since application start) in the PatternLayout

(and maybe other places).  From my empirical tests, it seems to
roll-over in the logs at about 400000 msec (every

6.67 minutes).  See a sample below, the first field is %r, and the wall
clock time is in the message part of the log.

 

373656 [FINE] T5C5 <VServer.SYSTIME> (ThreadMain) 04/04/05 15:40:04
Mountain Daylight Time -7:00 (UTC = 21:40:04)

...

6281 [FINE] T663 <VServer.SYSTIME> (ThreadMain) 04/04/05 15:40:55
Mountain Daylight Time -7:00 (UTC = 21:40:55)

 

This doesn't make sense from looking at the code, as internally this is
an int_64 and shouldn't roll-over for a very long time.

Is this the intended behavior, or is this a bug?

 

Myron Drapal

drapal@avaya.com