LvYanquan created FLINK-36560: --------------------------------- Summary: Fix the issue of timestamp_ltz increasing by 8 hours in Paimon Key: FLINK-36560 URL: https://issues.apache.org/jira/browse/FLINK-36560 Project: Flink Issue Type: Improvement Components: Flink CDC Affects Versions: cdc-3.2.1 Reporter: LvYanquan Fix For: cdc-3.2.1 Attachments: image-2024-10-17-17-16-01-773.png
When synchronizing the timestamp field type in MySQL, it was found that the time displayed in the Paimon table was incorrect. How to reproduct: {code:java} CREATE TABLE `orders` ( order_id bigint not null primary key, user_id varchar(50) not null, shop_id bigint not null, product_id bigint not null, buy_fee bigint not null, create_time timestamp not null, update_time timestamp not null default now(), state int not null ); INSERT INTO orders VALUES (100001, 'user_001', 12345, 1, 5000, '2023-02-15 16:40:56', '2023-02-15 18:42:56', 1), (100002, 'user_002', 12346, 2, 4000, '2023-02-15 15:40:56', '2023-02-15 18:42:56', 1), (100003, 'user_003', 12347, 3, 3000, '2023-02-15 14:40:56', '2023-02-15 18:42:56', 1), (100004, 'user_001', 12347, 4, 2000, '2023-02-15 13:40:56', '2023-02-15 18:42:56', 1), (100005, 'user_002', 12348, 5, 1000, '2023-02-15 12:40:56', '2023-02-15 18:42:56', 1), (100006, 'user_001', 12348, 1, 1000, '2023-02-15 11:40:56', '2023-02-15 18:42:56', 1), (100007, 'user_003', 12347, 4, 2000, '2023-02-15 10:40:56', '2023-02-15 18:42:56', 1);{code} My yaml job is like following: source: type: mysql hostname: host port: 3306 username: flink password: xx tables: yaml_test.\.* server-id: 22600-22620 sink: type: paimon catalog.properties.metastore: filesystem catalog.properties.warehouse: xx catalog.properties.fs.oss.endpoint: xx catalog.properties.fs.oss.accessKeyId:xx catalog.properties.fs.oss.accessKeySecret: xx pipeline: name: MySQL Database to Paimon Database Currently, the result is like following: the `create_time` and `update_time` fields are no correct. ||order_id||user_id||shop_id||product_id||buy_fee||create_time||update_time||state|| |100,001|user_001|12,345|1|5,000|2023-02-16 00:40:56|2023-02-16 02:42:56|1| |100,002|user_002|12,346|2|4,000|2023-02-15 23:40:56|2023-02-16 02:42:56|1| |100,003|user_003|12,347|3|3,000|2023-02-15 22:40:56|2023-02-16 02:42:56|1| |100,004|user_001|12,347|4|2,000|2023-02-15 21:40:56|2023-02-16 02:42:56|1| |100,005|user_002|12,348|5|1,000|2023-02-15 20:40:56|2023-02-16 02:42:56|1| |100,006|user_001|12,348|1|1,000|2023-02-15 19:40:56|2023-02-16 02:42:56|1| |100,007|user_003|12,347|4|2,000|2023-02-15 18:40:56|2023-02-16 02:42:56|1| -- This message was sent by Atlassian Jira (v8.20.10#820010)