Time zones are driving me CRAZY
Time zones are driving me CRAZY
- Subject: Time zones are driving me CRAZY
- From: "Pierre Bernard" <email@hidden>
- Date: Thu, 13 Nov 2003 15:26:40 +0100
- Thread-topic: JavaClient performance vs. JDK 1.4.1
Hi!
Since updating to WO 5.2.2 on JDK 1.4.1_05-b01 on Windows & Solaris, we are seeing an impressive number of various and most mysterious prombles with date / timestamp related operations.
1. I recently sent a message to this mailing list asking about other developer's experience with the performance of JavaClient after the update. We are experiencing a very noticeable slowdown. We since have trace down the performance bottleneck to a private Sun class named ZoneInfoFile. Indeed, the components most affected by the sudden drop in speed display lots of timestamps. ZoneInfoFile kicks in for each timestamp that is paresed or formatted. Our current working hypothesis is that that class does attempt lazy initialization but fails to read the timezone file. It thus goes to do a filesystem access each time a timestamp is used in some way.
2. As I recently mentionned here, I am seeing problems with date string parsing when I have set the default time zone to an instance of NSTimeZone. In some frequent situations working with dates, especially parsing, leads to wrong results. I can't yet determine if there is a pattern to this behavior. The workaround here is to use a standard TimeZone.
3. Well, with a standard TimeZone date string parsing seems fine (albeit slow). That is until I attempt to parse a date that is way in the past. Then the offset seems to be wrong. Parsing and the formatting a date does not lead back to the original string. What's odd is that the date in time that acts as border between dates parsed correctly and dates parsed incorrectly does not seem to be consistent. On one setup we observed it to be in January 1917, another test points to June 1916 and yet another one parses dates fine back until January 1905.
I suspect ZoneInfoFile to be the root cause of the trouble, but yet have a lot of chasing down to do. What's odd is that I can't find mention of similar bugs in Sun's bug database.
Pierre.
**********************************************************************
This email and any files transmitted with it are intended solely for
the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the sender
of this message. (email@hidden)
This email message has been checked for the presence of computer
viruses; however this protection does not ensure this message is
virus free.
Banque centrale du Luxembourg; Tel ++352-4774-1; http://www.bcl.lu
**********************************************************************
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.