-
Notifications
You must be signed in to change notification settings - Fork 477
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
HDDS-8435. [Snapshot] Handle Directory renames for FSO Buckets. #4607
Conversation
HI i haven't reviewed the PR because i don't know much about the snapshot design. |
The
This shouldn't be an issue, Everything would go through the original flow. |
...r/src/test/java/org/apache/hadoop/ozone/om/request/snapshot/TestOMSnapshotCreateRequest.java
Outdated
Show resolved
Hide resolved
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.
lgtm overall
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OmMetadataManagerImpl.java
Outdated
Show resolved
Hide resolved
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/codec/OMDBDefinition.java
Outdated
Show resolved
Hide resolved
.../ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/SnapshotDeletingService.java
Show resolved
Hide resolved
...anager/src/main/java/org/apache/hadoop/ozone/om/response/key/OMKeyRenameResponseWithFSO.java
Show resolved
Hide resolved
.../ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/SnapshotDeletingService.java
Outdated
Show resolved
Hide resolved
Thanks @smengcl for the review. I have updated the PR, please take a look at it. |
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.
lgtm so far.
@GeorgeJahad mentioned he would want to scrutinize the test cases.
Though we have the renameDir
addition here. We might want to have more test cases around mixtures of key deletes, renames and snapshot deletes.
e.g.
- create keys and dirs
- create snapshot 1
- rename keys and dirs
- verify key and rename table states
- create snapshot 2
- rename some of the keys and dirs, delete some of the keys and dirs
- verify table states
- create snapshot 3
- again rename some of the keys and dirs, delete some of the keys and dirs
- create snapshot 4
- verify table states
- delete snapshot 3, trigger SDT, verify table states
- delete snapshot 2, trigger SDT, verify table states
- delete snapshot 1, trigger SDT, verify table states
- delete snapshot 4, trigger SDT, verify table states
Parameterize for LEGACY, FSO and OBS.
Maybe in another jira.
...r/src/test/java/org/apache/hadoop/ozone/om/request/snapshot/TestOMSnapshotCreateRequest.java
Outdated
Show resolved
Hide resolved
...r/src/test/java/org/apache/hadoop/ozone/om/request/snapshot/TestOMSnapshotCreateRequest.java
Outdated
Show resolved
Hide resolved
Thanks @ashishkumar50 for the patch. Thanks @devmadhuu and @ashishkumar50 for the reviews. |
What changes were proposed in this pull request?
When directories are renamed, this information is not tracked. It is required by the
SnapshotDeletingService
to check the previous snapshot'sdirectoryTable
and check if the renamed key is present.What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-8435
How was this patch tested?
Existing tests.