Re: wm.log time stamp broken?
Keats Kirsch <[email protected]> Fri, 31 Mar 2006 11:33:56 -0500
| Newsgroups | gmane.comp.java.webmacro.user |
|---|---|
| Message-ID | <[email protected]> |
I don't see the cause of this from a quick inspection, however it does appear that the LogFile.log method is not thread-safe, given Endre's recent revelation about the SimpleDateFormat. Personally, I'd vote for ripping out the WM logging completely and using a better framework like Log4J. Keats Mike Weerdenburg - de Bruin (Werk) wrote: >Hello Marcel, > >I had a look at my logfile... and I have the same problem! > >It looks like it logs with the latest startup time! > >These logs are from today... but the timestamp is from yesterday! >30-03-2006 14:47:43.812 >30-03-2006 14:47:43.812 >30-03-2006 14:47:43.812 >... Etc. etc. > > >I have done some quick testing: > >It seems like Clock.java doesn't return the correct value's. >In particular: System.currentTimeMillis() > >System.out: >------------ >System.currentTimeMillis() 1143795904156 >time 1143795904156 >TIME 1143795880312 >TIME - time -23844 >< 1000 > >System.currentTimeMillis() 1143795904156 >time 1143795904156 >TIME 1143795880312 >TIME - time -23844 >< 1000 > >System.currentTimeMillis() 1143795904156 >time 1143795904156 >TIME 1143795880312 >TIME - time -23844 >< 1000 >... Etc. etc. > >I don't have the time to sort this problem out... >But I hope it helps someone else to solve this problem! > >Greetings, >Mike > >Atatchments: >LogFile.java (Latest version! With LogFilePerDay etc.) >Clock.java (With some System.out.println's for debugging) > > >-----Oorspronkelijk bericht----- >Van: [email protected] >[mailto:[email protected]] Namens Marcello H >Verzonden: vrijdag 31 maart 2006 10:14 >Aan: [email protected] >Onderwerp: ***SPAM***[WebMacro-user] wm.log time stamp broken? > >I checked out the cvs-code this week, and found out that the time stamp >in the wm-file is almost the same on ervy hit from the same logger. > >(I must say, i didn't look at this particular thing in detail lately...) > >Do other people experience this also? > >Greetings, >Marcel Huijkman > > > > ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642