Skip to content

Add linter rules to ensure we don't accidentally emit metrics directly instead of through the compat package#633

Merged
mkeeler merged 1 commit intomainfrom
metrics-compat-lint
Jan 9, 2025
Merged

Add linter rules to ensure we don't accidentally emit metrics directly instead of through the compat package#633
mkeeler merged 1 commit intomainfrom
metrics-compat-lint

Conversation

@mkeeler
Copy link
Member

@mkeeler mkeeler commented Jan 9, 2025

My previous PR switched the repo over to emitting metrics via github.com/hashicorp/go-metrics/compat. In discussions with other engineers it came up that if new metrics are added it would be good to ensure that they use the compat package as well. To that end, this PR introduces linter rules to ensure only the compat package is used.

@mkeeler mkeeler requested review from a team as code owners January 9, 2025 20:23
@mkeeler mkeeler requested a review from skpratt January 9, 2025 20:23
Copy link
Member

@schmichael schmichael left a comment

Choose a reason for hiding this comment

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

❤️ ❤️ ❤️ linting guardrails

@mkeeler mkeeler merged commit 8f99c15 into main Jan 9, 2025
11 checks passed
@mkeeler mkeeler deleted the metrics-compat-lint branch January 9, 2025 20:56
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