-
Notifications
You must be signed in to change notification settings - Fork 28.1k
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
[SPARK-12716] [Web UI] Add a TOTALS row to the Executors Web UI #10668
Closed
Closed
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
f0a725d
Added a TOTALS row to the executors UI
ajbozarth bbd9c0d
fixed style issue
ajbozarth 0b5ce04
Revert "Added a TOTALS row to the executors UI"
ajbozarth 8b13783
Alt version of SPARK-12716
ajbozarth 4b5f7c7
Removed unused vals and added table header
ajbozarth f1cd333
Merge branch 'master' into spark12716
ajbozarth File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,9 +62,6 @@ private[ui] class ExecutorsPage( | |
} | ||
(_storageStatusList, _execInfo) | ||
} | ||
val maxMem = storageStatusList.map(_.maxMem).sum | ||
val memUsed = storageStatusList.map(_.memUsed).sum | ||
val diskUsed = storageStatusList.map(_.diskUsed).sum | ||
val execInfoSorted = execInfo.sortBy(_.id) | ||
val logsExist = execInfo.filter(_.executorLogs.nonEmpty).nonEmpty | ||
|
||
|
@@ -100,18 +97,15 @@ private[ui] class ExecutorsPage( | |
</table> | ||
|
||
val content = | ||
<div class="row-fluid"> | ||
<div class="row"> | ||
<div class="span12"> | ||
<ul class="unstyled"> | ||
<li><strong>Memory:</strong> | ||
{Utils.bytesToString(memUsed)} Used | ||
({Utils.bytesToString(maxMem)} Total) </li> | ||
<li><strong>Disk:</strong> {Utils.bytesToString(diskUsed)} Used </li> | ||
</ul> | ||
<h4>Totals for {execInfo.size} Executors</h4> | ||
{execSummary(execInfo)} | ||
</div> | ||
</div> | ||
<div class = "row"> | ||
<div class="span12"> | ||
<h4>Active Executors</h4> | ||
{execTable} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here I diskUsed isn't be used |
||
</div> | ||
</div>; | ||
|
@@ -179,6 +173,66 @@ private[ui] class ExecutorsPage( | |
</tr> | ||
} | ||
|
||
private def execSummary(execInfo: Seq[ExecutorSummary]): Seq[Node] = { | ||
val maximumMemory = execInfo.map(_.maxMemory).sum | ||
val memoryUsed = execInfo.map(_.memoryUsed).sum | ||
val diskUsed = execInfo.map(_.diskUsed).sum | ||
val totalDuration = execInfo.map(_.totalDuration).sum | ||
val totalInputBytes = execInfo.map(_.totalInputBytes).sum | ||
val totalShuffleRead = execInfo.map(_.totalShuffleRead).sum | ||
val totalShuffleWrite = execInfo.map(_.totalShuffleWrite).sum | ||
|
||
val sumContent = | ||
<tr> | ||
<td>{execInfo.map(_.rddBlocks).sum}</td> | ||
<td sorttable_customkey={memoryUsed.toString}> | ||
{Utils.bytesToString(memoryUsed)} / | ||
{Utils.bytesToString(maximumMemory)} | ||
</td> | ||
<td sorttable_customkey={diskUsed.toString}> | ||
{Utils.bytesToString(diskUsed)} | ||
</td> | ||
<td>{execInfo.map(_.activeTasks).sum}</td> | ||
<td>{execInfo.map(_.failedTasks).sum}</td> | ||
<td>{execInfo.map(_.completedTasks).sum}</td> | ||
<td>{execInfo.map(_.totalTasks).sum}</td> | ||
<td sorttable_customkey={totalDuration.toString}> | ||
{Utils.msDurationToString(totalDuration)} | ||
</td> | ||
<td sorttable_customkey={totalInputBytes.toString}> | ||
{Utils.bytesToString(totalInputBytes)} | ||
</td> | ||
<td sorttable_customkey={totalShuffleRead.toString}> | ||
{Utils.bytesToString(totalShuffleRead)} | ||
</td> | ||
<td sorttable_customkey={totalShuffleWrite.toString}> | ||
{Utils.bytesToString(totalShuffleWrite)} | ||
</td> | ||
</tr>; | ||
|
||
<table class={UIUtils.TABLE_CLASS_STRIPED}> | ||
<thead> | ||
<th>RDD Blocks</th> | ||
<th><span data-toggle="tooltip" title={ToolTips.STORAGE_MEMORY}>Storage Memory</span></th> | ||
<th>Disk Used</th> | ||
<th>Active Tasks</th> | ||
<th>Failed Tasks</th> | ||
<th>Complete Tasks</th> | ||
<th>Total Tasks</th> | ||
<th>Task Time</th> | ||
<th><span data-toggle="tooltip" title={ToolTips.INPUT}>Input</span></th> | ||
<th><span data-toggle="tooltip" title={ToolTips.SHUFFLE_READ}>Shuffle Read</span></th> | ||
<th> | ||
<span data-toggle="tooltip" data-placement="left" title={ToolTips.SHUFFLE_WRITE}> | ||
Shuffle Write | ||
</span> | ||
</th> | ||
</thead> | ||
<tbody> | ||
{sumContent} | ||
</tbody> | ||
</table> | ||
} | ||
} | ||
|
||
private[spark] object ExecutorsPage { | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
memUsed and maxMem locals in this function aren't being used anymore so lets remove them.