You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by GitBox <gi...@apache.org> on 2021/07/27 09:48:36 UTC

[GitHub] [incubator-kyuubi] yaooqinn opened a new pull request #868: Avoid calling a stopped SparkContext

yaooqinn opened a new pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868


   <!--
   Thanks for sending a pull request!
   
   Here are some tips for you:
     1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
     2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
     3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
   -->
   
   ### _Why are the changes needed?_
   <!--
   Please clarify why the changes are needed. For instance,
     1. If you add a feature, you can talk about the use case of it.
     2. If you fix a bug, you can clarify why it is a bug.
   -->
   
   We shall avoid calling cancelJobGroup if the sc is already stopped.
   
   We shall stop the engine to stop serving before we stop the sc during the shutdown hook
   
   ### _How was this patch tested?_
   - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible
   
   - [ ] Add screenshots for manual tests if appropriate
   
   - [ ] [Run test](https://kyuubi.readthedocs.io/en/latest/tools/testing.html#running-tests) locally before make a pull request
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn closed pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
yaooqinn closed pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] ulysses-you commented on a change in pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
ulysses-you commented on a change in pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#discussion_r677306801



##########
File path: kyuubi-common/src/main/scala/org/apache/kyuubi/Utils.scala
##########
@@ -168,12 +168,16 @@ private[kyuubi] object Utils extends Logging {
     System.getProperty(IS_TESTING.key) != null
   }
 
+  val DEFAULT_SHUTDOWN_PRIORITY = 100
+  val SERVER_SHUTDOWN_PRIORITY = 75
+  val SPARK_CONTEXT_SHUTDOWN_PRIORITY = 50

Review comment:
       We can add some comment that this priority depends on `org.apache.spark.util.ShutdownHookManager.SPARK_CONTEXT_SHUTDOWN_PRIORITY`




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] pan3793 commented on a change in pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
pan3793 commented on a change in pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#discussion_r677364886



##########
File path: kyuubi-common/src/main/scala/org/apache/kyuubi/Utils.scala
##########
@@ -168,12 +168,16 @@ private[kyuubi] object Utils extends Logging {
     System.getProperty(IS_TESTING.key) != null
   }
 
+  val DEFAULT_SHUTDOWN_PRIORITY = 100
+  val SERVER_SHUTDOWN_PRIORITY = 75
+  val SPARK_CONTEXT_SHUTDOWN_PRIORITY = 50

Review comment:
       a small or big one has a higher priority?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#issuecomment-887375460


   cc @zhang1002 @ulysses-you @pan3793 @turboFei 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#issuecomment-887376477


   cc @hammertank
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] codecov-commenter commented on pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#issuecomment-887391642


   # [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#868](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (a8a9c80) into [master](https://codecov.io/gh/apache/incubator-kyuubi/commit/2e67b09954f9dd4b6e15a8bf313276662a64e2a1?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (2e67b09) will **decrease** coverage by `0.02%`.
   > The diff coverage is `72.72%`.
   
   > :exclamation: Current head a8a9c80 differs from pull request most recent head 1481087. Consider uploading reports for the commit 1481087 to get more accurate results
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/graphs/tree.svg?width=650&height=150&src=pr&token=925D4tb9AH&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@             Coverage Diff              @@
   ##             master     #868      +/-   ##
   ============================================
   - Coverage     78.60%   78.58%   -0.03%     
     Complexity       10       10              
   ============================================
     Files           135      135              
     Lines          5123     5127       +4     
     Branches        642      643       +1     
   ============================================
   + Hits           4027     4029       +2     
   - Misses          745      746       +1     
   - Partials        351      352       +1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...kyuubi/engine/spark/operation/SparkOperation.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-ZXh0ZXJuYWxzL2t5dXViaS1zcGFyay1zcWwtZW5naW5lL3NyYy9tYWluL3NjYWxhL29yZy9hcGFjaGUva3l1dWJpL2VuZ2luZS9zcGFyay9vcGVyYXRpb24vU3BhcmtPcGVyYXRpb24uc2NhbGE=) | `68.65% <0.00%> (-1.50%)` | :arrow_down: |
   | [...ommon/src/main/scala/org/apache/kyuubi/Utils.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-a3l1dWJpLWNvbW1vbi9zcmMvbWFpbi9zY2FsYS9vcmcvYXBhY2hlL2t5dXViaS9VdGlscy5zY2FsYQ==) | `73.41% <75.00%> (+0.08%)` | :arrow_up: |
   | [...rg/apache/kyuubi/engine/spark/SparkSQLEngine.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-ZXh0ZXJuYWxzL2t5dXViaS1zcGFyay1zcWwtZW5naW5lL3NyYy9tYWluL3NjYWxhL29yZy9hcGFjaGUva3l1dWJpL2VuZ2luZS9zcGFyay9TcGFya1NRTEVuZ2luZS5zY2FsYQ==) | `68.51% <100.00%> (ø)` | |
   | [.../scala/org/apache/kyuubi/server/KyuubiServer.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-a3l1dWJpLW1haW4vc3JjL21haW4vc2NhbGEvb3JnL2FwYWNoZS9reXV1Ymkvc2VydmVyL0t5dXViaVNlcnZlci5zY2FsYQ==) | `50.00% <100.00%> (ø)` | |
   | [...rg/apache/kyuubi/zookeeper/EmbeddedZookeeper.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/868/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-a3l1dWJpLXpvb2tlZXBlci9zcmMvbWFpbi9zY2FsYS9vcmcvYXBhY2hlL2t5dXViaS96b29rZWVwZXIvRW1iZWRkZWRab29rZWVwZXIuc2NhbGE=) | `90.24% <100.00%> (ø)` | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [2e67b09...1481087](https://codecov.io/gh/apache/incubator-kyuubi/pull/868?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#issuecomment-887451848


   thanks, merged to master


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on a change in pull request #868: Avoid calling a stopped SparkContext

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on a change in pull request #868:
URL: https://github.com/apache/incubator-kyuubi/pull/868#discussion_r677366403



##########
File path: kyuubi-common/src/main/scala/org/apache/kyuubi/Utils.scala
##########
@@ -168,12 +168,16 @@ private[kyuubi] object Utils extends Logging {
     System.getProperty(IS_TESTING.key) != null
   }
 
+  val DEFAULT_SHUTDOWN_PRIORITY = 100
+  val SERVER_SHUTDOWN_PRIORITY = 75
+  val SPARK_CONTEXT_SHUTDOWN_PRIORITY = 50

Review comment:
       big




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org