Skip to content

HDDS-10397. Restrict legacy bucket directory deletion through sh command. #6244

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

Merged
merged 2 commits into from
Feb 22, 2024

Conversation

ashishkumar50
Copy link
Contributor

What changes were proposed in this pull request?

When enableFileSystemPath is true and bucket layout is legacy, during key delete operation in normalizekey(prexecute) it removes trailing slash, but in DB key is present with trailing slash. And because of this KEY_NOT_FOUND error comes.
But fixing legacy bucket directory deletion using sh can lead to other issues. In this PR we are restricting legacy bucket directory deletion using sh command.
More discussion in PR.

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-10397

How was this patch tested?

New Integration test.

@ashishkumar50
Copy link
Contributor Author

@sadanand48 Please help to review.

@adoroszlai
Copy link
Contributor

@ashishkumar50 was CI run cancelled intentionally?

@ashishkumar50
Copy link
Contributor Author

@ashishkumar50 was CI run cancelled intentionally?

Yes, I thought of after review let it run. It's already passed in my fork branch.
I have run it now.

@adoroszlai
Copy link
Contributor

If you want to get feedback on the code without running CI checks, or you know code is work-in-progress, you can create the PR as draft to skip most checks. Otherwise, if no big changes are expected, running CI checks before review is fine, no need to cancel.

Copy link
Contributor

@sadanand48 sadanand48 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ashishkumar50 for the patch, LGTM.

@sadanand48 sadanand48 merged commit c9d3b23 into apache:master Feb 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants