AngersZhuuuu commented on a change in pull request #25729:
[SPARK-29022][SQL][test-hadoop3.2][test-java11] Fix spark 'add jar',
CliSessionState's hiveConf 's classLoader ClassNotFound
URL: https://github.com/apache/spark/pull/25729#discussion_r329354600
##########
File path:
sql/hive/src/main/scala/org/apache/spark/sql/hive/client/HiveClientImpl.scala
##########
@@ -145,6 +145,20 @@ private[hive] class HiveClientImpl(
warehouseDir.foreach { dir =>
ret.getConf.setVar(ConfVars.METASTOREWAREHOUSE, dir)
}
+ // Since in jdk11, when HiveClient's withHiveSate, it will set
ThreadLocal SessionState,
+ // In HiveThriftServer2, it will call
HiveUtils.newClientForExecution() to get a client
+ // for Execution, then that method will trigger here to execute, in
that case we can't reset
+ // ret.getConf's ClassLoader.
+ if (HiveUtils.isCliSessionState) {
Review comment:
@srowen @wangyum
Some special point for jdk11. Need to add more explanation?
----------------------------------------------------------------
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]