Skip to content

Add --export.debug.log-match flag and gRPC request debug logging#320

Merged
bwplotka merged 2 commits into
release-2.53.5-gmpfrom
debug-grpc-label-matchers
Jun 26, 2026
Merged

Add --export.debug.log-match flag and gRPC request debug logging#320
bwplotka merged 2 commits into
release-2.53.5-gmpfrom
debug-grpc-label-matchers

Conversation

@bwplotka

Copy link
Copy Markdown
Collaborator

This adds the --export.debug.log-match flag to allow developers to specify Prometheus time series matchers. When set, any GCM time series matching these selectors will cause the exact filtered CreateTimeSeriesRequest protobuf to be logged at the DEBUG level prior to transmission over gRPC.

TAG=agy
CONV=6a59ce92-4dfe-45dc-bbec-57a860a8e424

This adds the `--export.debug.log-match` flag to allow developers to specify Prometheus time series matchers. When set, any GCM time series matching these selectors will cause the exact filtered CreateTimeSeriesRequest protobuf to be logged at the DEBUG level prior to transmission over gRPC.

TAG=agy
CONV=6a59ce92-4dfe-45dc-bbec-57a860a8e424

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

Copy link
Copy Markdown
Contributor

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 a feature to debug gRPC requests by logging exact CreateTimeSeries requests that match specified Prometheus time series matchers. It adds a new command-line flag --export.debug.log-match to configure these matchers. The feedback points out a performance improvement opportunity: passing the protobuf message directly to the logger instead of eagerly calling .String(), which avoids unnecessary serialization overhead when debug logging is disabled.

Comment thread google/export/export.go Outdated
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@bwplotka bwplotka requested review from bernot-dev and dashpole June 25, 2026 22:02
@bwplotka bwplotka merged commit 9962452 into release-2.53.5-gmp Jun 26, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants