Github user vanzin commented on a diff in the pull request:
https://github.com/apache/spark/pull/4845#discussion_r25653381
--- Diff:
core/src/main/scala/org/apache/spark/deploy/history/HistoryPage.scala ---
@@ -34,18 +37,31 @@ private[spark] class HistoryPage(parent: HistoryServer)
extends WebUIPage("") {
val requestedIncomplete =
Option(request.getParameter("showIncomplete")).getOrElse("false").toBoolean
- val allApps = parent.getApplicationList().filter(_.completed !=
requestedIncomplete)
- val actualFirst = if (requestedFirst < allApps.size) requestedFirst
else 0
- val apps = allApps.slice(actualFirst, Math.min(actualFirst + pageSize,
allApps.size))
-
+ val allCompletedAppsNAttempts =
+ parent.getApplicationList().filter(_.completed !=
requestedIncomplete)
+ val (hasAttemptInfo, appToAttemptMap) =
getApplicationLevelList(allCompletedAppsNAttempts)
--- End diff --
BTW with the map you could do:
val hasAttemptInfo = appAttempts.exists { case (k, v) => v.size > 1 }
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]