Skip to content

fix #3990: query metric history by monitor ID instead of instance - #4351

Open
yykaue wants to merge 2 commits into
apache:masterfrom
yykaue:fix-3990-metric-history-monitor-id
Open

fix #3990: query metric history by monitor ID instead of instance#4351
yykaue wants to merge 2 commits into
apache:masterfrom
yykaue:fix-3990-metric-history-monitor-id

Conversation

@yykaue

@yykaue yykaue commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

What's changed?

Fixes #3990.

  • Pass monitorId from the metric history chart to the backend API.
  • Query VictoriaMetrics history data using the __monitor_id__ label instead of instance.
  • Apply the fix to both single-node and cluster VictoriaMetrics storage.
  • Support both regular and interval metric history queries.
  • Preserve the existing instance-based behavior when monitorId is not provided or unsupported by the storage backend.
  • Add regression tests for the controller, service, frontend request, and VictoriaMetrics queries.

Testing

  • Backend targeted tests: 19 passed, 0 failures.
  • Frontend targeted tests: 2 passed, 0 failures.
  • Maven Checkstyle: passed with 0 violations.
  • Frontend ESLint: passed.

Checklist

  • I have read the Contributing Guide.
  • I have written the necessary doc or comment.
  • I have added the necessary unit tests and all cases have passed.
…VictoriaMetrics storage to support monitor-based filtering
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

1 participant