[ 
https://issues.apache.org/jira/browse/AVRO-739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14090571#comment-14090571
 ] 

Dmitry Kovalev commented on AVRO-739:
-------------------------------------

bq. My vote is to require milliseconds in the string representations for both 
time-millis and timestamp-millis to solve the problem. 
Sure

bq. The interval type needs to specify the endianness of its components. 
Parquet uses little-endian, so I'd say we should specify that here also.
Could you suggest the wording? Bearing in mind that Avro specifies binary and 
JSON encodings for each type

bq. I'd rather not include representations that have a time zone because the 
logic is always tricky and changes. I think best practice is to convert to UTC 
and I'd like for people to do that rather than using an expensive 
representation to get around best practice.
I assume you are referring to datetime-timezone type? This is not another 
representation of timestamp-millis (where it already allows UTC only) - this is 
smth different. Consider for example a financial product whose definition says 
that it "ceases to trade on YYYY-MM-DD hh:mm Moscow time". It you convert it to 
UTC and store in a timestamp-millis, and on the next day the Russian 
authorities change the offset or daylight saving rules (which they did a few 
times in last decade) - you will end up with wrong expiration time (and 
potentially date). I think some zones like Israel adjust the rules every year. 
If you store timezone id with the "local" date-time in that zone - you can use 
the open database maintained by IANA to adjust.  So the point of this type is 
exactly that it is required when you cannot just convert to UTC and have to 
embrace the trickiness and mutability of timezones. Both components (date-time 
and timezone id) are pretty standard.



> Add Date/Time data types
> ------------------------
>
>                 Key: AVRO-739
>                 URL: https://issues.apache.org/jira/browse/AVRO-739
>             Project: Avro
>          Issue Type: New Feature
>          Components: spec
>            Reporter: Jeff Hammerbacher
>             Fix For: 1.7.8
>
>         Attachments: AVRO-739-datetime-spec.xml.patch, AVRO-739.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to