grafana: the data-transferred-by-domain panel steps at 5 minutes and draws bars
Squid logs a tunnel's bytes once, when it closes, so a large download was one point in a small bucket and read as instantaneous. The panel now has a 5 minute minimum interval and bars, so that point is a visible bar. The module-eval check pins both.
This commit is contained in:
parent
ea407823c1
commit
b6af390581
2 changed files with 12 additions and 4 deletions
|
|
@ -1589,7 +1589,7 @@
|
|||
"spec": {
|
||||
"id": 21,
|
||||
"title": "Data transferred by domain over time",
|
||||
"description": "Bytes per top-10 domain, rest as other. A tunnel is logged at close, so long ones spike.",
|
||||
"description": "Bytes per top-10 domain, rest as other, in 5 minute bars. A tunnel counts when it closes.",
|
||||
"links": [],
|
||||
"data": {
|
||||
"kind": "QueryGroup",
|
||||
|
|
@ -1637,7 +1637,9 @@
|
|||
}
|
||||
],
|
||||
"transformations": [],
|
||||
"queryOptions": {}
|
||||
"queryOptions": {
|
||||
"interval": "5m"
|
||||
}
|
||||
}
|
||||
},
|
||||
"vizConfig": {
|
||||
|
|
@ -1663,9 +1665,9 @@
|
|||
"mode": "palette-classic"
|
||||
},
|
||||
"custom": {
|
||||
"drawStyle": "line",
|
||||
"drawStyle": "bars",
|
||||
"lineWidth": 1,
|
||||
"fillOpacity": 10,
|
||||
"fillOpacity": 60,
|
||||
"showPoints": "never",
|
||||
"spanNulls": false,
|
||||
"axisSoftMin": 0
|
||||
|
|
|
|||
|
|
@ -713,6 +713,12 @@ let
|
|||
&& (lib.head xf).spec.options.value == "__name__"
|
||||
&& (lib.head xf).spec.options.join != [ ]
|
||||
) (lib.filter (e: e.spec.vizConfig.group == "table") (lib.attrValues board.spec.elements))
|
||||
# Squid logs a tunnel's bytes once, when it closes, so a large download is
|
||||
# one point. The by-domain panel steps no finer than 5 minutes and draws
|
||||
# bars, so that point is a visible bar rather than a sliver.
|
||||
&& board.spec.elements."panel-21".spec.data.spec.queryOptions.interval == "5m"
|
||||
&&
|
||||
board.spec.elements."panel-21".spec.vizConfig.spec.fieldConfig.defaults.custom.drawStyle == "bars"
|
||||
&& lib.hasInfix "logformat would_deny would_deny user=%[un method=%rm host=%>rd port=%>rP result=" squid
|
||||
&& lib.hasInfix "access_log syslog:daemon.info squid !manager" squid;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue