Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
2568a6c
Rename JobProgressPage to AllStagesPage:
JoshRosen Oct 29, 2014
4487dcb
[SPARK-4145] Web UI job pages
JoshRosen Oct 30, 2014
bfce2b9
Address review comments, except for progress bar.
JoshRosen Nov 6, 2014
4b206fb
Merge remote-tracking branch 'origin/master' into job-page
JoshRosen Nov 6, 2014
45343b8
More comments
JoshRosen Nov 6, 2014
a475ea1
Add progress bars to jobs page.
JoshRosen Nov 11, 2014
56701fa
Move last stage name / description logic out of markup.
JoshRosen Nov 11, 2014
1cf4987
Fix broken kill links; add Selenium test to avoid future regressions.
JoshRosen Nov 11, 2014
85e9c85
Extract startTime into separate variable.
JoshRosen Nov 11, 2014
4d58e55
Change label to "Tasks (for all stages)"
JoshRosen Nov 11, 2014
4846ce4
Hide "(Job Group") if no jobs were submitted in job groups.
JoshRosen Nov 12, 2014
b7bf30e
Add stages progress bar; fix bug where active stages show as completed.
JoshRosen Nov 12, 2014
8a2351b
Add help tooltip to Spark Jobs page.
JoshRosen Nov 12, 2014
3d0a007
Merge remote-tracking branch 'origin/master' into job-page
JoshRosen Nov 17, 2014
1145c60
Display text instead of progress bar for stages.
JoshRosen Nov 17, 2014
d62ea7b
Add failing Selenium test for stage overcounting issue.
JoshRosen Nov 17, 2014
79793cd
Track indices of completed stage to avoid overcounting when failures …
JoshRosen Nov 18, 2014
5884f91
Add StageInfos to SparkListenerJobStart event.
JoshRosen Nov 18, 2014
8ab6c28
Compute numTasks from job start stage infos.
JoshRosen Nov 18, 2014
8955f4c
Display information for pending stages on jobs page.
JoshRosen Nov 19, 2014
e2f2c43
Fix sorting of stages in job details page.
JoshRosen Nov 19, 2014
171b53c
Move `startTime` to the start of SparkContext.
JoshRosen Nov 19, 2014
f2a15da
Add status field to job details page.
JoshRosen Nov 19, 2014
5eb39dc
Add pending stages table to job page.
JoshRosen Nov 19, 2014
d69c775
Fix table sorting on all jobs page.
JoshRosen Nov 19, 2014
7d10b97
Merge remote-tracking branch 'apache/master' into job-page
JoshRosen Nov 20, 2014
67080ba
Ensure that "phantom stages" don't cause memory leaks.
JoshRosen Nov 20, 2014
eebdc2c
Don’t display pending stages for completed jobs.
JoshRosen Nov 20, 2014
034aa8d
Use `.max()` to find result stage for job.
JoshRosen Nov 20, 2014
0b77e3e
More bug fixes for phantom stages.
JoshRosen Nov 20, 2014
1f45d44
Incorporate a bunch of minor review feedback.
JoshRosen Nov 20, 2014
61c265a
Add “skipped stages” table; only display non-empty tables.
JoshRosen Nov 20, 2014
2bbf41a
Update job progress bar to reflect skipped tasks/stages.
JoshRosen Nov 20, 2014
6f17f3f
Only store StageInfos in SparkListenerJobStart event.
JoshRosen Nov 21, 2014
ff804cd
Don't write "Stage Ids" field in JobStartEvent JSON.
JoshRosen Nov 21, 2014
b89c258
More JSON protocol backwards-compatibility fixes.
JoshRosen Nov 21, 2014
f00c851
Fix JsonProtocol compatibility
JoshRosen Nov 21, 2014
eb05e90
Disable kill button in completed stages tables.
JoshRosen Nov 24, 2014
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Don’t display pending stages for completed jobs.
  • Loading branch information
JoshRosen committed Nov 20, 2014
commit eebdc2cb016409ae17e06b126c7459b587f1c358
5 changes: 3 additions & 2 deletions core/src/main/scala/org/apache/spark/ui/jobs/JobPage.scala
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ import scala.xml.{NodeSeq, Node}

import javax.servlet.http.HttpServletRequest

import org.apache.spark.JobExecutionStatus
import org.apache.spark.scheduler.StageInfo
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: fix import ordering

import org.apache.spark.ui.{UIUtils, WebUIPage}

/** Page showing statistics and stage list for a given job */
private[ui] class JobPage(parent: JobsTab) extends WebUIPage("job") {
private val listener = parent.listener
private val sc = parent.sc

def render(request: HttpServletRequest): Seq[Node] = {
listener.synchronized {
Expand All @@ -43,6 +43,7 @@ private[ui] class JobPage(parent: JobsTab) extends WebUIPage("job") {
s"Details for Job $jobId", content, parent)
}
val jobData = jobDataOption.get
val isComplete = jobData.status != JobExecutionStatus.RUNNING
val stages = jobData.stageIds.map { stageId =>
// This could be empty if the JobProgressListener hasn't received information about the
// stage or if the stage information has been garbage collected
Expand All @@ -55,7 +56,7 @@ private[ui] class JobPage(parent: JobsTab) extends WebUIPage("job") {
val completedStages = mutable.Buffer[StageInfo]()
val failedStages = mutable.Buffer[StageInfo]()
for (stage <- stages) {
if (stage.submissionTime.isEmpty) {
if (!isComplete && stage.submissionTime.isEmpty) {
pendingStages += stage
} else if (stage.completionTime.isDefined) {
if (stage.failureReason.isDefined) {
Expand Down
17 changes: 17 additions & 0 deletions core/src/test/scala/org/apache/spark/ui/UISeleniumSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -221,4 +221,21 @@ class UISeleniumSuite extends FunSuite with WebBrowser with Matchers {
}
}
}

test("stages that aren't run do not show up in 'pending stages' after a job finishes") {
withSpark(newSparkContext()) { sc =>
// Create an RDD that involves multiple stages:
val rdd =
sc.parallelize(Seq(1, 2, 3)).map(identity).groupBy(identity).map(identity).groupBy(identity)
// Run it twice; this will cause the second job to have two "phantom" stages that were
// mentioned in its job start event but which were never actually executed:
rdd.count()
rdd.count()
// Check that the "pending stages" section is empty:
eventually(timeout(10 seconds), interval(50 milliseconds)) {
go to (sc.ui.get.appUIAddress.stripSuffix("/") + "/jobs/job/?id=1")
find(id("pending")).get.text should be ("Pending Stages (0)")
}
}
}
}