Skip to content

Commit

Permalink
get JobProgressListener directly from UI
Browse files Browse the repository at this point in the history
  • Loading branch information
squito committed Apr 1, 2015
1 parent fdfc181 commit db61211
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ private[v1] class AllStagesResource(uiRoot: UIRoot) {
@QueryParam("status") statuses: java.util.List[StageStatus]
): Seq[StageData] = {
uiRoot.withSparkUI(appId) { ui =>
val listener = ui.stagesTab.listener
val listener = ui.jobProgressListener
val stageAndStatus = AllStagesResource.stagesAndStatus(ui)
val adjStatuses = {
if (statuses.isEmpty()) {
Expand Down Expand Up @@ -118,7 +118,7 @@ private[v1] object AllStagesResource {
}

def stagesAndStatus(ui: SparkUI): Seq[(StageStatus, Seq[StageInfo])] = {
val listener = ui.stagesTab.listener
val listener = ui.jobProgressListener
listener.synchronized {
Seq(
StageStatus.Active -> listener.activeStages.values.toSeq,
Expand Down

0 comments on commit db61211

Please sign in to comment.