Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
-
None
Description
inodes is initialized with the number of patch components. After resolve, it contains both non-null and null elements (introduced by dot-snapshot dirs).
When getINodes is called, an array is returned excluding all non elements, which is the correct behavior. Meanwhile, the inodes array is trimmed too, which shouldn't be done by a getter.
Because of the above, the behavior of getINodesInPath depends on whether getINodes has been called, which is not correct.
The name of getLastINodeInPath is confusing – it actually returns the last non-null inode in the path. Also, shouldn't the return type be a single INode?
Attachments
Attachments
Issue Links
- relates to
-
HDFS-7498 Simplify the logic in INodesInPath
- Closed