MaxGekk opened a new pull request #25173: [SPARK-28416][SQL] Use java.time API 
in timestampAddInterval
URL: https://github.com/apache/spark/pull/25173
 
 
   ## What changes were proposed in this pull request?
   
   The `DateTimeUtils.timestampAddInterval` method was rewritten by using Java 
8 time API. To add months and microseconds, I used the `plusMonths()` and 
`plus()` methods of `ZonedDateTime`. Also the signature of 
`timestampAddInterval()` was changed to accept an `ZoneId` instance instead of 
`TimeZone`. Using `ZoneId` allows to avoid the conversion `TimeZone` -> 
`ZoneId` on every invoke of `timestampAddInterval()`.
   
   ## How was this patch tested?
   
   By existing test suites `DateExpressionsSuite`, `TypeCoercionSuite` and 
`CollectionExpressionsSuite`.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to