You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/02/26 10:44:19 UTC

[GitHub] [spark] yikf opened a new pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

yikf opened a new pull request #31664:
URL: https://github.com/apache/spark/pull/31664


   ### What changes were proposed in this pull request?
   Fixed an issue where data could not be cleaned up when unregisterShuffle.
   
   ### Why are the changes needed?
   While we use the old shuffle fetch protocol, we use partitionId as mapId in the ShuffleBlockId construction,but we use `context.taskAttemptId()` as mapId that it is cached in `taskIdMapsForShuffle` when we `getWriter[K, V]`.
   
   where data could not be cleaned up when unregisterShuffle ,because we remove a shuffle's metadata from the `taskIdMapsForShuffle`'s mapIds, the mapId is `context.taskAttemptId()` instead of partitionId.
   
   ### Does this PR introduce _any_ user-facing change?
   yes
   
   ### How was this patch tested?
   exist test.
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787116605


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135545/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] srowen commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
srowen commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792391288


   Jenkins retest this please


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790743744


   **[Test build #135762 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135762/testReport)** for PR 31664 at commit [`65be2c7`](https://github.com/apache/spark/commit/65be2c7c94024535ced891115985c524b5a96aaf).


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790849086


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135762/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585595132



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,40 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=true/false") {

Review comment:
       ok, Thanks direction for codeStyle very much, xiexie~




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-786568144


   Can one of the admins verify this patch?


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584432639



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       We can run a simple job before our target job to make the `taskAttemptId` starts from 1. e.g., 
   
   `sc.parallelize(1 to 10, 1).count()`.
   
   I tried this way and the issue can be reproduced.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790839782


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


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588888923



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -130,5 +130,4 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
       mapSideCombine = true
     )))
   }
-

Review comment:
       line-133 is empty line, we add test in  `SortShuffleManagerSuite ` before, after https://github.com/apache/spark/pull/31664#discussion_r585669990, move the test to `ShuffleSuite`, So i change the empty line together.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] srowen commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
srowen commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790723527


   Jenkins retest this please


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787107626


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/40126/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don't understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask`
   `
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `
   
   In readSide, we need to use protoco to distinguish messages, But in writeSide, register to ExternalShuffleService by `RegisterExecutor `, It paas the localDir to shuffleService, So shuffleService know the middle file by shuffle, But seems unrelated to `mapId`.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584384912



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
         It seems that context.taskAttemptId and partitionId are the same, both increasing from 0. I don't understand why the  protocol should be differentiated on the write side.
     I met this problem before, but now the scene has not been recovered




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588888508



##########
File path: core/src/test/scala/org/apache/spark/ShuffleSuite.scala
##########
@@ -419,6 +424,31 @@ abstract class ShuffleSuite extends SparkFunSuite with Matchers with LocalSparkC
 
     manager.unregisterShuffle(0)
   }
+
+  test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=true") {

Review comment:
       `ShuffleSuite`  is abstract class, ShuffleOldFetchProtocolSuite would cover the `spark.shuffle.useOldFetchProtocol=true` case.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588889186



##########
File path: core/src/test/scala/org/apache/spark/ShuffleSuite.scala
##########
@@ -419,6 +424,31 @@ abstract class ShuffleSuite extends SparkFunSuite with Matchers with LocalSparkC
 
     manager.unregisterShuffle(0)
   }
+
+  test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=true") {

