-
Notifications
You must be signed in to change notification settings - Fork 1.3k
sdk/metric: Support specifying cardinality limits per instrument kinds #7855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
dmathieu
merged 38 commits into
open-telemetry:main
from
petern48:per-instrument-cardinality-limits
Mar 20, 2026
Merged
Changes from all commits
Commits
Show all changes
38 commits
Select commit
Hold shift + click to select a range
48e5871
Implement per instrument cardinality limits
petern48 1a99dbb
gofmt
petern48 e9ee1e2
Remove original cardinalityLimit field outside of the struct
petern48 e2132b9
clean up and add comments
petern48 6e14a8c
Add changelog
petern48 3de1a84
gofmt
petern48 857afca
Drop 'CardinalityLimit' from each field name to make the name shorter
petern48 38505bc
Rearrange order
petern48 56c399f
Collapse to multiple lines to make linter happy
petern48 e760138
Revert most changes
petern48 2441176
Implment fixes for the metric reader instead of provider
petern48 3ffbbf1
Change defaultCardinality limit to 2000 instead of 0, in accordance w…
petern48 c107413
Fix condition for getCardinalityLimit to be '>'
petern48 199d82e
gofmt
petern48 05876f2
Update changelog
petern48 722b87a
Merge branch 'main' into per-instrument-cardinality-limits
petern48 3abb16b
Move changelog entry back to new unreleased section
petern48 a556d92
Fix golangci-lint
petern48 b3c3f1c
Fix lint
petern48 18d7e96
Revert defaultCardinalityLimit back to 0, and update changelog
petern48 b71a446
Add godoc link from WithCardinalityLimit to WithKindCardinalityLimit
petern48 ed78ed0
Allow user to input a CardinalityLimitSelector (func) instead of indi…
petern48 ea5169a
Update name of api in changelog
petern48 668c3dc
Add extra note about behavior of returning 0 in the WithCardinalityLi…
petern48 2c06d2a
Support 'fallback' return value in order to distinguish unlimited fro…
petern48 d3216fc
Add test with a instrument kind set to unlimited without falling back…
petern48 090d9b1
Merge branch 'main' into per-instrument-cardinality-limits
petern48 6ef906a
Move changelog to new unreleased section
petern48 6dc505e
Update sdk/metric/pipeline.go
petern48 4b819e7
Use table-based testing pattern instead
petern48 654119a
Condense the table tests to improve readability
petern48 2f5ea7a
Make 'defaultCardinalityLimitSelector()' private instead of public
petern48 3e84fe2
Update sdk/metric/config_test.go
petern48 39131c1
fix after feedback
petern48 68c821f
feedback: Refactor tests to use func(Meter) and only use single-metri…
petern48 c5471d9
Merge branch 'main' into per-instrument-cardinality-limits + fix merg…
petern48 1c80474
Merge branch 'main' into per-instrument-cardinality-limits + fix merg…
petern48 313de28
Merge branch 'main' into per-instrument-cardinality-limits
dmathieu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.