e-mhui opened a new pull request, #7187:
URL: https://github.com/apache/inlong/pull/7187

   ### Prepare a Pull Request
   
   Fix time zone incorrect.
   
   - Fixes #7186 
   
   ### Motivation
   
   The data with datetime and timestamp format are written to iceberg, and the 
time zone is incorrect.
   
   ### Modifications
   
   1. timestamp without timezone: get his timestamp directly without any time 
zone.
   
   ```java
   TimestampData.fromEpochMillis(Timestamp.valueOf(LocalDateTime.of(localDate, 
localTime)).getTime());
   ```
   
   3. timestamp with timezone: use local time zone
   
   ```java
   TimestampData.fromInstant(
                   LocalDateTime.of(localDate, 
localTime).atZone(ZoneId.systemDefault()).toInstant());
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to