Skip to content

feat: cmperf should parse counter cook type#4281

Merged
rahulguptajss merged 1 commit into
mainfrom
cbg-cm
May 13, 2026
Merged

feat: cmperf should parse counter cook type#4281
rahulguptajss merged 1 commit into
mainfrom
cbg-cm

Conversation

@cgrinds
Copy link
Copy Markdown
Collaborator

@cgrinds cgrinds commented May 12, 2026

No description provided.

Copilot AI review requested due to automatic review settings May 12, 2026 15:38
@cla-bot cla-bot Bot added the cla-signed label May 12, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support in the cmperf cmmetrics parser for schema fields related to counter “cook” behavior, making parsed counter schemas more expressive and enabling consumers to understand derived counters.

Changes:

  • Introduced a dedicated CounterTypeEnum (cook type) for CounterSchema.Type instead of using a raw uint8.
  • Added parsing/storage of base_counter_index into CounterSchema.BaseIndex.
  • Updated tests to assert cook type semantics and base index parsing from the sample protobuf data.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.

File Description
cmd/collectors/cmperf/cmmetrics/metrics.go Adds cook-type enum, extends CounterSchema, and parses base_counter_index from schema payloads.
cmd/collectors/cmperf/cmmetrics/metrics_test.go Updates assertions to validate enum cook types and newly parsed base index.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread cmd/collectors/cmperf/cmmetrics/metrics.go
@rahulguptajss rahulguptajss merged commit 52d2840 into main May 13, 2026
17 checks passed
@rahulguptajss rahulguptajss deleted the cbg-cm branch May 13, 2026 07:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants