-
Notifications
You must be signed in to change notification settings - Fork 473
feat(Type Cache Deprecation): Delete implicit dirs #4249
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
base: master
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4249 +/- ##
=======================================
Coverage 83.06% 83.06%
=======================================
Files 156 156
Lines 19173 19172 -1
=======================================
Hits 15926 15926
+ Misses 2654 2653 -1
Partials 593 593
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
e8ca373 to
9f45831
Compare
9f45831 to
d08eb4e
Compare
a7f640b to
8600dc2
Compare
8600dc2 to
7de3e0f
Compare
|
/gemini review |
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.
Code Review
This pull request introduces an OnlyDeleteFromCache flag to DeleteObjectRequest to optimize the deletion of implicit GCS directories. When this flag is set, the system avoids a redundant network call to GCS and only invalidates the local metadata cache. The changes are logical and well-supported by new unit tests. My review includes a couple of suggestions to remove redundant code and to refactor the new tests for better maintainability.
d7b9ad6 to
afa01ef
Compare
|
Hi @vadlakondaswetha, your feedback is needed to move this pull request forward. This automated reminder was triggered because there has been no activity for over 24 hours. Please provide your input when you have a moment. Thank you! |
Description
Implicit directories in GCS exist only as prefixes of child objects. Once the last child is deleted, the directory automatically "disappears." Sending a DeleteObject request for an implicit directory is unnecessary and returns a 404 Not Found error, yet the entry may still exist in the local metadata cache.
Introduce an OnlyDeleteFromCache flag to DeleteObjectRequest. This allows the system to invalidate the local cache without making a redundant remote call to GCS when dealing with implicit directories.
Implementation:
Link to the issue in case of a bug fix.
b/473955961
Testing details
Any backward incompatible change? If so, please explain.