Skip to content

Set timestamp time zone in parquet writer#10474

Closed
JkSelf wants to merge 8 commits intofacebookincubator:mainfrom
JkSelf:timestamp-timezone
Closed

Set timestamp time zone in parquet writer#10474
JkSelf wants to merge 8 commits intofacebookincubator:mainfrom
JkSelf:timestamp-timezone

Conversation

@JkSelf
Copy link
Copy Markdown
Collaborator

@JkSelf JkSelf commented Jul 16, 2024

When we use Gluten's Parquet write to write timestamp data, we noticed that the timestamp data read out differs by a 7-hour time zone difference compared to vanilla Spark. We observed that Spark automatically adjusts the time zone to UTC when writing timestamp data. However, Velox's Parquet write function does not make such an adjustment, due to the fact that we did not set the time zone when creating the Arrow TimestampType. To address this issue, this PR will set the time zone in the Arrow TimestampType based on the kSessionTimezone configuration.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jul 16, 2024
@netlify
Copy link
Copy Markdown

netlify bot commented Jul 16, 2024

Deploy Preview for meta-velox canceled.

Name Link
🔨 Latest commit 45ce236
🔍 Latest deploy log https://app.netlify.com/sites/meta-velox/deploys/66b151b2501d68000848615f

@JkSelf JkSelf changed the title Pass timestamp time zone into the arrow writer options Set timestamp time zone in parquet writer Jul 16, 2024
@JkSelf JkSelf force-pushed the timestamp-timezone branch 2 times, most recently from 2a4d7f1 to b6ebfaa Compare July 23, 2024 05:00
@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Jul 23, 2024

@pedroerp @jinchengchenghh Resolved all your comments. Can you help to review again? Thanks.

@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Jul 26, 2024

@pedroerp @jinchengchenghh Thanks for your review. I have resolved all your comments. Can you help to review again? Thanks.

Copy link
Copy Markdown
Contributor

@pedroerp pedroerp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few small comments, but overall looks good.

@jinchengchenghh please take one last pass when you have a moment, then I can get it merged.

@pedroerp
Copy link
Copy Markdown
Contributor

Cc: @majetideepak

@JkSelf JkSelf force-pushed the timestamp-timezone branch from 8f9d882 to 160128b Compare July 31, 2024 00:54
@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Jul 31, 2024

@jinchengchenghh @pedroerp Thanks for your review. I have resolved all your comments. Can you help to review again? Thanks.

@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Jul 31, 2024

@jinchengchenghh Can you help to review again? Thanks.

Copy link
Copy Markdown
Collaborator

@majetideepak majetideepak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look good! Just need to address the outdated code comment.

@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Aug 1, 2024

@jinchengchenghh @majetideepak @pedroerp Resolved all your comments. Can you help to review again? Thanks.

@jinchengchenghh
Copy link
Copy Markdown
Collaborator

Thanks~

@majetideepak majetideepak added the ready-to-merge PR that have been reviewed and are ready for merging. PRs with this tag notify the Velox Meta oncall label Aug 1, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

@kagamiori has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Aug 2, 2024

@kagamiori Can you help to merge? Thanks.

@kagamiori
Copy link
Copy Markdown
Contributor

Hi @JkSelf, could you please rebasing the PR onto the latest main? That would help with merging. Thanks!

@JkSelf JkSelf force-pushed the timestamp-timezone branch from 03e7bf7 to 45ce236 Compare August 5, 2024 22:26
@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Aug 5, 2024

Hi @JkSelf, could you please rebasing the PR onto the latest main? That would help with merging. Thanks!

@kagamiori Yes. Rebased to latest main. Thanks.

@facebook-github-bot
Copy link
Copy Markdown
Contributor

@kagamiori has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@JkSelf
Copy link
Copy Markdown
Collaborator Author

JkSelf commented Aug 6, 2024

@kagamiori Does the failed unit test relate with this PR?

@kagamiori
Copy link
Copy Markdown
Contributor

@kagamiori Does the failed unit test relate with this PR?

No problem. I was out of office yesterday. Merging it now.

@facebook-github-bot
Copy link
Copy Markdown
Contributor

@kagamiori merged this pull request in 9355109.

@conbench-facebook
Copy link
Copy Markdown

Conbench analyzed the 1 benchmark run on commit 93551099.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Merged ready-to-merge PR that have been reviewed and are ready for merging. PRs with this tag notify the Velox Meta oncall

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants