This is an automated email from the ASF dual-hosted git repository.

zhouky pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-celeborn.git


The following commit(s) were added to refs/heads/main by this push:
     new be05ae37f [CELEBORN-815] Remove unused ShuffleClient.readPartition
be05ae37f is described below

commit be05ae37fe2d0297ca5f0ad2c748710be266978e
Author: Angerszhuuuu <[email protected]>
AuthorDate: Thu Jul 20 20:49:29 2023 +0800

    [CELEBORN-815] Remove unused ShuffleClient.readPartition
    
    ### What changes were proposed in this pull request?
    As title.
    
    ### Why are the changes needed?
    
    ### Does this PR introduce _any_ user-facing change?
    No.
    
    ### How was this patch tested?
    Passes GA.
    
    Closes #1739 from AngersZhuuuu/CELEBORN-815.
    
    Authored-by: Angerszhuuuu <[email protected]>
    Signed-off-by: zky.zhoukeyong <[email protected]>
---
 client/src/main/java/org/apache/celeborn/client/ShuffleClient.java  | 3 ---
 .../src/main/java/org/apache/celeborn/client/ShuffleClientImpl.java | 6 ------
 .../test/java/org/apache/celeborn/client/DummyShuffleClient.java    | 5 -----
 .../scala/org/apache/celeborn/client/WithShuffleClientSuite.scala   | 4 ++--
 .../apache/celeborn/service/deploy/cluster/ReadWriteTestBase.scala  | 2 +-
 5 files changed, 3 insertions(+), 17 deletions(-)

diff --git a/client/src/main/java/org/apache/celeborn/client/ShuffleClient.java 
b/client/src/main/java/org/apache/celeborn/client/ShuffleClient.java
index fad9a6957..c06c6a842 100644
--- a/client/src/main/java/org/apache/celeborn/client/ShuffleClient.java
+++ b/client/src/main/java/org/apache/celeborn/client/ShuffleClient.java
@@ -146,9 +146,6 @@ public abstract class ShuffleClient {
       int shuffleId, int partitionId, int attemptNumber, int startMapIndex, 
int endMapIndex)
       throws IOException;
 
-  public abstract CelebornInputStream readPartition(
-      int shuffleId, int partitionId, int attemptNumber) throws IOException;
-
   public abstract boolean cleanupShuffle(int shuffleId);
 
   public abstract void shutdown();
diff --git 
a/client/src/main/java/org/apache/celeborn/client/ShuffleClientImpl.java 
b/client/src/main/java/org/apache/celeborn/client/ShuffleClientImpl.java
index 7544f11b6..dcec21a94 100644
--- a/client/src/main/java/org/apache/celeborn/client/ShuffleClientImpl.java
+++ b/client/src/main/java/org/apache/celeborn/client/ShuffleClientImpl.java
@@ -1508,12 +1508,6 @@ public class ShuffleClientImpl extends ShuffleClient {
     return true;
   }
 
-  @Override
-  public CelebornInputStream readPartition(int shuffleId, int partitionId, int 
attemptNumber)
-      throws IOException {
-    return readPartition(shuffleId, partitionId, attemptNumber, 0, 
Integer.MAX_VALUE);
-  }
-
   protected ReduceFileGroups loadFileGroupInternal(int shuffleId) {
     {
       long getReducerFileGroupStartTime = System.nanoTime();
diff --git 
a/client/src/test/java/org/apache/celeborn/client/DummyShuffleClient.java 
b/client/src/test/java/org/apache/celeborn/client/DummyShuffleClient.java
index b593442e5..252452687 100644
--- a/client/src/test/java/org/apache/celeborn/client/DummyShuffleClient.java
+++ b/client/src/test/java/org/apache/celeborn/client/DummyShuffleClient.java
@@ -116,11 +116,6 @@ public class DummyShuffleClient extends ShuffleClient {
     return null;
   }
 
-  @Override
-  public CelebornInputStream readPartition(int shuffleId, int partitionId, int 
attemptNumber) {
-    return null;
-  }
-
   @Override
   public boolean cleanupShuffle(int shuffleId) {
     return false;
diff --git 
a/client/src/test/scala/org/apache/celeborn/client/WithShuffleClientSuite.scala 
b/client/src/test/scala/org/apache/celeborn/client/WithShuffleClientSuite.scala
index aefef641d..33bb24d62 100644
--- 
a/client/src/test/scala/org/apache/celeborn/client/WithShuffleClientSuite.scala
+++ 
b/client/src/test/scala/org/apache/celeborn/client/WithShuffleClientSuite.scala
@@ -141,11 +141,11 @@ trait WithShuffleClientSuite extends CelebornFunSuite {
     Assert.assertEquals(shuffleClient.getReduceFileGroupsMap.size(), 0)
 
     // reduce normal empty CelebornInputStream
-    var stream = shuffleClient.readPartition(shuffleId, 1, 1)
+    var stream = shuffleClient.readPartition(shuffleId, 1, 1, 0, 
Integer.MAX_VALUE)
     Assert.assertEquals(stream.read(), -1)
 
     // reduce normal null partition for CelebornInputStream
-    stream = shuffleClient.readPartition(shuffleId, 3, 1)
+    stream = shuffleClient.readPartition(shuffleId, 3, 1, 0, Integer.MAX_VALUE)
     Assert.assertEquals(stream.read(), -1)
   }
 
diff --git 
a/worker/src/test/scala/org/apache/celeborn/service/deploy/cluster/ReadWriteTestBase.scala
 
b/worker/src/test/scala/org/apache/celeborn/service/deploy/cluster/ReadWriteTestBase.scala
index 3796975ae..433f89ea1 100644
--- 
a/worker/src/test/scala/org/apache/celeborn/service/deploy/cluster/ReadWriteTestBase.scala
+++ 
b/worker/src/test/scala/org/apache/celeborn/service/deploy/cluster/ReadWriteTestBase.scala
@@ -93,7 +93,7 @@ trait ReadWriteTestBase extends AnyFunSuite
 
     shuffleClient.mapperEnd(1, 0, 0, 1)
 
-    val inputStream = shuffleClient.readPartition(1, 0, 0)
+    val inputStream = shuffleClient.readPartition(1, 0, 0, 0, 
Integer.MAX_VALUE)
     val outputStream = new ByteArrayOutputStream()
 
     var b = inputStream.read()

Reply via email to