JDK-4208984 : Win32: Wrong default timezone in Melbourne Australia
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util:i18n
  • Affected Version: 1.1.7,1.2.0
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_98,windows_nt
  • CPU: x86
  • Submitted: 1999-02-04
  • Updated: 1999-08-23
  • Resolved: 1999-08-23
Related Reports
Duplicate :  
Relates :  
Relates :  
Description

Name: gsC80088			Date: 02/04/99


new Date() is out by 1 hour because of a DST error.

I'm running in Melbourne, Australia. Melbourne has the same
DST rules as Sydney, Australia. These are different from those
for Brisbane, Australia: Brisbane doesn't have DST;
Melbourne and Sydney do.

My NT timezone is set to GMT+10 (Australia/Brisbane+Sydney+Melbourne).

The following program demonstrates that user.timezone is being
set to Australia/Brisbane instead of Australia/Sydney, which means
that new Date() is out by 1 hour - it's not DST-adjusted and it
should be.

This used to work in JDK 1.1 because all of eastern Australia
was in AET. This of course was wrong for Brisbane!

public class Timezone
{
 public static void main(String[] args)
 {
  System.out.println("user.timezone="+System.getProperties().getProperty("user.timezone"));
 }
}

Output:

user.timezone=Australia/Brisbane

As Melbourne and Sydney are the two biggest cities and are
in the two most populous states (Victoria and NSW respectively),
the JDK 1.1 error was marginally preferable to the JDK 1.2 error.
(Review ID: 48539)
======================================================================

Comments
WORK AROUND Name: gsC80088 Date: 02/04/99 java -Duser.timezone=Australia/Melbourne, or System.getProperties().put(...) This is only usable if the application only runs in Victoria or NSW, or somehow knows where it's running. Not very useful for us as our application is run all over the world. ======================================================================
11-06-2004

EVALUATION There is some mapping problem of timezone from windows control panel info to java default. See 4252829. koushi.takahashi@japan 1999-07-23 The fix will be provided via 4252829. koushi.takahashi@japan 1999-08-20
23-07-1999