Conversation
# Conflicts: # cmd/tools/generate/counter.go
Contributor
Author
|
updating the |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR expands the metrics generation pipeline to track where each metric is used in Grafana dashboards and surface that usage in the generated documentation.
- Propagate a
metricsPanelMapthroughBuildMetricsand related functions, collecting dashboard/panel metadata. - Introduce
visitDashboard/visitExpressionsto walk JSON dashboards and fillmetricsPanelMap. - Update the counter template and
Countertype to render a “Visualized in” section listing dashboards that use each metric.
Reviewed Changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| integration/test/alert_rule_test.go | Updated test to pass a new metricsPanelMap into BuildMetrics |
| grafana/dashboards/cmode/flexgroup.json | Fixed default row title from “Highlight” to “Highlights” |
| cmd/tools/grafana/metrics.go | Renamed exprP→ExprP, enriched expression metadata, updated DoTarget/NewExpr signatures |
| cmd/tools/grafana/dashboard_test.go | Updated tests to use the new ExprP and updated function signatures |
| cmd/tools/generate/generate.go | Changed BuildMetrics signature, added visitDashboard call in generator, wired metricsPanelMap |
| cmd/tools/generate/counter.tmpl | Extended the template to render a dashboard usage table per metric |
| cmd/tools/generate/counter.go | Added PanelDef/PanelData, integrated panels into Counter, updated merging logic |
| cmd/tools/generate/* (various) | Propagated metricsPanelMap through all process*Counters calls |
Comments suppressed due to low confidence (1)
cgrinds
reviewed
Jun 18, 2025
# Conflicts: # docs/ontap-metrics.md
Contributor
|
We need to have same names for panels for cases like below. Average Disk Utilization per Aggregate |
Contributor
|
Could you check if links open in a new tab when clicked? |
rahulguptajss
previously approved these changes
Jun 23, 2025
…ics documentation
cgrinds
approved these changes
Jun 24, 2025
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
No description provided.