You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by zsxwing <gi...@git.apache.org> on 2017/01/12 19:22:37 UTC

[GitHub] spark pull request #16542: [SPARK-18905][STREAMING] Fix the issue of removin...

Github user zsxwing commented on a diff in the pull request:

    https://github.com/apache/spark/pull/16542#discussion_r95864979
  
    --- Diff: streaming/src/main/scala/org/apache/spark/streaming/scheduler/JobScheduler.scala ---
    @@ -200,19 +200,19 @@ class JobScheduler(val ssc: StreamingContext) extends Logging {
         job.setEndTime(completedTime)
         listenerBus.post(StreamingListenerOutputOperationCompleted(job.toOutputOperationInfo))
         logInfo("Finished job " + job.id + " from job set of time " + jobSet.time)
    -    if (jobSet.hasCompleted) {
    -      jobSets.remove(jobSet.time)
    -      jobGenerator.onBatchCompletion(jobSet.time)
    -      logInfo("Total delay: %.3f s for time %s (execution: %.3f s)".format(
    -        jobSet.totalDelay / 1000.0, jobSet.time.toString,
    -        jobSet.processingDelay / 1000.0
    -      ))
    -      listenerBus.post(StreamingListenerBatchCompleted(jobSet.toBatchInfo))
    -    }
         job.result match {
           case Failure(e) =>
             reportError("Error running job " + job, e)
           case _ =>
    +        if (jobSet.hasCompleted) {
    +          jobSets.remove(jobSet.time)
    +          jobGenerator.onBatchCompletion(jobSet.time)
    +          logInfo("Total delay: %.3f s for time %s (execution: %.3f s)".format(
    +            jobSet.totalDelay / 1000.0, jobSet.time.toString,
    +            jobSet.processingDelay / 1000.0
    +          ))
    +          listenerBus.post(StreamingListenerBatchCompleted(jobSet.toBatchInfo))
    --- End diff --
    
    Could you also post this event for failure jobSet? Otherwise, the web UI cannot show it.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org