335 lines
No EOL
9.9 KiB
JSON
335 lines
No EOL
9.9 KiB
JSON
{
|
|
"version": "3.0.0",
|
|
"description": "Data-driven template - panels fully describe their query logic",
|
|
"datasource": {
|
|
"type": "grafana-opensearch-datasource",
|
|
"uid": "af84zsvlp9blsa"
|
|
},
|
|
"dashboard_meta": {
|
|
"uid": "pt-af-requests-auto",
|
|
"tags": ["auto-generated", "waf-monitoring"],
|
|
"version": 0
|
|
},
|
|
"dashboard": {
|
|
"annotations": {
|
|
"list": [
|
|
{
|
|
"builtIn": 1,
|
|
"datasource": {"type": "grafana", "uid": "-- Grafana --"},
|
|
"enable": true,
|
|
"hide": true,
|
|
"iconColor": "rgba(0, 211, 255, 1)",
|
|
"name": "Annotations & Alerts",
|
|
"type": "dashboard"
|
|
}
|
|
]
|
|
},
|
|
"editable": true,
|
|
"fiscalYearStartMonth": 0,
|
|
"graphTooltip": 0,
|
|
"links": [],
|
|
"schemaVersion": 39,
|
|
"timezone": "browser",
|
|
"time": {"from": "now-6h", "to": "now"},
|
|
"timepicker": {},
|
|
"weekStart": ""
|
|
},
|
|
"layout": {
|
|
"use_collapsed_rows": true,
|
|
"tenant_panels": [
|
|
{
|
|
"panel_key": "rps",
|
|
"title_format": "RPS %s",
|
|
"width": 12,
|
|
"x_offset": 0,
|
|
"y_offset": 1
|
|
},
|
|
{
|
|
"panel_key": "status_codes",
|
|
"title_format": "Status Codes %s",
|
|
"width": 12,
|
|
"x_offset": 12,
|
|
"y_offset": 1
|
|
}
|
|
],
|
|
"domain_panels": [
|
|
{
|
|
"panel_key": "status_codes",
|
|
"title_suffix": "{sid} Status Codes",
|
|
"width": 12,
|
|
"x_offset": 0,
|
|
"y_offset": 9
|
|
},
|
|
{
|
|
"panel_key": "response_time",
|
|
"title_suffix": "{sid} Response Time",
|
|
"width": 12,
|
|
"x_offset": 12,
|
|
"y_offset": 9
|
|
},
|
|
{
|
|
"panel_key": "traffic_combined",
|
|
"title_suffix": "{sid} Traffic",
|
|
"width": 24,
|
|
"x_offset": 0,
|
|
"y_offset": 17
|
|
}
|
|
]
|
|
},
|
|
"panels": {
|
|
"row": {
|
|
"type": "row",
|
|
"collapsed": true,
|
|
"gridPos": {"h": 1, "w": 24, "x": 0, "y": 0},
|
|
"panels": []
|
|
},
|
|
|
|
"rps": {
|
|
"type": "timeseries",
|
|
"description": "Requests per second",
|
|
"gridPos": {"h": 8, "w": 12, "x": 0, "y": 1},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"},
|
|
"custom": {
|
|
"axisBorderShow": false,
|
|
"drawStyle": "line",
|
|
"fillOpacity": 10,
|
|
"gradientMode": "opacity",
|
|
"lineInterpolation": "smooth",
|
|
"lineWidth": 1,
|
|
"showPoints": "never",
|
|
"thresholdsStyle": {"mode": "line"}
|
|
},
|
|
"thresholds": {
|
|
"mode": "absolute",
|
|
"steps": [
|
|
{"color": "green", "value": null},
|
|
{"color": "dark-red", "value": 1800}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"options": {
|
|
"legend": {"displayMode": "list", "placement": "bottom", "showLegend": true},
|
|
"tooltip": {"mode": "single"}
|
|
},
|
|
"query_mode": "rps",
|
|
"query_config": {
|
|
"base_query": "SID:({sids})",
|
|
"metric": "count",
|
|
"alias": "{client_title} Total RPS",
|
|
"expression": "$A / 60",
|
|
"expression_ref_id": "RPS"
|
|
}
|
|
},
|
|
|
|
"status_codes": {
|
|
"type": "timeseries",
|
|
"description": "HTTP status codes",
|
|
"gridPos": {"h": 8, "w": 12, "x": 0, "y": 1},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"},
|
|
"custom": {
|
|
"drawStyle": "line",
|
|
"fillOpacity": 10,
|
|
"lineInterpolation": "smooth",
|
|
"lineWidth": 1,
|
|
"showPoints": "never"
|
|
}
|
|
},
|
|
"overrides": [
|
|
{"matcher": {"id": "byName", "options": "2**"}, "properties": [{"id": "color", "value": {"fixedColor": "green", "mode": "fixed"}}]},
|
|
{"matcher": {"id": "byName", "options": "3**"}, "properties": [{"id": "color", "value": {"fixedColor": "blue", "mode": "fixed"}}]},
|
|
{"matcher": {"id": "byName", "options": "4**"}, "properties": [{"id": "color", "value": {"fixedColor": "yellow", "mode": "fixed"}}]},
|
|
{"matcher": {"id": "byName", "options": "5**"}, "properties": [{"id": "color", "value": {"fixedColor": "red", "mode": "fixed"}}]}
|
|
]
|
|
},
|
|
"options": {
|
|
"legend": {"displayMode": "list", "placement": "bottom", "showLegend": true},
|
|
"tooltip": {"mode": "single"}
|
|
},
|
|
"query_mode": "multi_target",
|
|
"query_config": {
|
|
"base_query": "SID:{sid}",
|
|
"metric": "count",
|
|
"targets": [
|
|
{"alias": "2**", "query_suffix": "AND response_status_code:[200 TO 299]", "ref_id": "A"},
|
|
{"alias": "3**", "query_suffix": "AND response_status_code:[300 TO 399]", "ref_id": "B"},
|
|
{"alias": "4**", "query_suffix": "AND response_status_code:[400 TO 499]", "ref_id": "C"},
|
|
{"alias": "5**", "query_suffix": "AND response_status_code:[500 TO 599]", "ref_id": "D"}
|
|
]
|
|
}
|
|
},
|
|
|
|
"response_time": {
|
|
"type": "timeseries",
|
|
"description": "Response time distribution",
|
|
"gridPos": {"h": 8, "w": 12, "x": 12, "y": 1},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"},
|
|
"custom": {
|
|
"drawStyle": "line",
|
|
"fillOpacity": 30,
|
|
"lineWidth": 0,
|
|
"stacking": {"mode": "normal"}
|
|
},
|
|
"max": 100,
|
|
"min": 0,
|
|
"unit": "percent"
|
|
}
|
|
},
|
|
"options": {
|
|
"legend": {"displayMode": "list", "placement": "bottom", "showLegend": true},
|
|
"tooltip": {"mode": "single"}
|
|
},
|
|
"query_mode": "range_percent",
|
|
"query_config": {
|
|
"base_query": "SID:{sid}",
|
|
"field_filter": "upstream_response_time_digital:[0 TO *]",
|
|
"metric": "count",
|
|
"total_ref_id": "F",
|
|
"ranges": [
|
|
{"label": "0-0.3s", "from": "0", "to": "0.3", "ref_id": "A"},
|
|
{"label": "0.3-1s", "from": "0.3","to": "1", "ref_id": "B"},
|
|
{"label": "1-3s", "from": "1", "to": "3", "ref_id": "C"},
|
|
{"label": "3-10s", "from": "3", "to": "10", "ref_id": "D"},
|
|
{"label": "10s+", "from": "10", "to": "*", "ref_id": "E"}
|
|
],
|
|
"range_field": "upstream_response_time_digital"
|
|
}
|
|
},
|
|
|
|
"traffic_combined": {
|
|
"type": "timeseries",
|
|
"description": "Response and Request Traffic",
|
|
"gridPos": {"h": 8, "w": 24, "x": 0, "y": 17},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"},
|
|
"custom": {
|
|
"drawStyle": "line",
|
|
"fillOpacity": 10,
|
|
"lineInterpolation": "smooth",
|
|
"lineWidth": 1,
|
|
"showPoints": "never",
|
|
"spanNulls": 180000
|
|
},
|
|
"unit": "Kbits"
|
|
},
|
|
"overrides": [
|
|
{
|
|
"matcher": {"id": "byRegexp", "options": "/.*Response.*/"},
|
|
"properties": [
|
|
{"id": "color", "value": {"fixedColor": "green", "mode": "fixed"}}
|
|
]
|
|
},
|
|
{
|
|
"matcher": {"id": "byRegexp", "options": "/.*Request.*/"},
|
|
"properties": [
|
|
{"id": "color", "value": {"fixedColor": "blue", "mode": "fixed"}}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"options": {
|
|
"legend": {"displayMode": "list", "placement": "bottom", "showLegend": true},
|
|
"tooltip": {"mode": "single"}
|
|
},
|
|
"query_mode": "multi_sum_expression",
|
|
"query_config": {
|
|
"base_query": "SID:{sid}",
|
|
"targets": [
|
|
{
|
|
"alias": "Response Traffic",
|
|
"metric": "sum",
|
|
"field": "upstream_response_length_digital",
|
|
"ref_id": "A",
|
|
"expression": "$A / 60",
|
|
"expression_ref_id": "ResponseTraffic"
|
|
},
|
|
{
|
|
"alias": "Request Traffic",
|
|
"metric": "sum",
|
|
"field": "upstream_bytes_sent_digital",
|
|
"ref_id": "B",
|
|
"expression": "$B / 60",
|
|
"expression_ref_id": "RequestTraffic"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
|
|
"traffic": {
|
|
"type": "timeseries",
|
|
"description": "Traffic",
|
|
"gridPos": {"h": 8, "w": 12, "x": 0, "y": 9},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"},
|
|
"custom": {
|
|
"drawStyle": "line",
|
|
"fillOpacity": 10,
|
|
"lineInterpolation": "smooth",
|
|
"lineWidth": 1,
|
|
"showPoints": "never",
|
|
"spanNulls": 180000
|
|
},
|
|
"unit": "Kbits"
|
|
}
|
|
},
|
|
"query_mode": "sum_expression",
|
|
"query_config": {
|
|
"base_query": "SID:{sid}",
|
|
"metric": "sum",
|
|
"field": "upstream_response_length_digital",
|
|
"ref_id": "A",
|
|
"expression": "($A / 60)",
|
|
"expression_ref_id": "Traffic"
|
|
}
|
|
},
|
|
|
|
"status_codes_barchart": {
|
|
"type": "barchart",
|
|
"description": "Status codes distribution",
|
|
"gridPos": {"h": 8, "w": 12, "x": 0, "y": 9},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {"mode": "palette-classic"}
|
|
}
|
|
},
|
|
"options": {
|
|
"legend": {"displayMode": "list", "placement": "bottom", "showLegend": true}
|
|
},
|
|
"query_mode": "bucket_logs",
|
|
"query_config": {
|
|
"base_query": "log_type:access AND SID:{sid}",
|
|
"metric": "count",
|
|
"bucket_aggs": [
|
|
{
|
|
"field": "response_status_code",
|
|
"id": "3",
|
|
"settings": {"min_doc_count": "1", "order": "desc", "orderBy": "_count", "size": "10"},
|
|
"type": "terms"
|
|
},
|
|
{
|
|
"field": "@timestamp",
|
|
"id": "2",
|
|
"settings": {"interval": "1m", "trimEdges": "1"},
|
|
"type": "date_histogram"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"queries": {
|
|
"bucket_agg": {
|
|
"field": "@timestamp",
|
|
"id": "2",
|
|
"settings": {"interval": "1m", "trimEdges": "1"},
|
|
"type": "date_histogram"
|
|
}
|
|
}
|
|
} |