feat(storage): Add delete object source field in ComposeObject API#16094
feat(storage): Add delete object source field in ComposeObject API#16094v-pratap wants to merge 3 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces the DeleteSourceObjects option for ComposeObject requests, implementing support in both gRPC and REST paths. It also includes integration tests to verify the behavior when the option is enabled or disabled. Feedback was provided to simplify the option retrieval logic using value_or(false) for better readability and to add a docstring to the new public-facing DeleteSourceObjects parameter.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #16094 +/- ##
==========================================
- Coverage 92.70% 92.70% -0.01%
==========================================
Files 2353 2353
Lines 218354 218414 +60
==========================================
+ Hits 202419 202472 +53
- Misses 15935 15942 +7 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
b5077ac to
53036f9
Compare
| request.GetOption<storage::IfMetagenerationMatch>().value()); | ||
| } | ||
| result.set_kms_key(request.GetOption<storage::KmsKeyName>().value_or("")); | ||
| if (request.GetOption<storage::DeleteSourceObjects>().value_or(false)) { |
There was a problem hiding this comment.
nit: we're using GetOption instead of HasOption, which seems to be intentional so that the default behavior (no deletion) is preserved if the option is not explicitly provided. Should we add a comment to clarify?
No description provided.