-
Notifications
You must be signed in to change notification settings - Fork 9.2k
HDFS-16428. Source path with storagePolicy cause wrong typeConsumed while rename #3898
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -339,6 +339,16 @@ public boolean isFile() { | |
| return false; | ||
| } | ||
|
|
||
| /** | ||
| * Check if this inode itself has a storage policy set. | ||
| */ | ||
| public boolean isSetStoragePolicy() { | ||
|
||
| if (isSymlink()) { | ||
| return false; | ||
| } | ||
| return getLocalStoragePolicyID() != HdfsConstants.BLOCK_STORAGE_POLICY_ID_UNSPECIFIED; | ||
| } | ||
|
|
||
| /** Cast this inode to an {@link INodeFile}. */ | ||
| public INodeFile asFile() { | ||
| throw new IllegalStateException("Current inode is not a file: " | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also add a test case to verify the quota check part.