minor difference in system_time_zone (5.6)
Posted by: Ben Dishman
Date: April 17, 2020 04:59AM

We have recently upgraded our mysql-connector-java (downloaded with spring boot) and it has caused a slightly odd anomaly which I ma investigating.

Essentially it appears to be storing one of the datetimes in UTC (we are in BST so this is essentially taking an hour off the time) and when retrieving it it assumes it was stored as BST and takes another hour off. This is given as context so apologies if it doesn't go into much detail. I'm assuming we will need to go into the code and sort it out in the java and that is not what I'm asking here.

We have noticed the failing test still works on our development machines and I trying to get a clear understanding of how and where the timezones are configured. (on the working version the datetime is stored as current timezone and retrieved as UTC (an hour subtracted)).

On the dev machines (standard set up) we have 5.6.46 on Linux with a BST system datetime. Our CI environment is the same except it uses version 5.6.47. No custom settings have been made in the my.cnf.

A difference we have noticed on the servers is on the dev machines

SELECT @@global.time_zone, @@session.time_zone, @@system_time_zone;
returns SYSTEM, SYSTEM, BST
and on the CI machines it returns
SYSTEM, SYSTEM, GMT

I can't find any simple explanation for the difference. I just wondered if someone could explain in what way the mySql server may have been configured differently and how to change it ?

Options: ReplyQuote


Subject
Written By
Posted
minor difference in system_time_zone (5.6)
April 17, 2020 04:59AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.