You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by gaborgsomogyi <gi...@git.apache.org> on 2018/11/27 13:53:46 UTC

[GitHub] spark pull request #23156: [SPARK-24063][SS] Add maximum epoch queue thresho...

GitHub user gaborgsomogyi opened a pull request:

    https://github.com/apache/spark/pull/23156

    [SPARK-24063][SS] Add maximum epoch queue threshold for ContinuousExecution

    ## What changes were proposed in this pull request?
    
    Continuous processing is waiting on epochs which are not yet complete (for example one partition is not making progress) and stores pending items in queues. These queues are unbounded and can consume up all the memory easily. In this PR I've added `spark.sql.streaming.continuous.epochBacklogQueueSize` configuration possibility to make them bounded. If the related threshold reached then the query will stop with `IllegalStateException`.
    
    ## How was this patch tested?
    
    Existing + additional unit tests.


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/gaborgsomogyi/spark SPARK-24063

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/23156.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #23156
    
----
commit 72733c5068d85e70e0a65b05a593c82120277622
Author: Gabor Somogyi <ga...@...>
Date:   2018-11-22T20:45:37Z

    [SPARK-24063][SS] Add maximum epoch queue threshold for ContinuousExecution.

----


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Merged build finished. Test PASSed.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    I thought this part is not affected. Who leads it? Asking it because haven't seen progress anywhere.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    cc @jose-torres @HeartSaVioR 


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    **[Test build #99328 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/99328/testReport)** for PR 23156 at commit [`72733c5`](https://github.com/apache/spark/commit/72733c5068d85e70e0a65b05a593c82120277622).


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by HeartSaVioR <gi...@git.apache.org>.
Github user HeartSaVioR commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    I think @jose-torres previously led the feature.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Ah, ok. This solution was agreed with him on https://github.com/apache/spark/pull/20936.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Can one of the admins verify this patch?


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    **[Test build #99328 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/99328/testReport)** for PR 23156 at commit [`72733c5`](https://github.com/apache/spark/commit/72733c5068d85e70e0a65b05a593c82120277622).
     * This patch passes all tests.
     * This patch merges cleanly.
     * This patch adds no public classes.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Test PASSed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/99822/
    Test PASSed.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by HeartSaVioR <gi...@git.apache.org>.
Github user HeartSaVioR commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    I'd rather not jumping in something regarding continuous mode unless the overall design (including aggregation and join) of continuous mode is cleared and stabilized.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by arunmahadevan <gi...@git.apache.org>.
Github user arunmahadevan commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    @gaborgsomogyi what I meant was rather than exposing a config to control the internal queue sizes, we could have a higher level config like the max pending epochs. This would act as a back pressure mechanism to stop further processing until the pending epochs are committed. I assume this would also put a limit on the three queues.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Can one of the admins verify this patch?


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    **[Test build #99822 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/99822/testReport)** for PR 23156 at commit [`b0c5056`](https://github.com/apache/spark/commit/b0c505676dcd207debb3e8483ef9bc20c25b03ac).
     * This patch passes all tests.
     * This patch merges cleanly.
     * This patch adds no public classes.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Merged build finished. Test PASSed.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by arunmahadevan <gi...@git.apache.org>.
Github user arunmahadevan commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Rather than controlling the queue sizes it would be better to limit the max epoch backlog and fail the query once that threshold is reached.  There already seems to be patch that attempted to address this https://github.com/apache/spark/pull/21392


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    Test PASSed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/99328/
    Test PASSed.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    BTW, coming back to your clean up PR but it takes some time to switch context :)


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by HeartSaVioR <gi...@git.apache.org>.
Github user HeartSaVioR commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    @gaborgsomogyi No problem :) When you get some other times please take a look at my other PRs as well.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    @arunmahadevan as I understand this is more like renaming the config than changing what the PR basically does, have I understood it well?
    
    Having backpressure instead of stopping the query is already agreed on another PRs, please check them. If the backlog reaches 10k items there is no way back.


---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by gaborgsomogyi <gi...@git.apache.org>.
Github user gaborgsomogyi commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    @arunmahadevan don't fully understand your comment:
    
    > Rather than controlling the queue sizes it would be better to limit the max epoch backlog and fail the query once that threshold is reached.
    
    I've written the following in the PR description:
    > If the related threshold reached then the query will stop with IllegalStateException.
    
    AFAIK `max epoch backlog` == `epochsWaitingToBeCommitted` which is a queue,
    but that's not the only unbounded part of `EpochCoordinator` (please see additional unit tests).
    As a result I've limited `partitionOffsets` and `partitionCommits` as well.



---

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


[GitHub] spark issue #23156: [SPARK-24063][SS] Add maximum epoch queue threshold for ...

Posted by SparkQA <gi...@git.apache.org>.
Github user SparkQA commented on the issue:

    https://github.com/apache/spark/pull/23156
  
    **[Test build #99822 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/99822/testReport)** for PR 23156 at commit [`b0c5056`](https://github.com/apache/spark/commit/b0c505676dcd207debb3e8483ef9bc20c25b03ac).


---

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