From 6a684a7c94a111558438ce962eba7994b09d3cbe Mon Sep 17 00:00:00 2001 From: Mingliang Zhu Date: Tue, 12 Nov 2024 13:38:04 +0800 Subject: [PATCH] [GLUTEN-7890][UI] Optimize cleanup gluten sql executions ui data (#7891) --- .../spark/sql/execution/ui/GlutenSQLAppStatusListener.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gluten-ui/src/main/scala/org/apache/spark/sql/execution/ui/GlutenSQLAppStatusListener.scala b/gluten-ui/src/main/scala/org/apache/spark/sql/execution/ui/GlutenSQLAppStatusListener.scala index 25150ca31f9f..a2f608f64d2e 100644 --- a/gluten-ui/src/main/scala/org/apache/spark/sql/execution/ui/GlutenSQLAppStatusListener.scala +++ b/gluten-ui/src/main/scala/org/apache/spark/sql/execution/ui/GlutenSQLAppStatusListener.scala @@ -32,7 +32,7 @@ private class GlutenSQLAppStatusListener(conf: SparkConf, kvstore: ElementTracki private val executionIdToDescription = new mutable.HashMap[Long, String] private val executionIdToFallbackEvent = new mutable.HashMap[Long, GlutenPlanFallbackEvent] - kvstore.addTrigger(classOf[SQLExecutionUIData], conf.get[Int](UI_RETAINED_EXECUTIONS)) { + kvstore.addTrigger(classOf[GlutenSQLExecutionUIData], conf.get[Int](UI_RETAINED_EXECUTIONS)) { count => cleanupExecutions(count) } @@ -71,7 +71,7 @@ private class GlutenSQLAppStatusListener(conf: SparkConf, kvstore: ElementTracki fallbackEvent.get.physicalPlanDescription, fallbackEvent.get.fallbackNodeToReason.toSeq.sortBy(_._1) ) - kvstore.write(uiData) + kvstore.write(uiData, checkTriggers = true) executionIdToFallbackEvent.remove(event.executionId) } executionIdToDescription.put(event.executionId, event.description)