HDFS-14910. Rename Snapshot with Pre Descendants Fail With IllegalArgumentException. Contributed by Wei-Chiu Chuang. (#1672)
Reviewed-by: Ayush Saxena <ayushsaxena@apache.org> (cherry picked from commit a1b4eebcc92976a9fb78ad5d3ab70c52cc0a5fa7) (cherry picked from commit 8cf4bc4bda5b0d33e42168ed2688396524598ead)
This commit is contained in:
parent
a3493fe328
commit
c6e6d1c6cc
@ -841,7 +841,8 @@ public void cleanSubtree(ReclaimContext reclaimContext, final int snapshotId,
|
||||
// If the inode has empty diff list and sf is not a
|
||||
// DirectorySnapshottableFeature, remove the feature to save heap.
|
||||
if (sf.getDiffs().isEmpty() &&
|
||||
!(sf instanceof DirectorySnapshottableFeature)) {
|
||||
!(sf instanceof DirectorySnapshottableFeature) &&
|
||||
getDirectoryWithSnapshotFeature() != null) {
|
||||
this.removeFeature(sf);
|
||||
}
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user