bowenliang123 commented on code in PR #5115:
URL: https://github.com/apache/kyuubi/pull/5115#discussion_r1280229165


##########
externals/kyuubi-spark-sql-engine/src/main/scala/org/apache/kyuubi/engine/spark/operation/SparkOperation.scala:
##########
@@ -50,7 +50,7 @@ abstract class SparkOperation(session: Session)
 
   private val timeZone: ZoneId = {
     spark.conf.getOption(TIMEZONE_KEY).map { timeZoneId =>
-      ZoneId.of(timeZoneId.replaceFirst("(\\+|\\-)(\\d):", "$10$2:"), 
ZoneId.SHORT_IDS)
+      ZoneId.of(timeZoneId.replaceFirst("([+\\-])(\\d):", "$10$2:"), 
ZoneId.SHORT_IDS)

Review Comment:
   all right. But I could not understan why or in what circumstance that the 
replacement should be `"$10$2:"` rather than padding 0 in the front as  
`"0$1$2:"`



##########
externals/kyuubi-spark-sql-engine/src/main/scala/org/apache/kyuubi/engine/spark/operation/SparkOperation.scala:
##########
@@ -50,7 +50,7 @@ abstract class SparkOperation(session: Session)
 
   private val timeZone: ZoneId = {
     spark.conf.getOption(TIMEZONE_KEY).map { timeZoneId =>
-      ZoneId.of(timeZoneId.replaceFirst("(\\+|\\-)(\\d):", "$10$2:"), 
ZoneId.SHORT_IDS)
+      ZoneId.of(timeZoneId.replaceFirst("([+\\-])(\\d):", "$10$2:"), 
ZoneId.SHORT_IDS)

Review Comment:
   all right. But I could not understand why or in what circumstance that the 
replacement should be `"$10$2:"` rather than padding 0 in the front as  
`"0$1$2:"`



-- 
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]

Reply via email to