-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Add support for (UT/UTC/GMT)(+/-)H[H] time zone IDs in from_unixtime and at_timezone Presto UDFs #11411
Conversation
This pull request was exported from Phabricator. Differential Revision: D65366170 |
✅ Deploy Preview for meta-velox canceled.
|
…and at_timezone Presto UDFs (facebookincubator#11411) Summary: Presto Java and Joda support time zone IDs that look like UT+1, UTC-12, GMT+3, Etc/UT-1, Etc/UTC+7, Etc/GMT-2. Of these Velox only supports the Etc/GMT prefix. This diff adds support for all 6. They all map to the offset number of hours in the suffix (except Etc/GMT which flips the sign for some reason). E.g. UT+1 maps to +01:00, while Etc/GMT-2 maps to +02:00. Differential Revision: D65366170
d095619
to
68b728e
Compare
This pull request was exported from Phabricator. Differential Revision: D65366170 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @kevinwilfong
Hi @kevinwilfong, Could you take a look at this PR #11114? I am currently developing timezone normalization for Spark, which includes all the timezones supported by Spark (In the description). Could you help to see which of these are supported by Presto? If they are also supported by Presto, I can add them to the common call section for both Presto and Spark. If there are timezone formats that Presto does not support, I think they can also be added to the normalization rules. The timezone formats supported by Velox can be the union of those supported by both Presto and Spark, which would not impact user usage. |
I agree. The current timezone normalization in |
This pull request has been merged in 7fde3c6. |
Conbench analyzed the 1 benchmark run on commit There were no benchmark performance regressions. 🎉 The full Conbench report has more details. |
Summary:
Presto Java and Joda support time zone IDs that look like UT+1, UTC-12, GMT+3, Etc/UT-1,
Etc/UTC+7, Etc/GMT-2. Of these Velox only supports the Etc/GMT prefix. This diff adds support for
all 6.
They all map to the offset number of hours in the suffix (except Etc/GMT which flips the sign
for some reason). E.g. UT+1 maps to +01:00, while Etc/GMT-2 maps to +02:00.
Differential Revision: D65366170