Skip to content

Reject exponential histogram aggregation views for async instruments - #5461

Open
Eason09053360 wants to merge 2 commits into
open-telemetry:mainfrom
Eason09053360:fix-async-exponential-histogram-incompatibility
Open

Reject exponential histogram aggregation views for async instruments#5461
Eason09053360 wants to merge 2 commits into
open-telemetry:mainfrom
Eason09053360:fix-async-exponential-histogram-incompatibility

Conversation

@Eason09053360

@Eason09053360 Eason09053360 commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Description

A View configuring ExponentialBucketHistogramAggregation on an
asynchronous instrument (e.g. ObservableCounter) is currently accepted
without any warning, but silently produces no data points forever:
asynchronous instruments report with CUMULATIVE instrument temporality, and
_ExponentialBucketHistogramAggregation.collect() only implements the DELTA
instrument temporality path, so every collection falls through and returnsNone.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • opentelemetry-sdk/tests/metrics/
  • test_metric_reader_storage.py

Does This PR Require a Contrib Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@Eason09053360
Eason09053360 requested a review from a team as a code owner July 26, 2026 14:25
@Eason09053360
Eason09053360 marked this pull request as draft July 26, 2026 14:26
@Eason09053360
Eason09053360 force-pushed the fix-async-exponential-histogram-incompatibility branch from 58a8dde to 4cd9352 Compare July 26, 2026 14:45
@Eason09053360
Eason09053360 marked this pull request as ready for review July 26, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant