pan3793 commented on code in PR #3836:
URL: https://github.com/apache/incubator-kyuubi/pull/3836#discussion_r1030102709


##########
kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala:
##########
@@ -124,7 +124,11 @@ case class KyuubiConf(loadSysDefault: Boolean = true) 
extends Logging {
 
   /** Get all batch conf as map */
   def getBatchConf(batchType: String): Map[String, String] = {
-    
getAllWithPrefix(s"$KYUUBI_BATCH_CONF_PREFIX.${batchType.toLowerCase(Locale.ROOT)}",
 "")
+    batchType.toLowerCase(Locale.ROOT) match {
+      case "spark" | "pyspark" => 
getAllWithPrefix(s"$KYUUBI_BATCH_CONF_PREFIX.spark", "")
+      case _ =>
+        
getAllWithPrefix(s"$KYUUBI_BATCH_CONF_PREFIX.${batchType.toLowerCase(Locale.ROOT)}",
 "")
+    }

Review Comment:
   ```suggestion
       val normalizedBatchType = batchType.toLowerCase(Locale.ROOT) match {
         case "pyspark" => "spark"
         case other => other.toLowerCase(Locale.ROOT)
       }
       getAllWithPrefix(s"$KYUUBI_BATCH_CONF_PREFIX.$normalizedBatchType", "")
   ```



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