Review comment:
       I mean, the test name is not correct for other extended shuffle suites. For other suites, `spark.shuffle.useOldFetchProtocol` should be `false`, right?




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792447483


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135848/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] srowen closed pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
srowen closed pull request #31664:
URL: https://github.com/apache/spark/pull/31664


   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790765302


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/40345/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] srowen commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
srowen commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787089974


   Jenkins retest this please


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don't understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask`
   
   `
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the
       // ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588889790



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -130,5 +130,4 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
       mapSideCombine = true
     )))
   }
-

Review comment:
       ok,i will revert it.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787094529


   **[Test build #135545 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135545/testReport)** for PR 31664 at commit [`69467ee`](https://github.com/apache/spark/commit/69467ee6c70d1074b3a79d093cde365e5ed648a3).


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792428715


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/40430/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584449255



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       I roughly remember that's because we want to ensure the unique file name at write size. cc @xuanyuanking 




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r586279580



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +138,33 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  Seq("true", "false").foreach { value =>
+    test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=$value") {

Review comment:
       If we move it to `ShuffleSuite`, we should consider  the case of `spark.shuffle.useOldFetchProtoclol = false` ,  and different configurations are also more intuitive to test together.
   
   If we need to move it to ShuffleSuite, I'm alse ok.
   




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792428715


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/40430/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790757777


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/40345/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790763887


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/40345/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792447483


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135848/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don't understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask`
   `
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584316328



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       BTW, this test requires `spark.shuffle.useOldFetchProtocol=true`?
   
   And it's better to test both `true` and `false`. 




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787116605


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135545/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792423016


   Kubernetes integration test status success
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/40430/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-789594255


   gentle ping@srowen , Coulde you help me merge the pr to master? thanks


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-791974566


   LGTM


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] srowen commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
srowen commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792744799


   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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584796214



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       updated




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] xuanyuanking commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
xuanyuanking commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585669990



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +138,33 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  Seq("true", "false").foreach { value =>
+    test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=$value") {

Review comment:
       Is this possible to add in `ShuffleSuite`. If so, we don't need to consider the `spark.shuffle.useOldFetchProtocol` since `ShuffleOldFetchProtocolSuite` would cover the old protocol case.
   If it's hard to move it to ShuffleSuite. I'm also OK with the current code.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792397759


   **[Test build #135848 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135848/testReport)** for PR 31664 at commit [`cd907bb`](https://github.com/apache/spark/commit/cd907bbd1d5f1d4df377133eafd9da60446e5d96).


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-786609458


   gentle ping @srowen @otterc  @HyukjinKwon  , thanks for taking a look.


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585595132



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,40 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=true/false") {

Review comment:
       ok, Thanks for guiding codeStyle very much, xiexie~




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-786686998


   cc @xuanyuanking 


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585297062



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,40 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=true/false") {

Review comment:
       We usually test different config values like this:
   
   ```scala
   Seq(true, false).foreach { value =>
      test(s"SPARK-34541: shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=$value") {
       ...
       conf.set(spark.shuffle.useOldFetchProtocol, value)
       ...
   }
   ```
   
   Could you follow this way?




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584384912



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       It seems that A and B are the same, both increasing from 0. I don't understand why the protocol should be differentiated on the write side




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-789594255


   gentle ping@srowen , Coulde you help me merge the pr to master? thanks


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-786568144






----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787094529


   **[Test build #135545 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135545/testReport)** for PR 31664 at commit [`69467ee`](https://github.com/apache/spark/commit/69467ee6c70d1074b3a79d093cde365e5ed648a3).


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585595132



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,40 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=true/false") {

Review comment:
       ok, Thanks direction for codeStyle very much,xiexie~




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588889545



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -130,5 +130,4 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
       mapSideCombine = true
     )))
   }
-

Review comment:
       I know the reason, but it's still not a necessary change, especially when there's no other changes in the file.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790849086


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/135762/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585297062



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,40 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=true/false") {

Review comment:
       We usually test different config values like this:
   
   ```scala
   Seq(true, false).foreach { value =>
      test("Shuffle data can be cleaned up whether spark.shuffle.useOldFetchProtocol=value") {
        ....
       conf.set(spark.shuffle.useOldFetchProtocol, value)
       ...
   }
   ```
   
   Could you follow this way?




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584384912



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       It seems that context.taskAttemptId and partitionId are the same, both increasing from 0. I don't understand why the protocol should be differentiated on the write side




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don't understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask
   
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the
       // ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-787114771


   **[Test build #135545 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135545/testReport)** for PR 31664 at commit [`69467ee`](https://github.com/apache/spark/commit/69467ee6c70d1074b3a79d093cde365e5ed648a3).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds the following public classes _(experimental)_:
     * `class SortShuffleManagerSuite extends SparkFunSuite with Matchers with LocalSparkContext `


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792414969


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/40430/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584316221



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       nit: `SPARK-34541: Data ...`




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r586279580



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +138,33 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  Seq("true", "false").foreach { value =>
+    test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=$value") {

Review comment:
       If we move it to `ShuffleSuite`, we should consider  the case of `spark.shuffle.useOldFetchProtoclol = false` ,  and different configurations are also more intuitive to test together.
   
   If we need to move it to ShuffleSuite, I'm alse ok.
   




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584384912



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       It seems that context.taskAttemptId and partitionId are the same, both increasing from 0. I don't understand why the  protocol should be differentiated on the write side.
   
   I met this problem before, but now the scene has not been recovered




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792397759


   **[Test build #135848 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135848/testReport)** for PR 31664 at commit [`cd907bb`](https://github.com/apache/spark/commit/cd907bbd1d5f1d4df377133eafd9da60446e5d96).


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790765302


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/40345/
   


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r588883452



##########
File path: core/src/test/scala/org/apache/spark/ShuffleSuite.scala
##########
@@ -419,6 +424,31 @@ abstract class ShuffleSuite extends SparkFunSuite with Matchers with LocalSparkC
 
     manager.unregisterShuffle(0)
   }
+
+  test(s"SPARK-34541: shuffle can be removed when spark.shuffle.useOldFetchProtocol=true") {

Review comment:
       nit: `SPARK-34541: shuffle files should be removed normally`
   
   (`spark.shuffle.useOldFetchProtocol=true` is not valid for `ShuffleSuite`.)

##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -130,5 +130,4 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
       mapSideCombine = true
     )))
   }
-

Review comment:
       nit: revert the unrelated change.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r583656091



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +141,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("SPARK-34541 Data could not be cleaned up when unregisterShuffle") {

Review comment:
       Updated.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] Ngone51 commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
Ngone51 commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r583633920



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +141,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("SPARK-34541 Data could not be cleaned up when unregisterShuffle") {
+    val conf = new SparkConf(loadDefaults = false)
+    val tempDir: File = Utils.createTempDir()

Review comment:
       use `withTempDir`?

##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +141,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("SPARK-34541 Data could not be cleaned up when unregisterShuffle") {
+    val conf = new SparkConf(loadDefaults = false)
+    val tempDir: File = Utils.createTempDir()
+    conf.set("spark.local.dir", tempDir.getAbsolutePath)
+    val sc: SparkContext = new SparkContext("local", "SPARK-34541", conf)
+    val rdd = sc.parallelize(1 to 10, 1).map(x => (x, x))
+    // Create a shuffleRdd
+    val shuffledRdd = new ShuffledRDD[Int, Int, Int](rdd, new HashPartitioner(4))
+      .setSerializer(new JavaSerializer(conf))
+    def getAllFiles: Set[File] =
+      FileUtils.listFiles(tempDir, TrueFileFilter.INSTANCE, TrueFileFilter.INSTANCE).asScala.toSet
+    val filesBeforeShuffle = getAllFiles
+    // Force the shuffle to be performed
+    shuffledRdd.count()
+    // Ensure that the shuffle actually created files that will need to be cleaned up
+    val filesCreatedByShuffle = getAllFiles -- filesBeforeShuffle
+    filesCreatedByShuffle.map(_.getName) should be
+    Set("shuffle_0_0_0.data", "shuffle_0_0_0.index")
+    // Check that the cleanup actually removes the files
+    sc.env.blockManager.master.removeShuffle(0, blocking = true)
+    for (file <- filesCreatedByShuffle) {
+      assert (!file.exists(), s"Shuffle file $file was not cleaned up")
+    }
+  }
+

Review comment:
       nit: unnecessary line

##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -17,13 +17,23 @@
 
 package org.apache.spark.shuffle.sort
 
+import java.io.File
+
+import scala.collection.JavaConverters._
+
+import org.apache.commons.io.FileUtils
+import org.apache.commons.io.filefilter.TrueFileFilter
 import org.mockito.Mockito.{mock, when}
 import org.mockito.invocation.InvocationOnMock
 import org.mockito.stubbing.Answer
 import org.scalatest.matchers.must.Matchers
+import org.scalatest.matchers.should.Matchers._
 
 import org.apache.spark._
+import org.apache.spark.rdd.ShuffledRDD
 import org.apache.spark.serializer.{JavaSerializer, KryoSerializer, Serializer}
+import org.apache.spark.util.Utils
+

Review comment:
       nit: redundant empty line.

##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +141,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("SPARK-34541 Data could not be cleaned up when unregisterShuffle") {

Review comment:
       nit: `SPARK-34541:`




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-792434848


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


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don`t understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask
   
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the
       // ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-791383952


   > Jenkins retest this please
   
   gentle ping @srowen .


----------------------------------------------------------------
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.

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



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


[GitHub] [spark] yikf commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
yikf commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r584438668



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       OK, thank you. I'll add test later, And I don't understand why the protocol should be differentiated on the WriteSide, As follow:
   `ShuffleMapTask#runTask`
   `
      // While we use the old shuffle fetch protocol, we use partitionId as mapId in the ShuffleBlockId construction.
       val mapId = if (SparkEnv.get.conf.get(config.SHUFFLE_USE_OLD_FETCH_PROTOCOL)) {
         partitionId
       } else context.taskAttemptId()
   `
   
   In readSide, we need to use protoco to distinguish messages, But in writeSide, register shuffle to ExternalShuffleService by `RegisterExecutor `, It paas the localDir to shuffleService, So shuffleService know the middle file by shuffle, But seems unrelated to `mapId`.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] xuanyuanking commented on a change in pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
xuanyuanking commented on a change in pull request #31664:
URL: https://github.com/apache/spark/pull/31664#discussion_r585662409



##########
File path: core/src/test/scala/org/apache/spark/shuffle/sort/SortShuffleManagerSuite.scala
##########
@@ -131,4 +139,29 @@ class SortShuffleManagerSuite extends SparkFunSuite with Matchers {
     )))
   }
 
+  test("Data could not be cleaned up when unregisterShuffle") {

Review comment:
       `at write size` -> `at write side`? :)
   Yes, you can check the description in #25620. TL;DR: we need a unique file name to resolve the indeterminate shuffle issue.




----------------------------------------------------------------
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.

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



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


[GitHub] [spark] SparkQA removed a comment on pull request #31664: [SPARK-34541][CORE] Fixed an issue where data could not be cleaned up when unregisterShuffle.

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #31664:
URL: https://github.com/apache/spark/pull/31664#issuecomment-790743744


   **[Test build #135762 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/135762/testReport)** for PR 31664 at commit [`65be2c7`](https://github.com/apache/spark/commit/65be2c7c94024535ced891115985c524b5a96aaf).


----------------------------------------------------------------
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.

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



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