You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by "Amit Sela (JIRA)" <ji...@apache.org> on 2017/01/11 12:56:58 UTC

[jira] [Closed] (BEAM-1256) SparkPipelineResult.StreamingMode should not return null on awaitTermination()

     [ https://issues.apache.org/jira/browse/BEAM-1256?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Amit Sela closed BEAM-1256.
---------------------------
       Resolution: Won't Fix
    Fix Version/s: Not applicable

Seems this highly depends on BEAM-849 so I'll comment there first.

> SparkPipelineResult.StreamingMode should not return null on awaitTermination()
> ------------------------------------------------------------------------------
>
>                 Key: BEAM-1256
>                 URL: https://issues.apache.org/jira/browse/BEAM-1256
>             Project: Beam
>          Issue Type: Bug
>          Components: runner-spark
>            Reporter: Amit Sela
>            Assignee: Amit Sela
>            Priority: Minor
>             Fix For: Not applicable
>
>
> Currently, {{SparkPipelineResult.StreamingMode}} will return {{null}} if {{JavaStreamingContext#awaitTerminationOrTimeout(Long)}} returns {{false}}.
> This is wrong because this will always return {{false}} and so {{null}} because Spark's {{ContextWaiter}} will only return {{true}} if the context was stopped and this only happens after calling "awaitTermination".
> Following Spark code:
> awaitTermination returns the [state of stopped|https://github.com/apache/spark/blob/branch-1.6/streaming/src/main/scala/org/apache/spark/streaming/ContextWaiter.scala#L74]
> But can only stopped via [notifyStopped|https://github.com/apache/spark/blob/branch-1.6/streaming/src/main/scala/org/apache/spark/streaming/ContextWaiter.scala#L44]
> Which is only called by [StreamingContext#stop()|https://github.com/apache/spark/blob/branch-1.6/streaming/src/main/scala/org/apache/spark/streaming/StreamingContext.scala#L714]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)