Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TimeZone when parsing dates and times #4

Open
bcurren opened this issue Dec 11, 2014 · 2 comments
Open

TimeZone when parsing dates and times #4

bcurren opened this issue Dec 11, 2014 · 2 comments

Comments

@bcurren
Copy link

bcurren commented Dec 11, 2014

I noticed that dates are always parsed in TimeZone.getDefault(). I was going to add a configuration option that allows a user of OpenReplicator to set the TimeZone when parsing the binlog. Have you thought much about this? Do you think it's a good idea? I think it's needed but wanted to double check before submitting a pull request.

Also, I think it's necessary to always parse timestamps in UTC since MySQL converts from the local timezone to UTC an save and update.

Please let me know if you agree with my thoughts and I'll do the work.

@wanghaisheng
Copy link

@bcurren sir i encounter a datatime issue ,could you share me your solutions

@trydofor
Copy link

1.command-line: java -Duser.timezone=GMT
2.java coding: TimeZone.setDefault(TimeZone.getTimeZone("GMT"));
3.mysql [mysqld] default-time-zone = '+00:00'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants