JDK-8064374 : TimeZone for Europe/Moscow
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util:i18n
  • Affected Version: 8u25
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_8
  • CPU: x86
  • Submitted: 2014-11-07
  • Updated: 2014-11-10
  • Resolved: 2014-11-10
Related Reports
Duplicate :  
Description
FULL PRODUCT VERSION :
1.7_72
1.8_25

ADDITIONAL OS VERSION INFORMATION :
Windows Server 2008 R2
Windows (.1

A DESCRIPTION OF THE PROBLEM :
Formatig a Date with SimpleDateFormater and TimeZone is Europe/Moscow
the calculation is wrong


Europe/Berlin has UTC+01:00
Europe/Moscow has UTC+03:00
2 h 

http://www.timeanddate.com/time/zones/msk

but the calculation returns a dif of 3h:
Europe/Berlin 07.11.14 10:44
Europe/Moscow 07.11.14 13:44

REGRESSION.  Last worked in version 7u72

ADDITIONAL REGRESSION INFORMATION: 
java version "1.7.0_72"
Java(TM) SE Runtime Environment (build 1.7.0_72-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.72-b04, mixed mode)

java version "1.8.0_25"
Java(TM) SE Runtime Environment (build 1.8.0_25-b18)
Java HotSpot(TM) 64-Bit Server VM (build 25.25-b02, mixed mode)

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Europe/Berlin 07.11.14 10:44
Europe/Moscow 07.11.14 12:44
ACTUAL -
Europe/Berlin 07.11.14 10:44
Europe/Moscow 07.11.14 13:44

REPRODUCIBILITY :
This bug can be reproduced always.

---------- BEGIN SOURCE ----------
final Long time = Long.valueOf(1_415_353_497_000l);

final SimpleDateFormat format = new SimpleDateFormat();
System.out.println(format.format(time));
		
format.setTimeZone(TimeZone.getTimeZone( "Europe/Berlin" ));
System.out.println(format.format(time));
		
format.setTimeZone(TimeZone.getTimeZone( "Europe/Moscow" ));
System.out.println(format.format(time));


---------- END SOURCE ----------


Comments
The Europe/Moscow change to +03:00 went to tzdata2014f. In JDK, the Moscow change is available as the tzdata2014g fixes.
10-11-2014