@@ -315,7 +315,7 @@ abstract class SparkEngineConnExecutor(val sc: SparkContext, id: Long)
315315 )
316316
317317 if (! isSpark3) {
318- logger.warn (s " Spark executor params setting is only supported in Spark3 engine " )
318+ logger.info (s " Spark executor params setting is only supported in Spark3 engine " )
319319 return
320320 }
321321
@@ -329,26 +329,29 @@ abstract class SparkEngineConnExecutor(val sc: SparkContext, id: Long)
329329 var skippedParams = 0
330330 var successCount = 0
331331 var failCount = 0
332- logger.info(
333- s " Spark executor params setting begin "
334- )
335- sc.getConf.getAll.foreach { case (key, value) =>
336- totalParams += 1
337- if (excludeParams.contains(key)) {
338- logger.info(
339- s " Spark executor params $key will be excluded and will not be set. "
340- )
341- skippedParams += 1
342- } else {
343- Utils .tryCatch {
344- sc.setLocalProperty(key, value)
345- successCount += 1
346- } { case e : Exception =>
347- logger.warn(s " Failed to set spark param: $key, error: ${e.getMessage}" , e)
348- failCount += 1
332+ logger.info(s " Spark executor params setting begin " )
333+ this
334+ .asInstanceOf [SparkSqlExecutor ]
335+ .getSparkEngineSession
336+ .sparkSession
337+ .sessionState
338+ .conf
339+ .getAllConfs
340+ .foreach { case (key, value) =>
341+ totalParams += 1
342+ if (excludeParams.contains(key)) {
343+ logger.info(s " Spark executor params $key will be excluded and will not be set. " )
344+ skippedParams += 1
345+ } else {
346+ Utils .tryCatch {
347+ sc.setLocalProperty(key, value)
348+ successCount += 1
349+ } { case e : Exception =>
350+ logger.warn(s " Failed to set spark param: $key, error: ${e.getMessage}" , e)
351+ failCount += 1
352+ }
349353 }
350354 }
351- }
352355
353356 logger.info(
354357 s " Spark executor params setting completed - total: $totalParams, " +
0 commit comments