diff --git a/client/src/main/java/org/apache/celeborn/client/read/CelebornInputStream.java b/client/src/main/java/org/apache/celeborn/client/read/CelebornInputStream.java index dfbb7c502b8..e63eaae621d 100644 --- a/client/src/main/java/org/apache/celeborn/client/read/CelebornInputStream.java +++ b/client/src/main/java/org/apache/celeborn/client/read/CelebornInputStream.java @@ -664,7 +664,7 @@ private boolean fillBuffer() throws IOException { appShuffleId, shuffleId, partitionId, - currentReader.getLocation(), + Optional.ofNullable(currentReader).map(PartitionReader::getLocation).orElse(null), e); IOException ioe; if (e instanceof IOException) { @@ -692,7 +692,7 @@ private boolean fillBuffer() throws IOException { appShuffleId, shuffleId, partitionId, - currentReader.getLocation(), + Optional.ofNullable(currentReader).map(PartitionReader::getLocation).orElse(null), e); throw e; }