Skip to content

Commit

Permalink
[fs] Retry for HDFS blocklist has changed in FileIO.readOverwrittenFi…
Browse files Browse the repository at this point in the history
…leUtf8
  • Loading branch information
JingsongLi committed Oct 30, 2023
1 parent e3cdc1b commit cddaa15
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions paimon-common/src/main/java/org/apache/paimon/fs/FileIO.java
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ default Optional<String> readOverwrittenFileUtf8(Path path) throws IOException {
if (e.getClass()
.getName()
.endsWith("org.apache.hadoop.fs.s3a.RemoteFileChangedException")) {
// retry for S3 RemoteFileChangedException
exception = e;
} else if (e.getMessage() != null
&& e.getMessage().contains("Blocklist for")
&& e.getMessage().contains("has changed")) {
// retry for HDFS blocklist has changed exception
exception = e;
} else {
throw e;
Expand Down

0 comments on commit cddaa15

Please sign in to comment.