org.eclipse.rap
org.eclipse.rap copied to clipboard
org.eclipse.rap.rwt.client.service.ClientInfo.getClientTimezoneOffset() returns invalid value after a daylight saving change
The RAP framework's service method org.eclipse.rap.rwt.client.service.ClientInfo.getTimezoneOffset() from
Bug 329007 and Bug 390435
returns a wrong value after there was a daylight saving transition with a change of the time zone offset.
The timezoneOffset field from org.eclipse.rap.rwt.internal.client.ClientInfoImpl
is set only once in the very first RWT message request of a UI session.
RWTMessageHandler.workAroundMissingReadData does a check, if it is the initial request with counter 0.
Example: In time zone Europe/Berlin there is a daylight saving change on October 29, 2023. After the switch from 02:59:59 to 02:00:00 the offset to UTC changes from 2 hours to 1 hour.
If a UI session was started before 02:59:59 in summer time (UTC+02:00),
getClientTimezoneOffset() correctly returns -120 minutes.
But after the switch to 02:00:00 (UTC+01:00), it still returns -120 minutes, whereas -60 minutes would be the correct value.