Skip to content

refactor(bigtable): rename metric Labels types to indicate Table schema - #16337

Open
scotthart wants to merge 2 commits into
googleapis:mainfrom
scotthart:bigtable_metrics_label_rename
Open

refactor(bigtable): rename metric Labels types to indicate Table schema#16337
scotthart wants to merge 2 commits into
googleapis:mainfrom
scotthart:bigtable_metrics_label_rename

Conversation

@scotthart

Copy link
Copy Markdown
Member

With the upcoming introduction of Client schema metric labels, this helps differentiate.

@scotthart
scotthart requested a review from a team as a code owner August 9, 2026 20:01
@product-auto-label product-auto-label Bot added the api: bigtable Issues related to the Bigtable API. label Aug 9, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

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 renames ResourceLabels to TableResourceLabels and DataLabels to TableDataLabels across the Bigtable internal metrics implementation, updating the clone method signatures to accept these structures by const reference instead of by value. Two issues were identified in the review: first, changing Metric::clone from a pure virtual function to a virtual function returning nullptr reduces compile-time safety and could lead to runtime null pointer dereferences; second, ApplicationBlockingLatency::clone incorrectly attempts to std::move the const& parameters, which is a no-op and misleading.

Comment thread google/cloud/bigtable/internal/metrics.h Outdated
Comment thread google/cloud/bigtable/internal/metrics.cc
@codecov

codecov Bot commented Aug 9, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 97.10611% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.24%. Comparing base (c6a56cb) to head (570a1a6).

Files with missing lines Patch % Lines
...oud/bigtable/internal/operation_context_factory.cc 84.74% 9 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main   #16337   +/-   ##
=======================================
  Coverage   92.24%   92.24%           
=======================================
  Files        2227     2227           
  Lines      209208   209241   +33     
=======================================
+ Hits       192976   193007   +31     
- Misses      16232    16234    +2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigtable Issues related to the Bigtable API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant