-
Notifications
You must be signed in to change notification settings - Fork 0
Add bars for more device metrics (processes, threads, net stat) #18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughGrafana dashboard JSON updated: multiple panel widths and x positions adjusted to reflow layout; seven new telemetry panels added (Processes, Threads, NET-Recv, NET-Sent, TCP Est., TCP Wait, UDP Est., plus SD Card bargauge); Flux queries use group → sort(desc: true) |> limit(1) for latest per-device samples; dashboard version bumped 33→34. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant U as User
participant G as Grafana
participant I as InfluxDB
U->>G: Open/refresh "overview_of_devices"
rect #F0F8FF
note right of G: Latest-sample panels (group → sort(desc) → limit(1))
G->>I: range() |> filter(...) |> group(by:["device"]) |> sort(columns:["_time"], desc:true) |> limit(1)
I-->>G: Latest sample per device
end
rect #F5FFFA
note right of G: Network rate panels (derivative → mean → group → sort → limit)
G->>I: range() |> filter(interface:"eth0", ...) |> derivative(unit:1s, nonNegative:true) |> mean() |> group(...) |> sort(columns:["_time"], desc:true) |> limit(1)
I-->>G: Rate/mean values per device
end
rect #FFF8E1
note right of G: Render new stat/bargauge panels
G->>G: Apply transforms/formatting, render dashboard
G-->>U: Updated dashboard displayed
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (2)dashboard-deployments/**⚙️ CodeRabbit configuration file
Files:
**/*⚙️ CodeRabbit configuration file
Files:
🧠 Learnings (1)📚 Learning: 2025-09-03T14:18:52.406ZApplied to files:
Comment |
🎨 Code Formatting RequiredPrettier Formatting IssuesSome files need to be formatted with Prettier (JSON, YAML, Markdown). Files that need prettier formatting:
To fix prettier issues: npx prettier@3.6.0 --write "**/*.{json,yml,yaml,md}" ".github/**/*.{json,yml,yaml,md}" ".*.{yml,yaml,json,md}" --ignore-unknownAfter fixing:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🧹 Nitpick comments (6)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (6)
548-609: Good switch to raw Flux + sort/limit; remove stale InfluxQL fields.The rawQuery + sort/limit pattern is solid. The builder props (groupBy/orderByTime/policy/select/tags) are ignored for Flux; consider dropping them to reduce noise.
"targets": [ { "datasource": { "type": "influxdb", "uid": "${datasource}" }, - "groupBy": [ - {"params": ["$__interval"], "type": "time"}, - {"params": ["null"], "type": "fill"} - ], - "orderByTime": "ASC", - "policy": "default", "query": "from(bucket: \"${bucket}\")\n // Filter on time\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n // Filter on the right device. Since this visual will be repeated, the\n // device variable will always contain the right value and only one,\n // so we do not need to do regexp here..\n |> filter(fn: (r) => r[\"${unique_identifier}\"] == \"${device}\")\n // Filter on the field we want\n |> filter(fn: (r) => r[\"_measurement\"] == \"system\")\n |> filter(fn: (r) => r[\"_field\"] == \"uptime\")\n // Group by device to merge multiple tagsets\n |> group(columns: [\"${unique_identifier}\"])\n // Get the last sample. Note that last() does not work after\n // group, so we use sort+limit instead.\n |> sort(columns: [\"_time\"], desc: true)\n |> limit(n: 1)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", - "select": [[{"params": ["value"], "type": "field"}, {"params": [], "type": "mean"}]], - "tags": [] } ],
647-693: CPU usage inversion looks right; align threshold modes.You invert idle to usage correctly. Consider using the same thresholds.mode (“percentage”) here as in RAM for consistency.
730-774: RAM query pattern LGTM; standardize threshold mode/steps.Functionally good. Optional: align threshold mode/step values with CPU to make colors comparable across panels.
811-857: Hard-coded disk path risks empty data; parameterize path.Not all Axis devices mount /usr/local the same way. Make path a dashboard variable (e.g., storage_path, default “/usr/local”) and use a regex filter.
- |> filter(fn: (r) => r["path"] == "/usr/local") + |> filter(fn: (r) => r["path"] =~ /${storage_path:regex}/)I can add a templating variable and update both Storage/SD Card panels on request.
894-940: SD path should be configurable.Same as Storage: parameterize “/var/spool/storage/SD_DISK” via a variable (e.g., sd_path) to keep the dashboard portable across devices/firmware.
1233-1241: Bucket name prefix “cameras” reduces portability.Expose a bucket name/prefix variable (e.g., bucket_prefix default “cameras”) to avoid tying examples to a single deployment naming scheme.
- |> filter(fn: (r) => strings.hasPrefix(v: strings.toLower(v: r.name), prefix: "cameras")) + |> filter(fn: (r) => strings.hasPrefix(v: strings.toLower(v: r.name), prefix: "${bucket_prefix}"))
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json(11 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
dashboard-deployments/**
⚙️ CodeRabbit configuration file
This directory contains server-side dashboard examples for visualizing data from FixedIT Data Agent running on Axis devices. These are primarily for DevOps/IT professionals comfortable with deploying Grafana dashboards and InfluxDB servers. Some dashboards work directly with bundled agent configurations, others can be customized. Licensed under Elastic License 2.0. Review for deployment complexity, dashboard usability, and proper licensing compliance. We should make sure that dashboards are portable and does not check in specific host names, or refer to other specific data from a single deployment.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
**/*
⚙️ CodeRabbit configuration file
This repository serves FixedIT Data Agent users across a spectrum from plug-and-play dashboard deployment to advanced edge device customization. Consider whether changes maintain accessibility for both DevOps professionals (server-side focus) and developers (edge customization focus). If new features are added or existing ones changed significantly, ensure documentation clearly explains the intended audience and usage level. We use prettier for formatting of common file formats like markdown, yaml, json, etc. Example projects should be placed in the repo-root in a directory named project-*/. Whenever referencing Axis device model names like "D4100-VE mk II" or "M3045", prefix it with "AXIS" in capital letters (e.g. "AXIS D4100-VE mk II"). When using Axis as a company name, use "Axis Communications", note that all-caps is only used when "AXIS" is used in their product names, not their company name. When using the name of an Axis product, google on the name to verify that it is correctly identified. Avoid using 'cameras' or 'Axis cameras' unless the solution in related to visual analytics, otherwise prefer using 'Axis devices' to show that the FixedIT Data Agent also works with strobes, speakers, door stations, etc. Images used for the README should be placed in a directory called .images/ in the affected project folder. These images might also be referred to from other sources like the top-level README.md file.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🔇 Additional comments (3)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (3)
942-1006: Processes stat: solid addition.Query and reducers look correct; no issues.
1008-1072: Threads stat: LGTM.Matches measurement/field; consistent with Processes panel.
1447-1450: Version bump OK.Dashboard version increment aligns with changes.
| { | ||
| "datasource": { | ||
| "type": "influxdb", | ||
| "uid": "${datasource}" | ||
| }, | ||
| "query": "from(bucket: \"${bucket}\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => r[\"${unique_identifier}\"] == \"${device}\")\n |> filter(fn: (r) => r[\"_measurement\"] == \"net\")\n |> filter(fn: (r) => r[\"interface\"] == \"eth0\")\n |> filter(fn: (r) => r[\"_field\"] == \"bytes_recv\")\n |> derivative(unit: 1s, nonNegative: true)\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\n // Group by device to merge multiple tagsets\n |> group(columns: [\"${unique_identifier}\"])\n // Get the last sample. Note that last() does not work after\n // group, so we use sort+limit instead.\n |> sort(columns: [\"_time\"], desc: true)\n |> limit(n: 1)\n |> yield(name: \"mean\")", | ||
| "refId": "A" | ||
| } | ||
| ], | ||
| "title": "NET-Recv", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NET-Recv shows bytes/s but unit is bits/s (bps). Multiply by 8.
derivative returns bytes per second; panel unit is bps, so values are off by 8x.
|> derivative(unit: 1s, nonNegative: true)
|> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)
+ |> map(fn: (r) => ({ r with _value: r._value * 8.0 }))Also consider making interface (“eth0”) a variable (net_iface) for portability.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| { | |
| "datasource": { | |
| "type": "influxdb", | |
| "uid": "${datasource}" | |
| }, | |
| "query": "from(bucket: \"${bucket}\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => r[\"${unique_identifier}\"] == \"${device}\")\n |> filter(fn: (r) => r[\"_measurement\"] == \"net\")\n |> filter(fn: (r) => r[\"interface\"] == \"eth0\")\n |> filter(fn: (r) => r[\"_field\"] == \"bytes_recv\")\n |> derivative(unit: 1s, nonNegative: true)\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\n // Group by device to merge multiple tagsets\n |> group(columns: [\"${unique_identifier}\"])\n // Get the last sample. Note that last() does not work after\n // group, so we use sort+limit instead.\n |> sort(columns: [\"_time\"], desc: true)\n |> limit(n: 1)\n |> yield(name: \"mean\")", | |
| "refId": "A" | |
| } | |
| ], | |
| "title": "NET-Recv", | |
| { | |
| "datasource": { | |
| "type": "influxdb", | |
| "uid": "${datasource}" | |
| }, | |
| "query": "from(bucket: \"${bucket}\")\n |> range(start: v.timeRangeStart, stop: v.timeRangeStop)\n |> filter(fn: (r) => r[\"${unique_identifier}\"] == \"${device}\")\n |> filter(fn: (r) => r[\"_measurement\"] == \"net\")\n |> filter(fn: (r) => r[\"interface\"] == \"eth0\")\n |> filter(fn: (r) => r[\"_field\"] == \"bytes_recv\")\n |> derivative(unit: 1s, nonNegative: true)\n |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false)\n |> map(fn: (r) => ({ r with _value: r._value * 8.0 }))\n // Group by device to merge multiple tagsets\n |> group(columns: [\"${unique_identifier}\"])\n // Get the last sample. Note that last() does not work after\n // group, so we use sort+limit instead.\n |> sort(columns: [\"_time\"], desc: true)\n |> limit(n: 1)\n |> yield(name: \"mean\")", | |
| "refId": "A" | |
| } |
🤖 Prompt for AI Agents
In
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
around lines 1127-1136, the Flux query returns bytes/sec but the panel unit is
bits/sec; multiply the timeseries by 8 after the derivative/aggregateWindow step
so the panel shows bps, and replace the hardcoded interface filter "eth0" with a
variable reference (e.g. "${net_iface}") so the dashboard is portable; ensure
the multiplication happens before the final sort/limit/yield and update
dashboard variables to include net_iface with a sensible default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed unit to Bps (B/s)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@daniel-falk Perfect! Changing the unit to "Bps" (bytes per second) is a clean solution that aligns the panel display with the actual data returned by the derivative() function. This eliminates the 8x factor discrepancy without requiring additional query transformations.
The unit mismatch is now resolved. The interface hardcoding ("eth0") suggestion for portability remains, but that's a separate enhancement that can be addressed later if needed.
✏️ Learnings added
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-data-agent-examples#18
File: dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json:1121-1130
Timestamp: 2025-09-03T14:18:52.369Z
Learning: When fixing unit mismatches in Grafana dashboards, daniel-falk prefers changing the panel unit configuration to match the data rather than transforming the query values, choosing simplicity over data conversion when both approaches are valid.
Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.
...ts/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
Show resolved
Hide resolved
19a0f5a to
91161bd
Compare
🎨 Code Formatting RequiredPrettier Formatting IssuesSome files need to be formatted with Prettier (JSON, YAML, Markdown). Files that need prettier formatting:
To fix prettier issues: npx prettier@3.6.0 --write "**/*.{json,yml,yaml,md}" ".github/**/*.{json,yml,yaml,md}" ".*.{yml,yaml,json,md}" --ignore-unknownAfter fixing:
|
91161bd to
5a501c3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (1)
1400-1430: Add a “Network Interface” variable to make NET panels portable.Introduce net_iface so users aren’t locked to “eth0”. Default to All.
Add this to templating.list:
{ "allValue": ".*", "allowCustomValue": false, "current": { "text": "All", "value": "$__all" }, "datasource": { "type": "influxdb", "uid": "${datasource}" }, "definition": "import \"influxdata/influxdb/schema\"\n\nschema.tagValues(bucket: \"${bucket}\", tag: \"interface\")", "includeAll": true, "label": "Network Interface", "multi": true, "name": "net_iface", "query": { "query": "import \"influxdata/influxdb/schema\"\n\nschema.tagValues(bucket: \"${bucket}\", tag: \"interface\")" }, "refresh": 1, "type": "query" }Want me to push a follow-up commit adding this and wiring both NET panels?
♻️ Duplicate comments (2)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (2)
1121-1127: NET-Recv: bytes→bits mismatch and hardcoded interface. Convert and template the iface.Panel unit is bps, but query returns bytes/s. Also “eth0” is hardcoded, hurting portability. Multiply by 8 after derivative/aggregation and use a net_iface variable.
Apply this diff inside the query:
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] =~ /${net_iface:regex}/) |> filter(fn: (r) => r["_field"] == "bytes_recv") |> derivative(unit: 1s, nonNegative: true) |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false) + |> map(fn: (r) => ({ r with _value: r._value * 8.0 })) // bytes/s -> bits/sAdd a dashboard variable for interfaces (see separate comment).
1185-1193: NET-Sent: same unit/iface issues as NET-Recv. Fix consistently.Mirror the conversion and interface templating here.
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] =~ /${net_iface:regex}/) |> filter(fn: (r) => r["_field"] == "bytes_sent") |> derivative(unit: 1s, nonNegative: true) |> aggregateWindow(every: v.windowPeriod, fn: mean, createEmpty: false) + |> map(fn: (r) => ({ r with _value: r._value * 8.0 })) // bytes/s -> bits/s
🧹 Nitpick comments (2)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (2)
846-853: Make disk path configurable for portability.Hardcoded “/usr/local” may not exist across Axis devices/sites. Template it.
- |> filter(fn: (r) => r["path"] == "/usr/local") + |> filter(fn: (r) => r["path"] =~ /${disk_path:regex}/)Optionally add a templating variable:
{ "allValue": ".*", "allowCustomValue": false, "current": { "text": "All", "value": "$__all" }, "datasource": { "type": "influxdb", "uid": "${datasource}" }, "definition": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"path\")", "includeAll": true, "label": "Disk Path", "multi": true, "name": "disk_path", "query": { "query": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"path\")" }, "refresh": 1, "type": "query" }
929-936: SD card path is deployment-specific; template it or broaden the match.“/var/spool/storage/SD_DISK” might vary (or be absent). Prefer a variable-backed filter.
- |> filter(fn: (r) => r["path"] == "/var/spool/storage/SD_DISK") + |> filter(fn: (r) => r["path"] =~ /${sd_path:regex}/)Or reuse disk_path if you don’t want a second variable. If you keep a dedicated one:
{ "allValue": ".*", "allowCustomValue": false, "current": { "text": "All", "value": "$__all" }, "datasource": { "type": "influxdb", "uid": "${datasource}" }, "definition": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"path\")", "includeAll": true, "label": "SD Path", "multi": true, "name": "sd_path", "query": { "query": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"path\")" }, "refresh": 1, "type": "query" }
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json(6 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
dashboard-deployments/**
⚙️ CodeRabbit configuration file
This directory contains server-side dashboard examples for visualizing data from FixedIT Data Agent running on Axis devices. These are primarily for DevOps/IT professionals comfortable with deploying Grafana dashboards and InfluxDB servers. Some dashboards work directly with bundled agent configurations, others can be customized. Licensed under Elastic License 2.0. Review for deployment complexity, dashboard usability, and proper licensing compliance. We should make sure that dashboards are portable and does not check in specific host names, or refer to other specific data from a single deployment.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
**/*
⚙️ CodeRabbit configuration file
This repository serves FixedIT Data Agent users across a spectrum from plug-and-play dashboard deployment to advanced edge device customization. Consider whether changes maintain accessibility for both DevOps professionals (server-side focus) and developers (edge customization focus). If new features are added or existing ones changed significantly, ensure documentation clearly explains the intended audience and usage level. We use prettier for formatting of common file formats like markdown, yaml, json, etc. Example projects should be placed in the repo-root in a directory named project-*/. Whenever referencing Axis device model names like "D4100-VE mk II" or "M3045", prefix it with "AXIS" in capital letters (e.g. "AXIS D4100-VE mk II"). When using Axis as a company name, use "Axis Communications", note that all-caps is only used when "AXIS" is used in their product names, not their company name. When using the name of an Axis product, google on the name to verify that it is correctly identified. Avoid using 'cameras' or 'Axis cameras' unless the solution in related to visual analytics, otherwise prefer using 'Axis devices' to show that the FixedIT Data Agent also works with strobes, speakers, door stations, etc. Images used for the README should be placed in a directory called .images/ in the affected project folder. These images might also be referred to from other sources like the top-level README.md file.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🔇 Additional comments (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (1)
547-553: Layout reflow to width=2 across bars looks good.Compact bars improve scan-ability and free space for new stats.
Also applies to: 649-653, 730-736, 811-817, 894-900
5a501c3 to
8d040d9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (1)
1121-1128: Parameterize network interface (avoid hardcoded eth0).Dashboards under dashboard-deployments should be portable. Introduce a net_iface variable and use it in the filters.
Apply in both NET-Recv and NET-Sent queries:
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] == "${net_iface}")Add a templating variable (outside this hunk) so users can pick the interface:
{ "name": "net_iface", "label": "Net Interface", "type": "query", "datasource": { "type": "influxdb", "uid": "${datasource}" }, "definition": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"interface\")", "includeAll": false, "refresh": 1, "current": { "text": "eth0", "value": "eth0" } }Also applies to: 1185-1192
🧹 Nitpick comments (3)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (3)
955-965: Threshold mode should be absolute for non-percent metrics.Processes and Threads are counts; percentage thresholds are misleading. Switch to absolute (or drop thresholds until meaningful ranges are known).
- "thresholds": { - "mode": "percentage", + "thresholds": { + "mode": "absolute", "steps": [ { "color": "orange", "value": 0 } ] }, - "unit": "none" + "unit": "none"Also applies to: 1020-1029
1358-1359: Clarify title: “TCP Wait” → “TCP Close Wait”.Matches the tcp_close_wait field and reduces ambiguity.
- "title": "TCP Wait", + "title": "TCP Close Wait",
942-1004: Nice additions; consider splitting fixes vs. new bars per PR note.New stat/bargauge panels for processes/threads/netstat look consistent with existing patterns. Per PR description, separating “fixes to existing bars” from “new bars” will ease review and unblock merges not dependent on the upcoming Data Agent release. I can help craft a follow-up commit.
Also applies to: 1006-1068, 1198-1278, 1280-1360, 1362-1442
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json(6 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
dashboard-deployments/**
⚙️ CodeRabbit configuration file
This directory contains server-side dashboard examples for visualizing data from FixedIT Data Agent running on Axis devices. These are primarily for DevOps/IT professionals comfortable with deploying Grafana dashboards and InfluxDB servers. Some dashboards work directly with bundled agent configurations, others can be customized. Licensed under Elastic License 2.0. Review for deployment complexity, dashboard usability, and proper licensing compliance. We should make sure that dashboards are portable and does not check in specific host names, or refer to other specific data from a single deployment.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
**/*
⚙️ CodeRabbit configuration file
This repository serves FixedIT Data Agent users across a spectrum from plug-and-play dashboard deployment to advanced edge device customization. Consider whether changes maintain accessibility for both DevOps professionals (server-side focus) and developers (edge customization focus). If new features are added or existing ones changed significantly, ensure documentation clearly explains the intended audience and usage level. We use prettier for formatting of common file formats like markdown, yaml, json, etc. Example projects should be placed in the repo-root in a directory named project-*/. Whenever referencing Axis device model names like "D4100-VE mk II" or "M3045", prefix it with "AXIS" in capital letters (e.g. "AXIS D4100-VE mk II"). When using Axis as a company name, use "Axis Communications", note that all-caps is only used when "AXIS" is used in their product names, not their company name. When using the name of an Axis product, google on the name to verify that it is correctly identified. Avoid using 'cameras' or 'Axis cameras' unless the solution in related to visual analytics, otherwise prefer using 'Axis devices' to show that the FixedIT Data Agent also works with strobes, speakers, door stations, etc. Images used for the README should be placed in a directory called .images/ in the affected project folder. These images might also be referred to from other sources like the top-level README.md file.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🔇 Additional comments (2)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (2)
549-549: Layout tightening LGTM.Width reductions to 2 columns keep parity across bars and improve density without harming readability.
Also applies to: 649-651, 732-734, 813-815, 896-898
1092-1093: Correct unit for NET panels.Using Bps matches derivative(bytes)/s. Thanks for fixing the earlier mismatch.
Also applies to: 1156-1157
| "title": "UDP Est.", | ||
| "type": "bargauge" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix misleading title: UDP is connectionless.
Field is udp_socket; “UDP Est.” suggests “established,” which doesn’t apply to UDP. Rename.
- "title": "UDP Est.",
+ "title": "UDP Sockets",📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "title": "UDP Est.", | |
| "type": "bargauge" | |
| "title": "UDP Sockets", | |
| "type": "bargauge" |
🤖 Prompt for AI Agents
In
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
around lines 1440-1441, the panel title "UDP Est." is misleading because UDP is
connectionless; update the title to accurately reflect the udp_socket field (for
example "UDP Sockets" or "UDP Socket Count") so the panel clearly describes the
metric, and ensure any tooltip/legend text matches the new title.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What would be a good short name for it? Sockets it too long to fit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@daniel-falk Looking at the other panel titles in your dashboard, here are some short alternatives that would fit the space:
- "UDP" (3 chars) - Matches the brevity of "CPU", "RAM"
- "UDP #" (5 chars) - The # symbol clearly indicates count
- "UDP Sock" (8 chars) - Same length as "TCP Est.", "NET-Recv"
I'd recommend "UDP" since it's the shortest and follows the pattern of your other concise panel titles. The context of it being a system monitoring dashboard makes it clear this refers to UDP socket count.
9160df4 to
c73533a
Compare
8d040d9 to
05d474a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (1)
1449-1465: Add a dashboard variable for network interfaceTo support the earlier portability change, add a templating variable with a default of eth0. You can later switch to a query-driven list if needed.
Add to templating.list (position doesn’t matter):
{ "name": "net_iface", "label": "Net Interface", "type": "constant", "hide": 0, "query": "eth0", "current": { "text": "eth0", "value": "eth0" }, "skipUrlSync": false, "description": "Default network interface for NET panels" }If you prefer a query-driven list per bucket/device later, we can draft a Flux variable query.
♻️ Duplicate comments (3)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (3)
1361-1442: Fix misleading UDP titleUDP is connectionless; suggest “UDP Sockets” to reflect udp_socket.
- "title": "UDP Est.", + "title": "UDP Sockets",
1070-1132: Make network interface selectable; avoid hardcoded "eth0"For portability (per repo guidelines), use a template variable instead of a fixed interface.
Apply inside this panel’s query:
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] == "${net_iface}")Then add a dashboard variable (templating) with a sensible default (see separate snippet below under the templating section).
1133-1196: Mirror interface variable change for NET-SentSame portability fix as NET-Recv; replace hardcoded "eth0" with "${net_iface}".
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] == "${net_iface}")
🧹 Nitpick comments (5)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (5)
942-1004: Processes stat: consider integer-friendly formattingUse unit "short" for nicer 1.2k style formatting; current thresholds mode "percentage" is odd for counts.
- "thresholds": { - "mode": "percentage", + "thresholds": { + "mode": "absolute", "steps": [ { "color": "orange", "value": 0 } ] }, - "unit": "none" + "unit": "short"
1006-1068: Threads stat: mirror Processes formattingSame suggestion as Processes: absolute thresholds and unit "short".
- "thresholds": { - "mode": "percentage", + "thresholds": { + "mode": "absolute", "steps": [ { "color": "orange", "value": 0 } ] }, - "unit": "none" + "unit": "short"
1197-1278: Title clarity (optional): “TCP Est.” → “TCP Established”Spelling it out aids non-experts scanning the dashboard.
- "title": "TCP Est.", + "title": "TCP Established",
1280-1360: Match title to metric: use “TCP Close Wait”Field is tcp_close_wait; title “TCP Wait” is vague.
- "title": "TCP Wait", + "title": "TCP Close Wait",
1663-1676: Wording: avoid “camera” in generic dashboardsGuidelines suggest “Axis devices” unless it’s visual analytics. Update description.
- "description": "Model of the camera", + "description": "Axis device model",
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json(6 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
dashboard-deployments/**
⚙️ CodeRabbit configuration file
This directory contains server-side dashboard examples for visualizing data from FixedIT Data Agent running on Axis devices. These are primarily for DevOps/IT professionals comfortable with deploying Grafana dashboards and InfluxDB servers. Some dashboards work directly with bundled agent configurations, others can be customized. Licensed under Elastic License 2.0. Review for deployment complexity, dashboard usability, and proper licensing compliance. We should make sure that dashboards are portable and does not check in specific host names, or refer to other specific data from a single deployment.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
**/*
⚙️ CodeRabbit configuration file
This repository serves FixedIT Data Agent users across a spectrum from plug-and-play dashboard deployment to advanced edge device customization. Consider whether changes maintain accessibility for both DevOps professionals (server-side focus) and developers (edge customization focus). If new features are added or existing ones changed significantly, ensure documentation clearly explains the intended audience and usage level. We use prettier for formatting of common file formats like markdown, yaml, json, etc. Example projects should be placed in the repo-root in a directory named project-*/. Whenever referencing Axis device model names like "D4100-VE mk II" or "M3045", prefix it with "AXIS" in capital letters (e.g. "AXIS D4100-VE mk II"). When using Axis as a company name, use "Axis Communications", note that all-caps is only used when "AXIS" is used in their product names, not their company name. When using the name of an Axis product, google on the name to verify that it is correctly identified. Avoid using 'cameras' or 'Axis cameras' unless the solution in related to visual analytics, otherwise prefer using 'Axis devices' to show that the FixedIT Data Agent also works with strobes, speakers, door stations, etc. Images used for the README should be placed in a directory called .images/ in the affected project folder. These images might also be referred to from other sources like the top-level README.md file.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🧠 Learnings (1)
📚 Learning: 2025-09-03T14:18:52.369Z
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-data-agent-examples#18
File: dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json:1121-1130
Timestamp: 2025-09-03T14:18:52.369Z
Learning: When fixing unit mismatches in Grafana dashboards, daniel-falk prefers changing the panel unit configuration to match the data rather than transforming the query values, choosing simplicity over data conversion when both approaches are valid.
Applied to files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🔇 Additional comments (7)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (7)
547-552: Layout compaction (w=2) for Uptime: LGTMTighter grid helps fit more KPIs without clutter.
647-652: Layout compaction (w=2) for CPU: LGTMKeeps row density consistent with neighboring panels.
730-735: Layout compaction (w=2) for RAM: LGTMConsistent with CPU and Uptime panels.
811-816: Layout compaction (w=2) for Storage: LGTMNo functional impact; improves use of horizontal space.
894-900: Layout compaction (w=2) for SD Card: LGTMMatches the rest of the summary bar gauges.
1092-1093: Unit set to Bps aligns with derivative(bytes): LGTMMatches the data without extra Flux math. Noting your stated preference for unit fixes over query transforms; good call.
1156-1157: Unit set to Bps for NET-Sent: LGTMConsistent with NET-Recv and Flux derivative output.
ddd017b to
9ed01d4
Compare
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (1)
1431-1441: Rename “UDP Est.” (UDP is connectionless)Short title alternatives previously discussed: “UDP” or “UDP #”. Recommend “UDP” to match brevity of other bars.
- "title": "UDP Est.", + "title": "UDP",
🧹 Nitpick comments (4)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (4)
942-1004: Processes panel depends on next agent release — consider soft-failing UXThis will read “No data” until the Data Agent exposes processes.total. Optional: add value mappings to display “—” or “N/A” explicitly when null, so the dashboard doesn’t look broken while the PR is blocked.
Apply mappings inline:
"fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, + "mappings": [ + { + "options": { + "match": "null", + "result": { "text": "N/A" } + }, + "type": "special" + } + ],If you want, I can also add a short “Requires Data Agent ≥ ” description to the panel once the target version is known.
1032-1068: Threads panel mirrors Processes — apply same N/A mappingKeep UX consistent while data is unavailable.
- "mappings": [], + "mappings": [ + { + "options": { + "match": "null", + "result": { "text": "N/A" } + }, + "type": "special" + } + ],Confirm the field name will be processes.total_threads in the upcoming release.
1121-1127: Make interface selectable; keep unit as Bps per your preferenceHardcoding “eth0” reduces portability. Add a dashboard variable (net_iface, default “eth0”) and filter by that instead. Unit is already Bps, which aligns with derivative bytes/sec — good.
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] == "${net_iface}")Add this templating variable (outside this hunk):
{ "allValue": ".*", "allowCustomValue": false, "current": { "text": "eth0", "value": "eth0" }, "datasource": { "type": "influxdb", "uid": "${datasource}" }, "definition": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"interface\")", "includeAll": false, "label": "Interface", "multi": false, "name": "net_iface", "options": [], "query": { "query": "import \"influxdata/influxdb/schema\"\nschema.tagValues(bucket: \"${bucket}\", tag: \"interface\")" }, "refresh": 1, "regex": "", "type": "query" }I can wire this variable into NET-Sent too and update the README with a one-liner.
1185-1191: Mirror interface variable in NET-SentKeep NET-Recv/NET-Sent symmetric.
- |> filter(fn: (r) => r["interface"] == "eth0") + |> filter(fn: (r) => r["interface"] == "${net_iface}")
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json(9 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
dashboard-deployments/**
⚙️ CodeRabbit configuration file
This directory contains server-side dashboard examples for visualizing data from FixedIT Data Agent running on Axis devices. These are primarily for DevOps/IT professionals comfortable with deploying Grafana dashboards and InfluxDB servers. Some dashboards work directly with bundled agent configurations, others can be customized. Licensed under Elastic License 2.0. Review for deployment complexity, dashboard usability, and proper licensing compliance. We should make sure that dashboards are portable and does not check in specific host names, or refer to other specific data from a single deployment.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
**/*
⚙️ CodeRabbit configuration file
This repository serves FixedIT Data Agent users across a spectrum from plug-and-play dashboard deployment to advanced edge device customization. Consider whether changes maintain accessibility for both DevOps professionals (server-side focus) and developers (edge customization focus). If new features are added or existing ones changed significantly, ensure documentation clearly explains the intended audience and usage level. We use prettier for formatting of common file formats like markdown, yaml, json, etc. Example projects should be placed in the repo-root in a directory named project-*/. Whenever referencing Axis device model names like "D4100-VE mk II" or "M3045", prefix it with "AXIS" in capital letters (e.g. "AXIS D4100-VE mk II"). When using Axis as a company name, use "Axis Communications", note that all-caps is only used when "AXIS" is used in their product names, not their company name. When using the name of an Axis product, google on the name to verify that it is correctly identified. Avoid using 'cameras' or 'Axis cameras' unless the solution in related to visual analytics, otherwise prefer using 'Axis devices' to show that the FixedIT Data Agent also works with strobes, speakers, door stations, etc. Images used for the README should be placed in a directory called .images/ in the affected project folder. These images might also be referred to from other sources like the top-level README.md file.
Files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🧠 Learnings (1)
📚 Learning: 2025-09-03T14:18:52.406Z
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-data-agent-examples#18
File: dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json:1121-1130
Timestamp: 2025-09-03T14:18:52.406Z
Learning: When fixing unit mismatches in Grafana dashboards, daniel-falk prefers changing the panel unit configuration to match the data rather than transforming the query values, choosing simplicity over data conversion when both approaches are valid.
Applied to files:
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json
🔇 Additional comments (10)
dashboard-deployments/system-monitoring-influxdb2-flux-grafana/provisioning/dashboards/overview_of_devices.json (10)
82-98: Device link override matches rename — good cohesionThe byName="Device" matcher aligns with the later rename in the table transform, so the deep-link will stay stable if the unique identifier field name changes.
406-426: Consistent device links in trends tableSame “Device” matcher and link config here — consistent with the overview table.
547-552: Denser grid acceptedWidth 2 for Uptime makes sense to fit the expanded set of bars. Readability should remain fine.
649-651: CPU bar width reduction is fineLayout tightening acknowledged.
732-734: RAM bar width reduction is fine
813-815: Storage bar width reduction is fine
896-898: SD Card bar width reduction is fine
1232-1278: TCP Est. panel — sane defaultsQuery and thresholds look reasonable for a quick glance at connection load.
1314-1360: TCP Wait panel — OKClose-wait is a useful early indicator; thresholds are conservative but fine for examples.
1699-1699: Version bump notedDashboard version updated to 32.
9ed01d4 to
592b870
Compare
|
|
Data Agent v1.1 is released with the new data items collected, so I'm merging this now. |



TODO:
Summary by CodeRabbit
New Features
Bug Fixes
Style