-
Bug
-
Resolution: Done
-
Critical
-
0.5
-
None
Timestamp field in mysql is parsed as ZonedDateTime in DBZ, but with different TZ, the date time is always the UTC time.
For me, the MySQL TZ is Asia/Shanghai (+08:00), a timestamp field '2017/03/14 18:07:52' is stored as epoch seconds 1489486072, which is '2017/3/14 10:07:52 UTC'.
After parsed by debezium, the time is '2017/03/14 10:07:52+08:00', which is wrong and should be '2017/03/14 18:07:52+08:00'.
Debug shows that when parsed by RowDesrializers, first the epoch seconds is retrieved from binlog, and convert to UTC time ('2017/03/14 10:07:52'). Then, TZ info is added, but the ZonedDateTime.of(LocalDateTime, ZoneId) just add TZ to date time but not handle the time offset.
- is related to
-
DBZ-491 Failing unit tests when run in EST timezone
- Closed