Log Message: |
AVRO-1672: Add time logical types and conversions.
This uses Joda classes to represent the new logical types:
* date => LocalDate
* time-millis => LocalTime
* time-micros => LocalTime
* timestamp-millis => DateTime
* timestamp-micros => DateTime
Joda is an optional dependency and will only be loaded if the
conversions in org.apache.avro.data.TimeConversions are referenced. By
default, no logical type conversions are enabled so there is no
additional runtime dependency for existing applications.
Microsecond types use Joda objects with millisecond precision. Because
this representation loses the microseconds, there are two conversions
for both microsecond types: a read-only conversion that will throw an
exception if used to write, and a "lossy" conversion that will write a
millisecond value as microseconds by convertsion. This is called "lossy"
because reading a microsecond value and writing it back out will lose
the microseconds.
|