This is an automated email from the ASF dual-hosted git repository.
zuston pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/uniffle.git
The following commit(s) were added to refs/heads/master by this push:
new bbdf71e67 [#2485] fix(Client): NPE in
`CoordinatorGrpcRetryableClient.getShuffleAssignments` (#2486)
bbdf71e67 is described below
commit bbdf71e6752971c3137821031799dd754a74baf8
Author: Zhen Wang <[email protected]>
AuthorDate: Fri May 16 17:43:52 2025 +0800
[#2485] fix(Client): NPE in
`CoordinatorGrpcRetryableClient.getShuffleAssignments` (#2486)
### What changes were proposed in this pull request?
Fix NPE in CoordinatorGrpcRetryableClient.getShuffleAssignments
### Why are the changes needed?
closes #2485
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
---
.../client/impl/grpc/CoordinatorGrpcRetryableClient.java | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git
a/internal-client/src/main/java/org/apache/uniffle/client/impl/grpc/CoordinatorGrpcRetryableClient.java
b/internal-client/src/main/java/org/apache/uniffle/client/impl/grpc/CoordinatorGrpcRetryableClient.java
index ef8a0f7ff..011de0999 100644
---
a/internal-client/src/main/java/org/apache/uniffle/client/impl/grpc/CoordinatorGrpcRetryableClient.java
+++
b/internal-client/src/main/java/org/apache/uniffle/client/impl/grpc/CoordinatorGrpcRetryableClient.java
@@ -166,7 +166,11 @@ public class CoordinatorGrpcRetryableClient implements
CoordinatorClient {
try {
response = coordinatorClient.getShuffleAssignments(request);
} catch (Exception e) {
- LOG.error(e.getMessage());
+ LOG.warn(
+ "Failed to get shuffle server assignment from {}",
+ coordinatorClient.getDesc(),
+ e);
+ continue;
}
if (response.getStatusCode() == StatusCode.SUCCESS) {
@@ -176,6 +180,10 @@ public class CoordinatorGrpcRetryableClient implements
CoordinatorClient {
return response;
}
}
+ if (response == null) {
+ throw new RssException(
+ "Failed to get shuffle server assignment from all
coordinators");
+ }
if (response.getStatusCode() != StatusCode.SUCCESS) {
throw new RssException(response.getMessage());
}