Repository navigation
feat(spanner): add support for Queues in mutations - #16549
Conversation
There was a problem hiding this comment.
Code Review
This pull request adds support for Spanner Queues by introducing SendMutationBuilder, AckMutationBuilder, and helper functions, along with unit and integration tests. The review feedback points out a potential undefined behavior issue in mutations.cc where a StatusOr is dereferenced without checking .ok(), recommending the use of .value() instead. In queue_integration_test.cc, the feedback suggests replacing raw pointers with std::optional for safer lifetime management, and replacing several instances of auto in loops with explicit types to comply with the style guide regarding obscured StatusOr types.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #16549 +/- ##
==========================================
- Coverage 92.39% 92.33% -0.07%
==========================================
Files 2262 2263 +1
Lines 218382 218652 +270
==========================================
+ Hits 201775 201893 +118
- Misses 16607 16759 +152 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Adds C++ client library support for Cloud Spanner Queues (
Mutation::SendandMutation::Ack):spanner::SendMutationBuilderandspanner::MakeSendMutation(supporting optionaldeliver_time) to enqueue messages into a Spanner queue.spanner::AckMutationBuilderandspanner::MakeAckMutation(supporting optionalignore_not_found) to acknowledge messages in a Spanner queue.mutations_test.ccand end-to-end Enterprise edition integration tests inqueue_integration_test.cc.