Skip to content

[receiver/azuremonitor] Fix metric data loss and incorrect timestamps#49532

Open
vishalmore90 wants to merge 1 commit into
open-telemetry:mainfrom
vishalmore90:fix-issue-49508
Open

[receiver/azuremonitor] Fix metric data loss and incorrect timestamps#49532
vishalmore90 wants to merge 1 commit into
open-telemetry:mainfrom
vishalmore90:fix-issue-49508

Conversation

@vishalmore90

@vishalmore90 vishalmore90 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Description

Fixes metric data loss and incorrect timestamping in the azuremonitor receiver:

  • Tracks the last emitted timestamp per unique timeseries (resourceID + metricName + dimensions) to filter out already-emitted historical data.
  • Processes all newly populated data points in chronological order instead of breaking after the first one.
  • Uses actual Azure timestamps in the non-batch scraper (scraper.go) instead of replacing them with time.Now().

Fixes #49508

Testing

Unit tests updated to verify correct chronological ordering of multiple data points, use of correct Azure timestamps, and no duplicate emissions on subsequent scrapes.

@vishalmore90 vishalmore90 requested a review from a team as a code owner July 7, 2026 16:10
@vishalmore90 vishalmore90 requested a review from codeboten July 7, 2026 16:10
Signed-off-by: vishal <httpsvishal07@gmail.com>
@vishalmore90 vishalmore90 changed the title [chore] [receiver/azuremonitor] Fix metric data loss and incorrect timestamps [receiver/azuremonitor] Fix metric data loss and incorrect timestamps Jul 7, 2026
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.

[receiver/azuremonitor] Accuracy not perfect

1 participant