This is an automated email from the ASF dual-hosted git repository.
danny0405 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hudi.git
The following commit(s) were added to refs/heads/master by this push:
new 46de25d [HUDI-2994] Add judgement to existed partitionPath in the
catch code block for HU… (#4294)
46de25d is described below
commit 46de25d5fd7fc5aedc574fc6bb76e14efb46bb37
Author: WangMinChao <[email protected]>
AuthorDate: Mon Dec 13 20:41:03 2021 +0800
[HUDI-2994] Add judgement to existed partitionPath in the catch code block
for HU… (#4294)
* [HUDI-2994] Add judgement to existed partition path in the catch code
block for HUDI-2743
Co-authored-by: wangminchao <[email protected]>
---
.../apache/hudi/common/table/view/AbstractTableFileSystemView.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git
a/hudi-common/src/main/java/org/apache/hudi/common/table/view/AbstractTableFileSystemView.java
b/hudi-common/src/main/java/org/apache/hudi/common/table/view/AbstractTableFileSystemView.java
index d946cff..a626c1b 100644
---
a/hudi-common/src/main/java/org/apache/hudi/common/table/view/AbstractTableFileSystemView.java
+++
b/hudi-common/src/main/java/org/apache/hudi/common/table/view/AbstractTableFileSystemView.java
@@ -336,9 +336,11 @@ public abstract class AbstractTableFileSystemView
implements SyncableFileSystemV
if (!metaClient.getFs().exists(partitionPath)) {
metaClient.getFs().mkdirs(partitionPath);
return new FileStatus[0];
+ } else {
+ // in case the partition path was created by another caller
+ return metaClient.getFs().listStatus(partitionPath);
}
}
- throw new HoodieIOException(String.format("Failed to list partition path:
%s", partitionPath));
}
/**