This is an automated email from the ASF dual-hosted git repository.
dongjoon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/master by this push:
new 062522e96a50 [SPARK-46967][CORE][UI] Hide `Thread Dump` and `Heap
Histogram` of `Dead` executors in `Executors` UI
062522e96a50 is described below
commit 062522e96a50b8b46b313aae62668717ba88639f
Author: Dongjoon Hyun <[email protected]>
AuthorDate: Sat Feb 3 19:17:33 2024 -0800
[SPARK-46967][CORE][UI] Hide `Thread Dump` and `Heap Histogram` of `Dead`
executors in `Executors` UI
### What changes were proposed in this pull request?
This PR aims to hide `Thread Dump` and `Heap Histogram` links of `Dead`
executors in Spark Driver `Executors` UI.
**BEFORE**

**AFTER**

### Why are the changes needed?
Since both `Thread Dump` and `Heap Histogram` requires a live JVM, those
links are broken and leads to the following pages.
**Broken Thread Dump Link**

**Broken Heap Histogram Link**

We had better hide them.
### Does this PR introduce _any_ user-facing change?
Yes, but this PR only hides the broken links.
### How was this patch tested?
Manual.
### Was this patch authored or co-authored using generative AI tooling?
No.
Closes #45009 from dongjoon-hyun/SPARK-46967.
Authored-by: Dongjoon Hyun <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
---
.../main/resources/org/apache/spark/ui/static/executorspage.js | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git
a/core/src/main/resources/org/apache/spark/ui/static/executorspage.js
b/core/src/main/resources/org/apache/spark/ui/static/executorspage.js
index 41164c7997bb..1b02fc0493e7 100644
--- a/core/src/main/resources/org/apache/spark/ui/static/executorspage.js
+++ b/core/src/main/resources/org/apache/spark/ui/static/executorspage.js
@@ -587,14 +587,16 @@ $(document).ready(function () {
{name: 'executorLogsCol', data: 'executorLogs', render:
formatLogsCells},
{
name: 'threadDumpCol',
- data: 'id', render: function (data, type) {
- return type === 'display' ? ("<a
href='threadDump/?executorId=" + data + "'>Thread Dump</a>" ) : data;
+ data: function (row) { return row.isActive ? row.id : '' },
+ render: function (data, type) {
+ return data != '' && type === 'display' ? ("<a
href='threadDump/?executorId=" + data + "'>Thread Dump</a>" ) : data;
}
},
{
name: 'heapHistogramCol',
- data: 'id', render: function (data, type) {
- return type === 'display' ? ("<a
href='heapHistogram/?executorId=" + data + "'>Heap Histogram</a>") : data;
+ data: function (row) { return row.isActive ? row.id : '' },
+ render: function (data, type) {
+ return data != '' && type === 'display' ? ("<a
href='heapHistogram/?executorId=" + data + "'>Heap Histogram</a>") : data;
}
},
{
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]