Skip to content

[CONFIGURATION] Update ViewSelector to comply with schema v1.1.0 - #4384

Merged
dbarker merged 7 commits into
open-telemetry:mainfrom
dbarker:config_support_all_instrument_selectors
Aug 11, 2026
Merged

dbarker merged 7 commits into
open-telemetry:mainfrom
dbarker:config_support_all_instrument_selectors

Conversation

@dbarker

@dbarker dbarker commented Aug 8, 2026 •

Copy link
Copy Markdown
Member

Followup to: #4340

The schema includes synchronous gauge in the supported instrument types for view selection and defines a match all default behavior for unspecified instrument names and types. The current behavior is to throw an exception if the instrument type is not specified and select no instruments if the name is empty.

This PR adds support for gauge and fixes the default behavior of the selector to match the schema.

  ViewSelector:
    type: object
    additionalProperties: false
    properties:
      instrument_name:
        type:
          - string
          - "null"
        description: |
          Configure instrument name selection criteria.
        defaultBehavior: all instrument names match
      instrument_type:
        $ref: "#/$defs/InstrumentType"
        description: |
          Configure instrument type selection criteria.
        defaultBehavior: all instrument types match

Changes

  • Added synchronous gauge view-selector support with ABI v2
  • Fixed empty instrument name to match all instrument names
  • Fixed none instrument type to match all supported instrument types
  • Added SdkBuilder and programmatic config tests covering views and selection
  • Updates the kitchen-sink.yaml to cover supported view configurations

For significant contributions please make sure you have completed the following items:

  • CHANGELOG.md updated for non-trivial changes
  • Unit tests have been added
  • Changes in public API reviewed

@codecov

codecov Bot commented Aug 8, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 92.00000% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.10%. Comparing base (338ff7f) to head (4eb01bb).

Files with missing lines Patch % Lines
sdk/src/configuration/sdk_builder.cc 91.67% 4 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4384      +/-   ##
==========================================
+ Coverage   81.92%   82.10%   +0.19%     
==========================================
  Files         494      494              
  Lines       19658    19670      +12     
==========================================
+ Hits        16103    16149      +46     
+ Misses       3555     3521      -34     
Files with missing lines Coverage Δ
sdk/src/configuration/configuration_parser.cc 79.65% <100.00%> (+0.99%) ⬆️
sdk/src/configuration/sdk_builder.cc 55.23% <91.67%> (+2.46%) ⬆️

... and 1 file with indirect coverage changes

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

@dbarker
dbarker marked this pull request as ready for review August 9, 2026 14:16
@dbarker
dbarker requested a review from a team as a code owner August 9, 2026 14:16

@marcalff marcalff left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, see minor nit.

Thanks for all the test cases.

@dbarker
dbarker merged commit 768d04d into open-telemetry:main Aug 11, 2026
123 of 125 checks passed
@dbarker
dbarker deleted the config_support_all_instrument_selectors branch August 11, 2026 01:28
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