yaooqinn commented on code in PR #46457:
URL: https://github.com/apache/spark/pull/46457#discussion_r1593465736
##########
sql/api/src/main/scala/org/apache/spark/sql/catalyst/util/SparkDateTimeUtils.scala:
##########
@@ -197,8 +197,8 @@ trait SparkDateTimeUtils {
rebaseJulianToGregorianDays(julianDays)
}
- private val zoneInfoClassName = "sun.util.calendar.ZoneInfo"
- private val getOffsetsByWallHandle = {
+ private lazy val zoneInfoClassName = "sun.util.calendar.ZoneInfo"
Review Comment:
> On the other hand, if TimeZone.getDefault.getOffset(localMillis) can be
uniformly used to get timeZoneOffset in the toJavaDate function, then the use
of the MethodHandle mechanism can be avoided here.
It seems that `ZoneInfo.getOffset` doesn't support daylight saving
transitions?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]