shahidki31 commented on a change in pull request #26378:
[SPARK-29724][SPARK-29726][WEBUI][SQL] Support JDBC/ODBC tab for HistoryServer
WebUI
URL: https://github.com/apache/spark/pull/26378#discussion_r351050042
##########
File path:
core/src/main/scala/org/apache/spark/deploy/history/FsHistoryProvider.scala
##########
@@ -352,17 +352,36 @@ private[history] class FsHistoryProvider(conf:
SparkConf, clock: Clock)
val ui = SparkUI.create(None, new HistoryAppStatusStore(conf, kvstore),
conf, secManager,
app.info.name, HistoryServer.getAttemptURI(appId,
attempt.info.attemptId),
attempt.info.startTime.getTime(), attempt.info.appSparkVersion)
- loadPlugins().foreach(_.setupUI(ui))
-
+ setupPluginUI(ui)
val loadedUI = LoadedAppUI(ui)
-
synchronized {
activeUIs((appId, attemptId)) = loadedUI
}
Some(loadedUI)
}
+ private def setupPluginUI(ui: SparkUI): Unit = {
+ val plugins = loadPlugins().toSeq
+
+ var sqlTab: Option[AppHistoryServerPlugin] = None
+ var jdbcTab: Option[AppHistoryServerPlugin] = None
+ val otherTabs: Seq[AppHistoryServerPlugin] = Seq()
+
+ plugins.foreach{ plugin =>
+ if (plugin.toString.contains("SQLHistoryServerPlugin")) {
Review comment:
Seems the class name change won't help here. I am not sure any better way
than this.
Earlier I did `loadPlugins().toSeq.reverse.foreach(_.setupUI(ui))`, which
also worked.

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