impl(generator): add OperationContext to Bigtable stub and decorators - #16331
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces an experimental feature to propagate OperationContext through the Bigtable client stub and decorator layers. It adds a new configuration option experimental_bigtable_operation_context to the code generator, updates the C++ code generator templates (including auth, logging, metadata, round-robin, stub, and tracing decorators) to support passing this context, and integrates the context parameter across the handwritten Bigtable client implementation files and their corresponding unit tests. I have no feedback to provide as there are no review comments.
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #16331 +/- ##
==========================================
- Coverage 92.24% 92.23% -0.01%
==========================================
Files 2227 2227
Lines 209169 209208 +39
==========================================
+ Hits 192943 192969 +26
- Misses 16226 16239 +13 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
As part of ongoing Bigtable metric collection, some additional metrics require data to be collected in a stub decorator. To enable this, we need to plumb the bigtable_internal::OperationContext object into the decorators via the stub RPC methods. This requires a minor but widespread change to how we emit stubs from the generator. For now, we are going to limit this generator change to the bigtable library where it is needed. In the future, as we expand metric collection, we will factor OperationContext out into a common library and make the generator changes service generic instead of specific to bigtable.
The code changes have been grouped into separate commits for clarity.