Skip to content

Commit

Permalink
More examples
Browse files Browse the repository at this point in the history
  • Loading branch information
jotak committed Apr 16, 2024
1 parent e0a3ce2 commit ebf5897
Show file tree
Hide file tree
Showing 6 changed files with 118 additions and 60 deletions.
30 changes: 0 additions & 30 deletions config/samples/flowmetrics/cluster_egress_traffic.yaml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# More examples in https://github.com/netobserv/network-observability-operator/tree/main/config/samples/flowmetrics
apiVersion: flows.netobserv.io/v1alpha1
kind: FlowMetric
metadata:
name: flowmetric-cluster-external-egress-rtt-seconds
spec:
metricName: cluster_external_egress_rtt_seconds
type: Histogram
valueField: TimeFlowRttNs
direction: Egress
includeDuplicates: true
labels: [SrcK8S_HostName,SrcK8S_Namespace,SrcK8S_OwnerName,SrcK8S_OwnerType]
filters:
- field: DstSubnetLabel
matchType: Absence
- field: TimeFlowRttNs
matchType: Presence
divider: "1000000000"
buckets: [".001", ".005", ".01", ".02", ".03", ".04", ".05", ".075", ".1", ".25", "1"]
charts:
- dashboardName: Main
title: External egress TCP latency
unit: seconds
type: SingleStat
queries:
- promQL: "histogram_quantile(0.99, sum(rate($METRIC_bucket[2m])) by (le)) > 0"
legend: "p99"
- dashboardName: Main
sectionName: Cluster
title: "Top external egress sRTT per workload, p50 (ms)"
unit: seconds
type: Line
queries:
- promQL: "histogram_quantile(0.5, sum(rate($METRIC_bucket{SrcK8S_Namespace!=\"\"}[2m])) by (le,SrcK8S_Namespace,SrcK8S_OwnerName))*1000 > 0"
legend: "{{SrcK8S_Namespace}} / {{SrcK8S_OwnerName}}"
- dashboardName: Main
sectionName: Cluster
title: "Top external egress sRTT per workload, p99 (ms)"
unit: seconds
type: Line
queries:
- promQL: "histogram_quantile(0.99, sum(rate($METRIC_bucket{SrcK8S_Namespace!=\"\"}[2m])) by (le,SrcK8S_Namespace,SrcK8S_OwnerName))*1000 > 0"
legend: "{{SrcK8S_Namespace}} / {{SrcK8S_OwnerName}}"
16 changes: 16 additions & 0 deletions config/samples/flowmetrics/cluster_external_egress_traffic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,19 @@ spec:
filters:
- field: DstSubnetLabel
matchType: Absence
charts:
- dashboardName: Main
title: Cluster egress traffic
unit: Bps
type: SingleStat
queries:
- promQL: "sum(rate($METRIC[2m]))"
legend: ""
- dashboardName: Main
sectionName: Cluster
title: Top cluster egress traffic per workload
unit: Bps
type: StackArea
queries:
- promQL: "sum(rate($METRIC{SrcK8S_Namespace!=\"\"}[2m])) by (SrcK8S_Namespace, SrcK8S_OwnerName)"
legend: "{{SrcK8S_Namespace}} / {{SrcK8S_OwnerName}}"
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# More examples in https://github.com/netobserv/network-observability-operator/tree/main/config/samples/flowmetrics
apiVersion: flows.netobserv.io/v1alpha1
kind: FlowMetric
metadata:
name: flowmetric-cluster-external-ingress-rtt-seconds
spec:
metricName: cluster_external_ingress_rtt_seconds
type: Histogram
valueField: TimeFlowRttNs
direction: Ingress
includeDuplicates: true
labels: [DstK8S_HostName,DstK8S_Namespace,DstK8S_OwnerName,DstK8S_OwnerType]
filters:
- field: SrcSubnetLabel
matchType: Absence
- field: TimeFlowRttNs
matchType: Presence
divider: "1000000000"
buckets: [".001", ".005", ".01", ".02", ".03", ".04", ".05", ".075", ".1", ".25", "1"]
charts:
- dashboardName: Main
title: External ingress TCP latency
unit: seconds
type: SingleStat
queries:
- promQL: "histogram_quantile(0.99, sum(rate($METRIC_bucket[2m])) by (le)) > 0"
legend: "p99"
- dashboardName: Main
sectionName: Cluster
title: "Top external ingress sRTT per workload, p50 (ms)"
unit: seconds
type: Line
queries:
- promQL: "histogram_quantile(0.5, sum(rate($METRIC_bucket{DstK8S_Namespace!=\"\"}[2m])) by (le,DstK8S_Namespace,DstK8S_OwnerName))*1000 > 0"
legend: "{{DstK8S_Namespace}} / {{DstK8S_OwnerName}}"
- dashboardName: Main
sectionName: Cluster
title: "Top external ingress sRTT per workload, p99 (ms)"
unit: seconds
type: Line
queries:
- promQL: "histogram_quantile(0.99, sum(rate($METRIC_bucket{DstK8S_Namespace!=\"\"}[2m])) by (le,DstK8S_Namespace,DstK8S_OwnerName))*1000 > 0"
legend: "{{DstK8S_Namespace}} / {{DstK8S_OwnerName}}"
16 changes: 16 additions & 0 deletions config/samples/flowmetrics/cluster_external_ingress_traffic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,19 @@ spec:
filters:
- field: SrcSubnetLabel
matchType: Absence
charts:
- dashboardName: Main
title: Cluster ingress traffic
unit: Bps
type: SingleStat
queries:
- promQL: "sum(rate($METRIC[2m]))"
legend: ""
- dashboardName: Main
sectionName: Cluster
title: Top cluster ingress traffic per workload
unit: Bps
type: StackArea
queries:
- promQL: "sum(rate($METRIC{DstK8S_Namespace!=\"\"}[2m])) by (DstK8S_Namespace, DstK8S_OwnerName)"
legend: "{{DstK8S_Namespace}} / {{DstK8S_OwnerName}}"
30 changes: 0 additions & 30 deletions config/samples/flowmetrics/cluster_ingress_traffic.yaml

This file was deleted.

0 comments on commit ebf5897

Please sign in to comment.