bowenliang123 commented on code in PR #5039:
URL: https://github.com/apache/kyuubi/pull/5039#discussion_r1271696980
##########
externals/kyuubi-spark-sql-engine/src/main/scala/org/apache/kyuubi/engine/spark/KyuubiSparkUtil.scala:
##########
@@ -95,7 +95,5 @@ object KyuubiSparkUtil extends Logging {
}
}
- // Given that we are on the Spark SQL engine side, the
[[org.apache.spark.SPARK_VERSION]] can be
- // represented as the runtime version of the Spark SQL engine.
- lazy val SPARK_ENGINE_RUNTIME_VERSION =
SemanticVersion(org.apache.spark.SPARK_VERSION)
+ lazy val sparkRuntimeVersion: SemanticVersion =
SemanticVersion(SPARK_VERSION)
Review Comment:
Let me try to summarize your suggested changes:
1. preferred uppercase for constants, eg. `SPARK_ENGINE_RUNTIME_VERSION` as
it is.
2. change to get Spark's runtime version via [JDBC query "SELECT version()"
as in
`SparkVersionUtil`](https://github.com/apache/kyuubi/blob/ecc3b4af6149ff49faff5f5360b67a6459d84856/kyuubi-common/src/test/scala/org/apache/kyuubi/util/SparkVersionUtil.scala#L30)
3. make this `SPARK_ENGINE_RUNTIME_VERSION` private and marked as visible
for testing, as it's used in tests only.
--
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]