From aa6b7bbbf7cf4c36e5c011f333904e6a8effac1c Mon Sep 17 00:00:00 2001 From: Yun-Tang Hsu Date: Mon, 25 Jul 2022 15:55:19 -0700 Subject: [PATCH] Grafana UI improvements 1. Map FlowEndReason value from int to string 2. Add user-friendly names for columns used in tables 3. Remove mean value in throughput related table 4. Add a threshold for time-series diagram to prevent points from connecting when the gap of time is > 90s Signed-off-by: Yun-Tang Hsu --- .../dashboards/flow_records_dashboard.json | 162 +- .../dashboards/networkpolicy_dashboard.json | 1228 ++++---- .../dashboards/node_to_node_dashboard.json | 108 +- .../dashboards/pod_to_external_dashboard.json | 654 ++-- .../dashboards/pod_to_pod_dashboard.json | 118 +- .../dashboards/pod_to_service_dashboard.json | 110 +- build/yamls/flow-visibility.yml | 2736 +++++++++-------- docs/getting-started.md | 2 +- docs/network-flow-visibility.md | 26 +- 9 files changed, 2638 insertions(+), 2506 deletions(-) diff --git a/build/charts/theia/provisioning/dashboards/flow_records_dashboard.json b/build/charts/theia/provisioning/dashboards/flow_records_dashboard.json index 2ae948093..38254105c 100644 --- a/build/charts/theia/provisioning/dashboards/flow_records_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/flow_records_dashboard.json @@ -21,8 +21,8 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": 1, - "iteration": 1652994218341, + "id": 4, + "iteration": 1659392847247, "links": [], "liveNow": false, "panels": [ @@ -74,21 +74,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT count(*) as count\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT count(*) as count\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)", + "refId": "A" } ], "title": "Flow Records Count", @@ -174,21 +174,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT count() as count, $__timeInterval(flowEndSeconds) as time\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nGROUP BY time\nORDER BY time", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT count() as count, $__timeInterval(flowEndSeconds) as time\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nGROUP BY time\nORDER BY time", + "refId": "A" } ], "title": "Flow Records Count", @@ -560,6 +560,10 @@ { "id": "custom.width", "value": 230 + }, + { + "id": "displayName", + "value": "throughput reported by source" } ] }, @@ -571,7 +575,11 @@ "properties": [ { "id": "custom.width", - "value": 251 + "value": 260 + }, + { + "id": "displayName", + "value": "throughput reported by destination" } ] }, @@ -583,7 +591,11 @@ "properties": [ { "id": "custom.width", - "value": 273 + "value": 280 + }, + { + "id": "displayName", + "value": "reverse throughput reported by source" } ] }, @@ -595,7 +607,11 @@ "properties": [ { "id": "custom.width", - "value": 299 + "value": 310 + }, + { + "id": "displayName", + "value": "reverse throughput reported by destination" } ] }, @@ -655,7 +671,11 @@ "properties": [ { "id": "custom.width", - "value": 283 + "value": 290 + }, + { + "id": "displayName", + "value": "end time of flow reported by destination" } ] }, @@ -667,7 +687,11 @@ "properties": [ { "id": "custom.width", - "value": 255 + "value": 260 + }, + { + "id": "displayName", + "value": "end time of flow reported by source" } ] }, @@ -792,6 +816,10 @@ { "id": "custom.width", "value": 185 + }, + { + "id": "displayName", + "value": "end time of flow" } ] }, @@ -803,7 +831,11 @@ "properties": [ { "id": "custom.width", - "value": 184 + "value": 185 + }, + { + "id": "displayName", + "value": "start time of flow" } ] }, @@ -815,7 +847,77 @@ "properties": [ { "id": "custom.width", - "value": 181 + "value": 187 + }, + { + "id": "displayName", + "value": "insert time of flow" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "flowEndReason" + }, + "properties": [ + { + "id": "mappings", + "value": [ + { + "options": { + "1": { + "index": 0, + "text": "Idle Timeout" + }, + "2": { + "index": 1, + "text": "Active Timeout" + }, + "3": { + "index": 2, + "text": "End Of Flow" + } + }, + "type": "value" + } + ] + }, + { + "id": "custom.width", + "value": 142 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "octetDeltaCount" + }, + "properties": [ + { + "id": "displayName", + "value": "delta bytes from the last record" + }, + { + "id": "custom.width", + "value": 235 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "packetDeltaCount" + }, + "properties": [ + { + "id": "custom.width", + "value": 250 + }, + { + "id": "displayName", + "value": "delta packets from the last record" } ] } @@ -842,14 +944,14 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT * \nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nORDER BY flowEndSeconds DESC\nLIMIT 10000", - "format": 1 + "refId": "A" } ], "title": "Flow Records Table", @@ -899,4 +1001,4 @@ "uid": "t1UGX7t7k", "version": 2, "weekStart": "" -} +} \ No newline at end of file diff --git a/build/charts/theia/provisioning/dashboards/networkpolicy_dashboard.json b/build/charts/theia/provisioning/dashboards/networkpolicy_dashboard.json index 8d081620f..7fa4a6c28 100644 --- a/build/charts/theia/provisioning/dashboards/networkpolicy_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/networkpolicy_dashboard.json @@ -1,647 +1,639 @@ { - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 2, + "iteration": 1659133512870, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 20, + "w": 15, + "x": 0, + "y": 0 + }, + "id": 2, + "interval": "1s", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" } - ] + }, + "queryType": "sql", + "rawSql": "SELECT CONCAT(sourcePodNamespace, '/', sourcePodName) as srcPod,\nCONCAT(destinationPodNamespace, '/', destinationPodName) as dstPod,\nsourceTransportPort as srcPort,\ndestinationTransportPort as dstPort,\ndestinationServicePort as dstSvcPort,\ndestinationServicePortName as dstSvc,\ndestinationIP as dstIP,\nSUM(octetDeltaCount) as bytes,\nSUM(reverseOctetDeltaCount) as revBytes,\negressNetworkPolicyName,\negressNetworkPolicyRuleAction,\ningressNetworkPolicyName,\ningressNetworkPolicyRuleAction\nfrom flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND $__timeFilter(flowEndSeconds)\nGROUP BY srcPod, dstPod, srcPort, dstPort, dstSvcPort, dstSvc, dstIP, egressNetworkPolicyName, egressNetworkPolicyRuleAction, ingressNetworkPolicyName, ingressNetworkPolicyRuleAction\nHAVING bytes > 0\norder by bytes DESC\n", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Flows with NetworkPolicy Information", + "transparent": true, + "type": "theia-grafana-chord-plugin" }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 2, - "iteration": 1657746484227, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 20, - "w": 15, - "x": 0, - "y": 0 - }, - "id": 2, - "interval": "1s", - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT CONCAT(sourcePodNamespace, '/', sourcePodName) as srcPod,\nCONCAT(destinationPodNamespace, '/', destinationPodName) as dstPod,\nsourceTransportPort as srcPort,\ndestinationTransportPort as dstPort,\ndestinationServicePort as dstSvcPort,\ndestinationServicePortName as dstSvc,\ndestinationIP as dstIP,\nSUM(octetDeltaCount) as bytes,\nSUM(reverseOctetDeltaCount) as revBytes,\negressNetworkPolicyName,\negressNetworkPolicyRuleAction,\ningressNetworkPolicyName,\ningressNetworkPolicyRuleAction\nfrom flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND $__timeFilter(flowEndSeconds)\nGROUP BY srcPod, dstPod, srcPort, dstPort, dstSvcPort, dstSvc, dstIP, egressNetworkPolicyName, egressNetworkPolicyRuleAction, ingressNetworkPolicyName, ingressNetworkPolicyRuleAction\nHAVING bytes > 0\norder by bytes DESC\n", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Flows with NetworkPolicy Information", - "transparent": true, - "type": "theia-grafana-chord-plugin" + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "decbytes" }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 0 - }, - "id": 10, - "options": { - "legend": { - "displayMode": "table", - "placement": "bottom", - "values": [ - "percent", - "value" - ] - }, - "pieType": "donut", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "limit": 25, - "values": true - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 1, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace, '/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) != 0\nORDER BY bytes DESC", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Ingress Network Policy", - "transparent": true, - "type": "piechart" + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 8, + "x": 16, + "y": 0 + }, + "id": 10, + "options": { + "legend": { + "displayMode": "table", + "placement": "bottom", + "values": [ + "percent", + "value" + ] + }, + "pieType": "donut", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "limit": 25, + "values": true }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 10 - }, - "id": 9, - "options": { - "displayLabels": [], - "legend": { - "displayMode": "table", - "placement": "bottom", - "values": [ - "percent", - "value" - ] - }, - "pieType": "donut", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "limit": 25, - "values": true - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 1, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace, '/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY bytes DESC", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Egress Network Policy", - "transparent": true, - "type": "piechart" + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace, '/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) != 0\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Ingress Network Policy", + "transparent": true, + "type": "piechart" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "decbytes" }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 8, + "x": 16, + "y": 10 + }, + "id": 9, + "options": { + "displayLabels": [], + "legend": { + "displayMode": "table", + "placement": "bottom", + "values": [ + "percent", + "value" + ] + }, + "pieType": "donut", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "limit": 25, + "values": true + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace, '/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Egress Network Policy", + "transparent": true, + "type": "piechart" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 20 + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 4, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND AS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction == 1\nAND egressNetworkPolicyRuleAction NOT IN (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Ingress Allow NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 20 + }, + "id": 4, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND AS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction == 1\nAND egressNetworkPolicyRuleAction NOT IN (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\n", + "refId": "A" + } + ], + "title": "Throughput of Ingress Allow NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 20 + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 5, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction == 1\nAND ingressNetworkPolicyRuleAction not in (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Egress Allow NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 20 + }, + "id": 5, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction == 1\nAND ingressNetworkPolicyRuleAction not in (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Egress Allow NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 28 + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 6, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "expand": false, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Ingress Deny NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 28 + }, + "id": 6, + "interval": "1s", + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "expand": false, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Ingress Deny NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 28 + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 7, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Egress Deny NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 28 + }, + "id": 7, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" } - ], - "refresh": "", - "schemaVersion": 34, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "filters": [], - "hide": 0, - "name": "Filter", - "skipUrlSync": false, - "type": "adhoc" - }, - { - "hide": 2, - "name": "clickhouse_adhoc_query", - "query": "default.flows_policy_view", - "skipUrlSync": false, - "type": "constant" + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "networkpolicy_dashboard", - "uid": "KJNMOwQnk", - "version": 5, - "weekStart": "" + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Egress Deny NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + } + ], + "refresh": "", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "filters": [], + "hide": 0, + "name": "Filter", + "skipUrlSync": false, + "type": "adhoc" + }, + { + "hide": 2, + "name": "clickhouse_adhoc_query", + "query": "default.flows_policy_view", + "skipUrlSync": false, + "type": "constant" + } + ] + }, + "time": { + "from": "now-30m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "networkpolicy_dashboard", + "uid": "KJNMOwQnk", + "version": 2, + "weekStart": "" } diff --git a/build/charts/theia/provisioning/dashboards/node_to_node_dashboard.json b/build/charts/theia/provisioning/dashboards/node_to_node_dashboard.json index b02fa0a67..acbdc48a1 100644 --- a/build/charts/theia/provisioning/dashboards/node_to_node_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/node_to_node_dashboard.json @@ -22,7 +22,7 @@ "fiscalYearStartMonth": 0, "graphTooltip": 0, "id": 3, - "iteration": 1653419912594, + "iteration": 1659133528716, "links": [], "liveNow": false, "panels": [ @@ -47,14 +47,14 @@ "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes of Node-to-Node", @@ -88,14 +88,14 @@ "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Reverse Bytes of Node-to-Node", @@ -131,7 +131,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -168,9 +168,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -181,21 +179,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(throughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(throughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Node-to-Node", @@ -250,7 +248,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -287,9 +285,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -300,21 +296,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(reverseThroughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(reverseThroughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time", + "refId": "A" } ], "title": "Reverse Throughput of Node-to-Node", @@ -369,7 +365,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -406,9 +402,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -419,21 +413,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time, sourceNodeName, SUM(throughputFromSourceNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' \nAND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, sourceNodeName\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time, sourceNodeName, SUM(throughputFromSourceNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' \nAND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, sourceNodeName\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Node as Source", @@ -556,7 +550,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -593,9 +587,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -606,21 +598,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time, destinationNodeName, SUM(throughputFromDestinationNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, destinationNodeName\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time, destinationNodeName, SUM(throughputFromDestinationNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, destinationNodeName\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Node as Destination", @@ -747,6 +739,6 @@ "timezone": "", "title": "node_to_node_dashboard", "uid": "1F56RJh7z", - "version": 5, + "version": 2, "weekStart": "" } diff --git a/build/charts/theia/provisioning/dashboards/pod_to_external_dashboard.json b/build/charts/theia/provisioning/dashboards/pod_to_external_dashboard.json index 2fbe3ba91..1aec85331 100644 --- a/build/charts/theia/provisioning/dashboards/pod_to_external_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/pod_to_external_dashboard.json @@ -1,345 +1,341 @@ { - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 1, - "iteration": 1655845123241, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 18, - "w": 12, - "x": 0, - "y": 0 - }, - "id": 13, - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 - } - ], - "title": "Cumulative Bytes of Pod-to-External", - "transparent": true, - "type": "theia-grafana-sankey-plugin" + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 4, + "iteration": 1659133592592, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 0, + "y": 0 + }, + "id": 13, + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 18, - "w": 12, - "x": 12, - "y": 0 - }, - "id": 12, - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 - } - ], - "title": "Cumulative Reverse Bytes of Pod-to-External", - "transparent": true, - "type": "theia-grafana-sankey-plugin" - }, + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Pod-to-External", + "transparent": true, + "type": "theia-grafana-sankey-plugin" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 12, + "y": 0 + }, + "id": 12, + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", + "refId": "A" + } + ], + "title": "Cumulative Reverse Bytes of Pod-to-External", + "transparent": true, + "type": "theia-grafana-sankey-plugin" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] + "lineInterpolation": "linear", + "lineStyle": { + "fill": "solid" }, - "gridPos": { - "h": 10, - "w": 12, - "x": 0, - "y": 18 + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 2, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "right" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "pluginVersion": "8.3.3", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "meta": { - "builderOptions": { - "mode": "list", - "fields": [], - "limit": 100 - } - }, - "format": 2 - } - ], - "title": "Throughput of Pod-to-External", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 12, + "x": 0, + "y": 18 + }, + "id": 2, + "interval": "1s", + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "right" + }, + "tooltip": { + "mode": "single" + } + }, + "pluginVersion": "8.3.3", + "targets": [ { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Pod-to-External", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false }, - "gridPos": { - "h": 10, - "w": 12, - "x": 12, - "y": 18 + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" }, - "id": 7, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "right" - }, - "tooltip": { - "mode": "single" - } + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" }, - "pluginVersion": "8.3.3", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", - "meta": { - "builderOptions": { - "mode": "list", - "fields": [], - "limit": 100 - } - }, - "format": 2 - } - ], - "title": "Reverse Throughput of Pod-to-External", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "decbytes" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 12, + "x": 12, + "y": 18 + }, + "id": 7, + "interval": "1s", + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "right" + }, + "tooltip": { + "mode": "single" } - ], - "refresh": "", - "schemaVersion": 34, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "filters": [], - "hide": 0, - "name": "Filter", - "skipUrlSync": false, - "type": "adhoc" - }, - { - "hide": 2, - "name": "clickhouse_adhoc_query", - "query": "default.flows_pod_view", - "skipUrlSync": false, - "type": "constant" + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "pod_to_external_dashboard", - "uid": "K9SPrnJ7k", - "version": 12, - "weekStart": "" + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Reverse Throughput of Pod-to-External", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + } + ], + "refresh": "", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "filters": [], + "hide": 0, + "name": "Filter", + "skipUrlSync": false, + "type": "adhoc" + }, + { + "hide": 2, + "name": "clickhouse_adhoc_query", + "query": "default.flows_pod_view", + "skipUrlSync": false, + "type": "constant" + } + ] + }, + "time": { + "from": "now-30m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "pod_to_external_dashboard", + "uid": "K9SPrnJ7k", + "version": 2, + "weekStart": "" } diff --git a/build/charts/theia/provisioning/dashboards/pod_to_pod_dashboard.json b/build/charts/theia/provisioning/dashboards/pod_to_pod_dashboard.json index 151bffdf4..94e17786c 100644 --- a/build/charts/theia/provisioning/dashboards/pod_to_pod_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/pod_to_pod_dashboard.json @@ -22,7 +22,7 @@ "fiscalYearStartMonth": 0, "graphTooltip": 0, "id": 5, - "iteration": 1655847050224, + "iteration": 1659133662707, "links": [], "liveNow": false, "panels": [ @@ -46,14 +46,14 @@ "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes of Pod-to-Pod", @@ -80,14 +80,14 @@ "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Reverse Bytes of Pod-to-Pod", @@ -123,7 +123,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -156,9 +156,7 @@ "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -169,21 +167,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod-to-Pod", @@ -227,7 +225,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -264,9 +262,7 @@ "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -277,21 +273,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Reverse Throughput of Pod-to-Pod", @@ -335,7 +331,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -368,9 +364,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -381,21 +375,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Source", @@ -467,10 +461,10 @@ "type": "grafana-clickhouse-datasource", "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourcePodNamespace\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY sourcePodNamespace\nHAVING bytes > 0\nORDER BY bytes DESC", - "refId": "A", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes of Source Pod Namespace", @@ -506,7 +500,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -543,9 +537,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -556,21 +548,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Destination", @@ -655,14 +647,14 @@ "type": "grafana-clickhouse-datasource", "uid": "PDEE91DDB90597936" }, + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2, "rawSql": "SELECT SUM(octetDeltaCount) as bytes, destinationPodNamespace\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY destinationPodNamespace\nORDER BY bytes DESC", "refId": "A" } @@ -706,6 +698,6 @@ "timezone": "", "title": "pod_to_pod_dashboard", "uid": "Yxn0Ghh7k", - "version": 2, + "version": 3, "weekStart": "" } diff --git a/build/charts/theia/provisioning/dashboards/pod_to_service_dashboard.json b/build/charts/theia/provisioning/dashboards/pod_to_service_dashboard.json index 32a4f4fb8..0f7a48561 100644 --- a/build/charts/theia/provisioning/dashboards/pod_to_service_dashboard.json +++ b/build/charts/theia/provisioning/dashboards/pod_to_service_dashboard.json @@ -21,8 +21,8 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": 3, - "iteration": 1655844589249, + "id": 6, + "iteration": 1659133715817, "links": [], "liveNow": false, "panels": [ @@ -46,14 +46,14 @@ "pluginVersion": "7.5. 2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes Pod-to-Service", @@ -80,14 +80,14 @@ "pluginVersion": "7.5. 2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Reverse Bytes Pod-to-Service", @@ -123,7 +123,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -160,9 +160,7 @@ "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -173,21 +171,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod-to-Service", @@ -231,7 +229,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -268,9 +266,7 @@ "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -281,21 +277,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Reverse Throughput of Pod-to-Service", @@ -339,7 +335,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -376,9 +372,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -389,21 +383,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Source", @@ -447,7 +441,7 @@ "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -484,9 +478,7 @@ "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -497,21 +489,21 @@ "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Service as Destination", @@ -561,6 +553,6 @@ "timezone": "", "title": "pod_to_service_dashboard", "uid": "LGdxbW17z", - "version": 10, + "version": 2, "weekStart": "" } diff --git a/build/yamls/flow-visibility.yml b/build/yamls/flow-visibility.yml index 208cb9096..1fa251273 100644 --- a/build/yamls/flow-visibility.yml +++ b/build/yamls/flow-visibility.yml @@ -319,7 +319,7 @@ metadata: --- apiVersion: v1 data: - flow_records_dashboard.json: | + flow_records_dashboard.json: |- { "annotations": { "list": [ @@ -343,8 +343,8 @@ data: "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": 1, - "iteration": 1652994218341, + "id": 4, + "iteration": 1659392847247, "links": [], "liveNow": false, "panels": [ @@ -396,21 +396,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT count(*) as count\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT count(*) as count\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)", + "refId": "A" } ], "title": "Flow Records Count", @@ -496,21 +496,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT count() as count, $__timeInterval(flowEndSeconds) as time\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nGROUP BY time\nORDER BY time", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT count() as count, $__timeInterval(flowEndSeconds) as time\nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nGROUP BY time\nORDER BY time", + "refId": "A" } ], "title": "Flow Records Count", @@ -882,6 +882,10 @@ data: { "id": "custom.width", "value": 230 + }, + { + "id": "displayName", + "value": "throughput reported by source" } ] }, @@ -893,7 +897,11 @@ data: "properties": [ { "id": "custom.width", - "value": 251 + "value": 260 + }, + { + "id": "displayName", + "value": "throughput reported by destination" } ] }, @@ -905,7 +913,11 @@ data: "properties": [ { "id": "custom.width", - "value": 273 + "value": 280 + }, + { + "id": "displayName", + "value": "reverse throughput reported by source" } ] }, @@ -917,7 +929,11 @@ data: "properties": [ { "id": "custom.width", - "value": 299 + "value": 310 + }, + { + "id": "displayName", + "value": "reverse throughput reported by destination" } ] }, @@ -977,7 +993,11 @@ data: "properties": [ { "id": "custom.width", - "value": 283 + "value": 290 + }, + { + "id": "displayName", + "value": "end time of flow reported by destination" } ] }, @@ -989,7 +1009,11 @@ data: "properties": [ { "id": "custom.width", - "value": 255 + "value": 260 + }, + { + "id": "displayName", + "value": "end time of flow reported by source" } ] }, @@ -1114,6 +1138,10 @@ data: { "id": "custom.width", "value": 185 + }, + { + "id": "displayName", + "value": "end time of flow" } ] }, @@ -1125,7 +1153,11 @@ data: "properties": [ { "id": "custom.width", - "value": 184 + "value": 185 + }, + { + "id": "displayName", + "value": "start time of flow" } ] }, @@ -1137,7 +1169,77 @@ data: "properties": [ { "id": "custom.width", - "value": 181 + "value": 187 + }, + { + "id": "displayName", + "value": "insert time of flow" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "flowEndReason" + }, + "properties": [ + { + "id": "mappings", + "value": [ + { + "options": { + "1": { + "index": 0, + "text": "Idle Timeout" + }, + "2": { + "index": 1, + "text": "Active Timeout" + }, + "3": { + "index": 2, + "text": "End Of Flow" + } + }, + "type": "value" + } + ] + }, + { + "id": "custom.width", + "value": 142 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "octetDeltaCount" + }, + "properties": [ + { + "id": "displayName", + "value": "delta bytes from the last record" + }, + { + "id": "custom.width", + "value": 235 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "packetDeltaCount" + }, + "properties": [ + { + "id": "custom.width", + "value": 250 + }, + { + "id": "displayName", + "value": "delta packets from the last record" } ] } @@ -1164,14 +1266,14 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT * \nFROM flows\nWHERE $__timeFilter(flowEndSeconds)\nORDER BY flowEndSeconds DESC\nLIMIT 10000", - "format": 1 + "refId": "A" } ], "title": "Flow Records Table", @@ -1223,654 +1325,6 @@ data: "weekStart": "" } networkpolicy_dashboard.json: | - { - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 2, - "iteration": 1657746484227, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 20, - "w": 15, - "x": 0, - "y": 0 - }, - "id": 2, - "interval": "1s", - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT CONCAT(sourcePodNamespace, '/', sourcePodName) as srcPod,\nCONCAT(destinationPodNamespace, '/', destinationPodName) as dstPod,\nsourceTransportPort as srcPort,\ndestinationTransportPort as dstPort,\ndestinationServicePort as dstSvcPort,\ndestinationServicePortName as dstSvc,\ndestinationIP as dstIP,\nSUM(octetDeltaCount) as bytes,\nSUM(reverseOctetDeltaCount) as revBytes,\negressNetworkPolicyName,\negressNetworkPolicyRuleAction,\ningressNetworkPolicyName,\ningressNetworkPolicyRuleAction\nfrom flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND $__timeFilter(flowEndSeconds)\nGROUP BY srcPod, dstPod, srcPort, dstPort, dstSvcPort, dstSvc, dstIP, egressNetworkPolicyName, egressNetworkPolicyRuleAction, ingressNetworkPolicyName, ingressNetworkPolicyRuleAction\nHAVING bytes > 0\norder by bytes DESC\n", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Flows with NetworkPolicy Information", - "transparent": true, - "type": "theia-grafana-chord-plugin" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 0 - }, - "id": 10, - "options": { - "legend": { - "displayMode": "table", - "placement": "bottom", - "values": [ - "percent", - "value" - ] - }, - "pieType": "donut", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "limit": 25, - "values": true - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 1, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace, '/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) != 0\nORDER BY bytes DESC", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Ingress Network Policy", - "transparent": true, - "type": "piechart" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 10 - }, - "id": 9, - "options": { - "displayLabels": [], - "legend": { - "displayMode": "table", - "placement": "bottom", - "values": [ - "percent", - "value" - ] - }, - "pieType": "donut", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "limit": 25, - "values": true - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 1, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace, '/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY bytes DESC", - "refId": "A" - } - ], - "title": "Cumulative Bytes of Egress Network Policy", - "transparent": true, - "type": "piechart" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 20 - }, - "id": 4, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND AS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction == 1\nAND egressNetworkPolicyRuleAction NOT IN (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Ingress Allow NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 20 - }, - "id": 5, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction == 1\nAND ingressNetworkPolicyRuleAction not in (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Egress Allow NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 28 - }, - "id": 6, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "expand": false, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Ingress Deny NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 28 - }, - "id": 7, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single" - } - }, - "targets": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "format": 2, - "meta": { - "builderOptions": { - "fields": [], - "limit": 100, - "mode": "list" - } - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time\nLIMIT 50", - "refId": "A" - } - ], - "title": "Throughput of Egress Deny NetworkPolicy", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - } - ], - "refresh": "", - "schemaVersion": 34, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "filters": [], - "hide": 0, - "name": "Filter", - "skipUrlSync": false, - "type": "adhoc" - }, - { - "hide": 2, - "name": "clickhouse_adhoc_query", - "query": "default.flows_policy_view", - "skipUrlSync": false, - "type": "constant" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "networkpolicy_dashboard", - "uid": "KJNMOwQnk", - "version": 5, - "weekStart": "" - } - node_to_node_dashboard.json: | { "annotations": { "list": [ @@ -1894,8 +1348,8 @@ data: "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": 3, - "iteration": 1653419912594, + "id": 2, + "iteration": 1659133512870, "links": [], "liveNow": false, "panels": [ @@ -1905,75 +1359,35 @@ data: "uid": "PDEE91DDB90597936" }, "gridPos": { - "h": 18, - "w": 12, + "h": 20, + "w": 15, "x": 0, "y": 0 }, - "id": 11, - "interval": "60", - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", + "id": 2, + "interval": "1s", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 - } - ], - "title": "Cumulative Bytes of Node-to-Node", - "transformations": [ - { - "id": "labelsToFields", - "options": {} - } - ], - "transparent": true, - "type": "theia-grafana-sankey-plugin" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 18, - "w": 12, - "x": 12, - "y": 0 - }, - "id": 14, - "interval": "60s", - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } }, "queryType": "sql", - "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "rawSql": "SELECT CONCAT(sourcePodNamespace, '/', sourcePodName) as srcPod,\nCONCAT(destinationPodNamespace, '/', destinationPodName) as dstPod,\nsourceTransportPort as srcPort,\ndestinationTransportPort as dstPort,\ndestinationServicePort as dstSvcPort,\ndestinationServicePortName as dstSvc,\ndestinationIP as dstIP,\nSUM(octetDeltaCount) as bytes,\nSUM(reverseOctetDeltaCount) as revBytes,\negressNetworkPolicyName,\negressNetworkPolicyRuleAction,\ningressNetworkPolicyName,\ningressNetworkPolicyRuleAction\nfrom flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\n AND $__timeFilter(flowEndSeconds)\nGROUP BY srcPod, dstPod, srcPort, dstPort, dstSvcPort, dstSvc, dstIP, egressNetworkPolicyName, egressNetworkPolicyRuleAction, ingressNetworkPolicyName, ingressNetworkPolicyRuleAction\nHAVING bytes > 0\norder by bytes DESC\n", + "refId": "A" } ], - "title": "Cumulative Reverse Bytes of Node-to-Node", + "title": "Cumulative Bytes of Flows with NetworkPolicy Information", "transparent": true, - "type": "theia-grafana-sankey-plugin" + "type": "theia-grafana-chord-plugin" }, { "datasource": { @@ -1986,31 +1400,711 @@ data: "mode": "palette-classic" }, "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", "hideFrom": { "legend": false, "tooltip": false, "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" + } + }, + "mappings": [], + "unit": "decbytes" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 8, + "x": 16, + "y": 0 + }, + "id": 10, + "options": { + "legend": { + "displayMode": "table", + "placement": "bottom", + "values": [ + "percent", + "value" + ] + }, + "pieType": "donut", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "limit": 25, + "values": true + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace, '/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) != 0\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Ingress Network Policy", + "transparent": true, + "type": "piechart" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "decbytes" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 8, + "x": 16, + "y": 10 + }, + "id": 9, + "options": { + "displayLabels": [], + "legend": { + "displayMode": "table", + "placement": "bottom", + "values": [ + "percent", + "value" + ] + }, + "pieType": "donut", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "limit": 25, + "values": true + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace, '/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND AS np\nFROM flows_policy_view\nWHERE sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Egress Network Policy", + "transparent": true, + "type": "piechart" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 20 + }, + "id": 4, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND AS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND AS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction == 1\nAND egressNetworkPolicyRuleAction NOT IN (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time\n", + "refId": "A" + } + ], + "title": "Throughput of Ingress Allow NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 20 + }, + "id": 5, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction == 1\nAND ingressNetworkPolicyRuleAction not in (2, 3)\nGROUP BY time, src, dst, np\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Egress Allow NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 28 + }, + "id": 6, + "interval": "1s", + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "expand": false, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN ingressNetworkPolicyNamespace != '' THEN CONCAT(ingressNetworkPolicyNamespace,'/', ingressNetworkPolicyName)\nELSE ingressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND ingressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Ingress Deny NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 28 + }, + "id": 7, + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCASE WHEN sourceTransportPort != 0 THEN CONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR))\nELSE CONCAT(sourcePodNamespace, '/', sourcePodName)\nEND AS src,\nCASE WHEN destinationServicePortName != '' AND destinationServicePort != 0 THEN CONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR))\nWHEN destinationServicePortName != '' AND destinationServicePort == 0 THEN destinationServicePortName\nWHEN destinationPodName != '' AND destinationTransportPort != 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR))\nWHEN destinationPodName != '' AND destinationTransportPort == 0 THEN CONCAT(destinationPodNamespace,'/', destinationPodName)\nELSE destinationIP\nEND\nAS dst,\nCASE WHEN egressNetworkPolicyNamespace != '' THEN CONCAT(egressNetworkPolicyNamespace,'/', egressNetworkPolicyName)\nELSE egressNetworkPolicyName\nEND\nAS np,\nCONCAT(src, ' -> ', dst, ' : ', np) as pair,\nAVG(throughput)\nFROM flows_policy_view\nWHERE $__timeFilter(flowEndSeconds)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND egressNetworkPolicyRuleAction in (2,3)\nGROUP BY time, src, dst, np\nHAVING SUM(octetDeltaCount) > 0\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Egress Deny NetworkPolicy", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + } + ], + "refresh": "", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "filters": [], + "hide": 0, + "name": "Filter", + "skipUrlSync": false, + "type": "adhoc" + }, + { + "hide": 2, + "name": "clickhouse_adhoc_query", + "query": "default.flows_policy_view", + "skipUrlSync": false, + "type": "constant" + } + ] + }, + "time": { + "from": "now-30m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "networkpolicy_dashboard", + "uid": "KJNMOwQnk", + "version": 2, + "weekStart": "" + } + node_to_node_dashboard.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 3, + "iteration": 1659133528716, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 0, + "y": 0 + }, + "id": 11, + "interval": "60", + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Node-to-Node", + "transformations": [ + { + "id": "labelsToFields", + "options": {} + } + ], + "transparent": true, + "type": "theia-grafana-sankey-plugin" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 12, + "y": 0 + }, + "id": 14, + "interval": "60s", + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes, sourceNodeName as source, destinationNodeName as destination\nFrom flows_node_view\nWHERE source != '' AND destination != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", + "refId": "A" + } + ], + "title": "Cumulative Reverse Bytes of Node-to-Node", + "transparent": true, + "type": "theia-grafana-sankey-plugin" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" } }, "mappings": [], @@ -2037,13 +2131,128 @@ data: "x": 0, "y": 18 }, - "id": 18, + "id": 18, + "interval": "60s", + "options": { + "legend": { + "calcs": [], + "displayMode": "table", + "placement": "right" + }, + "tooltip": { + "mode": "single" + } + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(throughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time", + "refId": "A" + } + ], + "title": "Throughput of Node-to-Node", + "transformations": [ + { + "id": "groupBy", + "options": { + "fields": { + "Time": { + "aggregations": [], + "operation": "aggregate" + } + } + } + }, + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], + "transparent": true, + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "bps" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 12, + "x": 12, + "y": 18 + }, + "id": 24, "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -2054,24 +2263,24 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(throughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(reverseThroughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time", + "refId": "A" } ], - "title": "Throughput of Node-to-Node", + "title": "Reverse Throughput of Node-to-Node", "transformations": [ { "id": "groupBy", @@ -2123,7 +2332,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -2153,16 +2362,14 @@ data: "gridPos": { "h": 10, "w": 12, - "x": 12, - "y": 18 + "x": 0, + "y": 28 }, - "id": 24, + "id": 25, "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -2173,24 +2380,24 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, CONCAT(sourceNodeName, '->', destinationNodeName) as pair, SUM(reverseThroughput) as Node\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time, sourceNodeName, SUM(throughputFromSourceNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' \nAND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, sourceNodeName\nORDER BY time", + "refId": "A" } ], - "title": "Reverse Throughput of Node-to-Node", + "title": "Throughput of Node as Source", "transformations": [ { "id": "groupBy", @@ -2206,13 +2413,81 @@ data: { "id": "labelsToFields", "options": { - "valueLabel": "pair" + "valueLabel": "sourceNodeName" } } ], "transparent": true, "type": "timeseries" }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "decbytes" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 12, + "x": 12, + "y": 28 + }, + "id": 21, + "interval": "60s", + "options": { + "displayLabels": [], + "legend": { + "displayMode": "table", + "placement": "right", + "values": [ + "percent", + "value" + ] + }, + "pieType": "pie", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "limit": 25, + "values": true + }, + "tooltip": { + "mode": "single" + } + }, + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourceNodeName\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY sourceNodeName\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Node as Source", + "transparent": true, + "type": "piechart" + }, { "datasource": { "type": "grafana-clickhouse-datasource", @@ -2242,7 +2517,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -2273,15 +2548,13 @@ data: "h": 10, "w": 12, "x": 0, - "y": 28 + "y": 38 }, - "id": 25, + "id": 26, "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -2292,24 +2565,24 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time, sourceNodeName, SUM(throughputFromSourceNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' \nAND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, sourceNodeName\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time, destinationNodeName, SUM(throughputFromDestinationNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, destinationNodeName\nORDER BY time", + "refId": "A" } ], - "title": "Throughput of Node as Source", + "title": "Throughput of Node as Destination", "transformations": [ { "id": "groupBy", @@ -2325,7 +2598,7 @@ data: { "id": "labelsToFields", "options": { - "valueLabel": "sourceNodeName" + "valueLabel": "destinationNodeName" } } ], @@ -2358,12 +2631,10 @@ data: "h": 10, "w": 12, "x": 12, - "y": 28 + "y": 38 }, - "id": 21, - "interval": "60s", + "id": 22, "options": { - "displayLabels": [], "legend": { "displayMode": "table", "placement": "right", @@ -2392,13 +2663,148 @@ data: "uid": "PDEE91DDB90597936" }, "format": 1, - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourceNodeName\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY sourceNodeName\nORDER BY bytes DESC", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, destinationNodeName\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY destinationNodeName\nORDER BY bytes DESC", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Node as Destination", + "transparent": true, + "type": "piechart" + } + ], + "refresh": "", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "filters": [], + "hide": 0, + "name": "Filter", + "skipUrlSync": false, + "type": "adhoc" + }, + { + "hide": 2, + "name": "clickhouse_adhoc_query", + "query": "default.flows_node_view", + "skipUrlSync": false, + "type": "constant" + } + ] + }, + "time": { + "from": "now-30m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "node_to_node_dashboard", + "uid": "1F56RJh7z", + "version": 2, + "weekStart": "" + } + pod_to_external_dashboard.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 4, + "iteration": 1659133592592, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 0, + "y": 0 + }, + "id": 13, + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", + "refId": "A" + } + ], + "title": "Cumulative Bytes of Pod-to-External", + "transparent": true, + "type": "theia-grafana-sankey-plugin" + }, + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "gridPos": { + "h": 18, + "w": 12, + "x": 12, + "y": 0 + }, + "id": 12, + "options": { + "seriesCountSize": "sm", + "showSeriesCount": false, + "text": "Default value of text input option" + }, + "pluginVersion": "7.5.2", + "targets": [ + { + "datasource": { + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" + }, + "format": 1, + "queryType": "sql", + "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", "refId": "A" } ], - "title": "Cumulative Bytes of Node as Source", + "title": "Cumulative Reverse Bytes of Pod-to-External", "transparent": true, - "type": "piechart" + "type": "theia-grafana-sankey-plugin" }, { "datasource": { @@ -2423,13 +2829,16 @@ data: "viz": false }, "lineInterpolation": "linear", + "lineStyle": { + "fill": "solid" + }, "lineWidth": 1, "pointSize": 5, "scaleDistribution": { "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -2445,10 +2854,6 @@ data: { "color": "green", "value": null - }, - { - "color": "red", - "value": 80 } ] }, @@ -2460,15 +2865,13 @@ data: "h": 10, "w": 12, "x": 0, - "y": 38 + "y": 18 }, - "id": 26, - "interval": "60s", + "id": 2, + "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -2479,40 +2882,29 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time, destinationNodeName, SUM(throughputFromDestinationNode)\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, destinationNodeName\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" } ], - "title": "Throughput of Node as Destination", + "title": "Throughput of Pod-to-External", "transformations": [ - { - "id": "groupBy", - "options": { - "fields": { - "Time": { - "aggregations": [], - "operation": "aggregate" - } - } - } - }, { "id": "labelsToFields", "options": { - "valueLabel": "destinationNodeName" + "valueLabel": "pair" } } ], @@ -2530,13 +2922,43 @@ data: "mode": "palette-classic" }, "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", "hideFrom": { "legend": false, "tooltip": false, "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "always", + "spanNulls": 90000, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" } }, "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, "unit": "decbytes" }, "overrides": [] @@ -2545,45 +2967,51 @@ data: "h": 10, "w": 12, "x": 12, - "y": 38 + "y": 18 }, - "id": 22, + "id": 7, + "interval": "1s", "options": { "legend": { + "calcs": [], "displayMode": "table", - "placement": "right", - "values": [ - "percent", - "value" - ] - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "limit": 25, - "values": true + "placement": "right" }, "tooltip": { "mode": "single" } }, + "pluginVersion": "8.3.3", "targets": [ { "datasource": { "type": "grafana-clickhouse-datasource", "uid": "PDEE91DDB90597936" }, - "format": 1, - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, destinationNodeName\nFROM flows_node_view\nWHERE sourceNodeName != '' AND destinationNodeName != ''\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY destinationNodeName\nORDER BY bytes DESC", + "format": 2, + "meta": { + "builderOptions": { + "fields": [], + "limit": 100, + "mode": "list" + } + }, + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", "refId": "A" } ], - "title": "Cumulative Bytes of Node as Destination", + "title": "Reverse Throughput of Pod-to-External", + "transformations": [ + { + "id": "labelsToFields", + "options": { + "valueLabel": "pair" + } + } + ], "transparent": true, - "type": "piechart" + "type": "timeseries" } ], "refresh": "", @@ -2606,7 +3034,7 @@ data: { "hide": 2, "name": "clickhouse_adhoc_query", - "query": "default.flows_node_view", + "query": "default.flows_pod_view", "skipUrlSync": false, "type": "constant" } @@ -2618,357 +3046,11 @@ data: }, "timepicker": {}, "timezone": "", - "title": "node_to_node_dashboard", - "uid": "1F56RJh7z", - "version": 5, + "title": "pod_to_external_dashboard", + "uid": "K9SPrnJ7k", + "version": 2, "weekStart": "" } - pod_to_external_dashboard.json: | - { - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 1, - "iteration": 1655845123241, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 18, - "w": 12, - "x": 0, - "y": 0 - }, - "id": 13, - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 - } - ], - "title": "Cumulative Bytes of Pod-to-External", - "transparent": true, - "type": "theia-grafana-sankey-plugin" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "gridPos": { - "h": 18, - "w": 12, - "x": 12, - "y": 0 - }, - "id": 12, - "options": { - "seriesCountSize": "sm", - "showSeriesCount": false, - "text": "Default value of text input option" - }, - "pluginVersion": "7.5.2", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \ndestinationIP as destination\nFrom flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 - } - ], - "title": "Cumulative Reverse Bytes of Pod-to-External", - "transparent": true, - "type": "theia-grafana-sankey-plugin" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 12, - "x": 0, - "y": 18 - }, - "id": 2, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "right" - }, - "tooltip": { - "mode": "single" - } - }, - "pluginVersion": "8.3.3", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", - "meta": { - "builderOptions": { - "mode": "list", - "fields": [], - "limit": 100 - } - }, - "format": 2 - } - ], - "title": "Throughput of Pod-to-External", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - }, - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 10, - "w": 12, - "x": 12, - "y": 18 - }, - "id": 7, - "interval": "1s", - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "table", - "placement": "right" - }, - "tooltip": { - "mode": "single" - } - }, - "pluginVersion": "8.3.3", - "targets": [ - { - "refId": "A", - "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" - }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), '->', destinationIP) as pair,\nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType == 3\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", - "meta": { - "builderOptions": { - "mode": "list", - "fields": [], - "limit": 100 - } - }, - "format": 2 - } - ], - "title": "Reverse Throughput of Pod-to-External", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "pair" - } - } - ], - "transparent": true, - "type": "timeseries" - } - ], - "refresh": "", - "schemaVersion": 34, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "datasource": { - "type": "grafana-clickhouse-datasource", - "uid": "PDEE91DDB90597936" - }, - "filters": [], - "hide": 0, - "name": "Filter", - "skipUrlSync": false, - "type": "adhoc" - }, - { - "hide": 2, - "name": "clickhouse_adhoc_query", - "query": "default.flows_pod_view", - "skipUrlSync": false, - "type": "constant" - } - ] - }, - "time": { - "from": "now-30m", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "pod_to_external_dashboard", - "uid": "K9SPrnJ7k", - "version": 12, - "weekStart": "" - } pod_to_pod_dashboard.json: | { "annotations": { @@ -2994,7 +3076,7 @@ data: "fiscalYearStartMonth": 0, "graphTooltip": 0, "id": 5, - "iteration": 1655847050224, + "iteration": 1659133662707, "links": [], "liveNow": false, "panels": [ @@ -3018,14 +3100,14 @@ data: "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes of Pod-to-Pod", @@ -3052,14 +3134,14 @@ data: "pluginVersion": "7.5.2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Reverse Bytes of Pod-to-Pod", @@ -3095,7 +3177,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3128,9 +3210,7 @@ data: "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3141,21 +3221,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod-to-Pod", @@ -3199,7 +3279,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3236,9 +3316,7 @@ data: "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3249,21 +3327,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Reverse Throughput of Pod-to-Pod", @@ -3307,7 +3385,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3340,9 +3418,7 @@ data: "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3353,21 +3429,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Source", @@ -3439,10 +3515,10 @@ data: "type": "grafana-clickhouse-datasource", "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, sourcePodNamespace\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY sourcePodNamespace\nHAVING bytes > 0\nORDER BY bytes DESC", - "refId": "A", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes of Source Pod Namespace", @@ -3478,7 +3554,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3515,9 +3591,7 @@ data: "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3528,21 +3602,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationPodNamespace, '/', destinationPodName, ':', CAST(destinationTransportPort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Destination", @@ -3627,14 +3701,14 @@ data: "type": "grafana-clickhouse-datasource", "uid": "PDEE91DDB90597936" }, + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2, "rawSql": "SELECT SUM(octetDeltaCount) as bytes, destinationPodNamespace\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND $__timeFilter(flowEndSeconds)\nGROUP BY destinationPodNamespace\nORDER BY bytes DESC", "refId": "A" } @@ -3678,7 +3752,7 @@ data: "timezone": "", "title": "pod_to_pod_dashboard", "uid": "Yxn0Ghh7k", - "version": 2, + "version": 3, "weekStart": "" } pod_to_service_dashboard.json: | @@ -3705,8 +3779,8 @@ data: "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": 3, - "iteration": 1655844589249, + "id": 6, + "iteration": 1659133715817, "links": [], "liveNow": false, "panels": [ @@ -3730,14 +3804,14 @@ data: "pluginVersion": "7.5. 2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(octetDeltaCount) as bytes, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Bytes Pod-to-Service", @@ -3764,14 +3838,14 @@ data: "pluginVersion": "7.5. 2", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, + "format": 1, "queryType": "sql", "rawSql": "SELECT SUM(reverseOctetDeltaCount) as bytes,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as source, \nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as destination\nFrom flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY source, destination\nHAVING bytes > 0\nORDER BY bytes DESC\nLIMIT 50", - "format": 1 + "refId": "A" } ], "title": "Cumulative Reverse Bytes Pod-to-Service", @@ -3807,7 +3881,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3844,9 +3918,7 @@ data: "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3857,21 +3929,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(throughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(flowEndSeconds)\nGROUP BY time, pair\nHAVING AVG(throughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod-to-Service", @@ -3915,7 +3987,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -3952,9 +4024,7 @@ data: "interval": "1s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -3965,21 +4035,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSeconds) as time, \nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR), ' -> ', destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as pair, \nAVG(reverseThroughput)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, pair\nHAVING AVG(reverseThroughput) > 0\nORDER BY time", + "refId": "A" } ], "title": "Reverse Throughput of Pod-to-Service", @@ -4023,7 +4093,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -4060,9 +4130,7 @@ data: "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -4073,21 +4141,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromSourceNode) as time,\nCONCAT(sourcePodNamespace, '/', sourcePodName, ':', CAST(sourceTransportPort as VARCHAR)) as src,\nSUM(throughputFromSourceNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, src\nHAVING SUM(throughputFromSourceNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Pod as Source", @@ -4131,7 +4199,7 @@ data: "type": "linear" }, "showPoints": "always", - "spanNulls": true, + "spanNulls": 90000, "stacking": { "group": "A", "mode": "none" @@ -4168,9 +4236,7 @@ data: "interval": "60s", "options": { "legend": { - "calcs": [ - "mean" - ], + "calcs": [], "displayMode": "table", "placement": "right" }, @@ -4181,21 +4247,21 @@ data: "pluginVersion": "8.3.3", "targets": [ { - "refId": "A", "datasource": { - "uid": "PDEE91DDB90597936", - "type": "grafana-clickhouse-datasource" + "type": "grafana-clickhouse-datasource", + "uid": "PDEE91DDB90597936" }, - "queryType": "sql", - "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time\nLIMIT 50", + "format": 2, "meta": { "builderOptions": { - "mode": "list", "fields": [], - "limit": 100 + "limit": 100, + "mode": "list" } }, - "format": 2 + "queryType": "sql", + "rawSql": "SELECT $__timeInterval(flowEndSecondsFromDestinationNode) as time,\nCONCAT(destinationServicePortName, ':', CAST(destinationServicePort as VARCHAR)) as dst,\nSUM(throughputFromDestinationNode)\nFROM flows_pod_view\nWHERE flowType IN (1, 2)\nAND sourcePodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationPodNamespace NOT IN ('kube-system', 'flow-visibility', 'flow-aggregator')\nAND destinationServicePortName != ''\nAND $__timeFilter(time)\nGROUP BY time, dst\nHAVING SUM(throughputFromDestinationNode) > 0\nORDER BY time", + "refId": "A" } ], "title": "Throughput of Service as Destination", @@ -4245,7 +4311,7 @@ data: "timezone": "", "title": "pod_to_service_dashboard", "uid": "LGdxbW17z", - "version": 10, + "version": 2, "weekStart": "" } kind: ConfigMap diff --git a/docs/getting-started.md b/docs/getting-started.md index 2ac8b672f..b8a2332b9 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -46,7 +46,7 @@ commands: ```bash helm repo add antrea https://charts.antrea.io -helm install antrea antrea/antrea -n kube-system --set featureGate.FlowExporter=true +helm install antrea antrea/antrea -n kube-system --set featureGates.FlowExporter=true ``` This will install the latest available version of Antrea with the Flow Exporter diff --git a/docs/network-flow-visibility.md b/docs/network-flow-visibility.md index 8620acad0..584e19338 100644 --- a/docs/network-flow-visibility.md +++ b/docs/network-flow-visibility.md @@ -593,24 +593,24 @@ Flow Records Dashboard displays the number of flow records being captured in the selected time range. The detailed metadata of each of the records can be found in the table below. -Flow Records Dashboard +Flow Records Dashboard Flow Records Dashboard provides time-range control. The selected time-range will be applied to all the panels in the dashboard. This feature is also available for all the other pre-built dashboards. -Flow Records Dashboard +Flow Records Dashboard Flow Records Dashboard allows us to add key/value filters that automatically apply to all the panels in the dashboard. This feature is also available for all the other pre-built dashboards. -Flow Records Dashboard +Flow Records Dashboard Besides the dashboard-wide filter, Flow Records Dashboard also provides column-based filters that apply to each table column. -Flow Records Dashboard +Flow Records Dashboard #### Pod-to-Pod Flows Dashboard @@ -621,7 +621,7 @@ visualize the cumulative traffic grouped by source or destination Pod Namespace. Pod-to-Pod Flows Dashboard -Pod-to-Pod Flows Dashboard +Pod-to-Pod Flows Dashboard #### Pod-to-External Flows Dashboard @@ -629,9 +629,9 @@ Pod-to-External Flows Dashboard has similar visualization to Pod-to-Pod Flows Dashboard, visualizing the Pod-to-External flows. The destination of a traffic flow is represented by the destination IP address. -Pod-to-External Flows Dashboard +Pod-to-External Flows Dashboard -Pod-to-External Flows Dashboard +Pod-to-External Flows Dashboard #### Pod-to-Service Flows Dashboard @@ -641,7 +641,7 @@ is represented by the destination Service metadata. Pod-to-Service Flows Dashboard -Pod-to-Service Flows Dashboard +Pod-to-Service Flows Dashboard #### Node-to-Node Flows Dashboard @@ -651,7 +651,7 @@ and throughput is shown in the line graphs. Node-to-Node Flows Dashboard -Node-to-Node Flows Dashboard +Node-to-Node Flows Dashboard #### Network-Policy Flows Dashboard @@ -667,9 +667,9 @@ without NetworkPolicy enforced has the same color with its source Pod. Every link is in the shape of an arrow, pointing from source to destination. Line graphs show the evolution of traffic throughput with NetworkPolicy enforced. -Network-Policy Flows Dashboard +Network-Policy Flows Dashboard -Network-Policy Flows Dashboard +Network-Policy Flows Dashboard We can filter on desired fields, e.g. for egress/ingressNetworkPolicyRuleAction value: @@ -682,12 +682,12 @@ value: Here is an example if we filter on traffic with only ingressNetworkPolicyRuleAction equals to "Allow". -Network-Policy Flows Dashboard +Network-Policy Flows Dashboard Mouse over or click on source/destination highlights only the related traffic. Mouse out or click on the background will bring all the traffic back. -Network-Policy Flows Dashboard +Network-Policy Flows Dashboard ### Dashboard Customization