-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-16520] [WEBUI] Link executors to corresponding worker pages #14204
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 6 commits
21a5abc
f2ab3a3
4d1d47f
801f8fe
1618ffe
519c329
48ae86f
4808306
11e584b
987caa3
bed0310
8743898
2d6d2f2
2732db8
11fe868
3dfd0f0
ae4794a
3680eb5
d23643c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -440,7 +440,8 @@ private[spark] object JsonProtocol { | |
| def executorInfoToJson(executorInfo: ExecutorInfo): JValue = { | ||
| ("Host" -> executorInfo.executorHost) ~ | ||
| ("Total Cores" -> executorInfo.totalCores) ~ | ||
| ("Log Urls" -> mapToJson(executorInfo.logUrlMap)) | ||
| ("Log Urls" -> mapToJson(executorInfo.logUrlMap)) ~ | ||
| ("Worker" -> mapToJson(executorInfo.workerUrl)) | ||
| } | ||
|
|
||
| /** ------------------------------ * | ||
|
|
@@ -934,7 +935,8 @@ private[spark] object JsonProtocol { | |
| val executorHost = (json \ "Host").extract[String] | ||
| val totalCores = (json \ "Total Cores").extract[Int] | ||
| val logUrls = mapFromJson(json \ "Log Urls").toMap | ||
| new ExecutorInfo(executorHost, totalCores, logUrls) | ||
| val worker = mapFromJson(json \ "Worker").toMap | ||
|
||
| new ExecutorInfo(executorHost, totalCores, logUrls, worker) | ||
| } | ||
|
|
||
| /** -------------------------------- * | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -73,13 +73,15 @@ class JsonProtocolSuite extends SparkFunSuite { | |
| BlockManagerId("Scarce", "to be counted...", 100)) | ||
| val unpersistRdd = SparkListenerUnpersistRDD(12345) | ||
| val logUrlMap = Map("stderr" -> "mystderr", "stdout" -> "mystdout").toMap | ||
| val workerUrlMap = Map("url" -> "spark://[email protected]:32790", | ||
| "ui_url" -> "http://192.168.1.104:46445").toMap | ||
|
||
| val applicationStart = SparkListenerApplicationStart("The winner of all", Some("appId"), | ||
| 42L, "Garfield", Some("appAttempt")) | ||
| val applicationStartWithLogs = SparkListenerApplicationStart("The winner of all", Some("appId"), | ||
| 42L, "Garfield", Some("appAttempt"), Some(logUrlMap)) | ||
| val applicationEnd = SparkListenerApplicationEnd(42L) | ||
| val executorAdded = SparkListenerExecutorAdded(executorAddedTime, "exec1", | ||
| new ExecutorInfo("Hostee.awesome.com", 11, logUrlMap)) | ||
| new ExecutorInfo("Hostee.awesome.com", 11, logUrlMap, workerUrlMap)) | ||
| val executorRemoved = SparkListenerExecutorRemoved(executorRemovedTime, "exec2", "test reason") | ||
| val executorMetricsUpdate = { | ||
| // Use custom accum ID for determinism | ||
|
|
@@ -1749,6 +1751,10 @@ private[spark] object JsonProtocolSuite extends Assertions { | |
| | "Log Urls" : { | ||
| | "stderr" : "mystderr", | ||
| | "stdout" : "mystdout" | ||
| | }, | ||
| | "Worker" : { | ||
| | "url" : "spark://[email protected]:32790", | ||
| | "ui_url" : "http://192.168.1.104:46445" | ||
| | } | ||
| | } | ||
| |} | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me also ping @JoshRosen about this change since it is adding a new field to
ExecutorInfo.@JoshRosen Does this change look good to you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The only concern that I see here is in binary-compatibility in the
ExecutorInfoconstructor, but that's easily fixable by adding an overloaded constructor which accepts the old arguments.