Skip to content

Commit 58e028e

Browse files
committed
PoC on UDN UI
1 parent b7fdf62 commit 58e028e

33 files changed

+677
-256
lines changed

config/sample-config.yaml

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ loki:
1313
- DstK8S_Type
1414
- K8S_FlowLayer
1515
- FlowDirection
16+
- UDN
1617
# - Duplicate
1718
# - _RecordType
1819
# - K8S_ClusterName
@@ -82,7 +83,7 @@ frontend:
8283
merge: false
8384
# The following configuration is taken from Network Observability Operator
8485
# see https://github.com/netobserv/network-observability-operator/blob/main/controllers/consoleplugin/config/static-frontend-config.yaml
85-
panels:
86+
panels:
8687
# Protocol
8788
- Proto_Bytes
8889
- sum_Proto_Bytes
@@ -152,6 +153,20 @@ frontend:
152153
# flow on current scope
153154
- Flows
154155
- DnsFlows
156+
# UDN
157+
- UDN_Bytes
158+
- UDN_Packets
159+
- min_UDN_TimeFlowRttNs
160+
- max_UDN_TimeFlowRttNs
161+
- avg_UDN_TimeFlowRttNs
162+
- p90_UDN_TimeFlowRttNs
163+
- p99_UDN_TimeFlowRttNs
164+
- min_UDN_DnsLatencyMs
165+
- max_UDN_DnsLatencyMs
166+
- avg_UDN_DnsLatencyMs
167+
- p90_UDN_DnsLatencyMs
168+
- p99_UDN_DnsLatencyMs
169+
- UDN_Flows
155170
columns:
156171
- id: StartTime
157172
name: Start Time
@@ -555,6 +570,13 @@ frontend:
555570
field: Interfaces
556571
default: false
557572
width: 15
573+
- id: UDN
574+
name: User Defined Network
575+
tooltip: The user defined network Name.
576+
field: UDN
577+
filter: udn
578+
default: false
579+
width: 15
558580
- id: Bytes
559581
name: Bytes
560582
tooltip: The total aggregated number of bytes.
@@ -932,6 +954,10 @@ frontend:
932954
component: autocomplete
933955
placeholder: 'E.g: Ingress, Egress'
934956
hint: Specify the direction of the Flow observed at the network interface observation point.
957+
- id: udn
958+
name: User Defined Network
959+
component: autocomplete
960+
hint: Specify a user defined network name.
935961
- id: id
936962
name: Conversation Id
937963
component: text
@@ -1154,6 +1180,10 @@ frontend:
11541180
type: string
11551181
description: Cluster name or identifier
11561182
lokiLabel: true
1183+
- name: UDN
1184+
type: string
1185+
description: User Defined Network
1186+
lokiLabel: true
11571187
- name: _RecordType
11581188
type: string
11591189
description: "Type of record: 'flowLog' for regular flow logs, or 'newConnection', 'heartbeat', 'endConnection' for conversation tracking"

mocks/loki/flow_metrics_dropped_app.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,4 +114,4 @@
114114
}
115115
}
116116
}
117-
}
117+
}

mocks/loki/flow_metrics_dropped_namespace.json

Lines changed: 21 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"result": [
66
{
77
"metric": {
8-
"SrcK8S_Namespace": "netobserv"
8+
"SrcK8S_Namespace": "netobserv",
9+
"UDN": "my-udn"
910
},
1011
"values": [
1112
[
@@ -20,7 +21,8 @@
2021
},
2122
{
2223
"metric": {
23-
"SrcK8S_Namespace": "openshift-console"
24+
"SrcK8S_Namespace": "openshift-console",
25+
"UDN": "my-udn"
2426
},
2527
"values": [
2628
[
@@ -35,7 +37,8 @@
3537
},
3638
{
3739
"metric": {
38-
"SrcK8S_Namespace": "openshift-console-operator"
40+
"SrcK8S_Namespace": "openshift-console-operator",
41+
"UDN": "my-udn"
3942
},
4043
"values": [
4144
[
@@ -50,7 +53,8 @@
5053
},
5154
{
5255
"metric": {
53-
"SrcK8S_Namespace": "openshift-insights"
56+
"SrcK8S_Namespace": "openshift-insights",
57+
"UDN": "my-udn"
5458
},
5559
"values": [
5660
[
@@ -65,7 +69,8 @@
6569
},
6670
{
6771
"metric": {
68-
"SrcK8S_Namespace": "openshift-kube-storage-version-migrator-operator"
72+
"SrcK8S_Namespace": "openshift-kube-storage-version-migrator-operator",
73+
"UDN": "my-udn"
6974
},
7075
"values": [
7176
[
@@ -80,7 +85,8 @@
8085
},
8186
{
8287
"metric": {
83-
"SrcK8S_Namespace": "openshift-monitoring"
88+
"SrcK8S_Namespace": "openshift-monitoring",
89+
"UDN": "my-udn"
8490
},
8591
"values": [
8692
[
@@ -95,7 +101,8 @@
95101
},
96102
{
97103
"metric": {
98-
"SrcK8S_Namespace": "openshift-multus"
104+
"SrcK8S_Namespace": "openshift-multus",
105+
"UDN": "my-udn"
99106
},
100107
"values": [
101108
[
@@ -106,7 +113,8 @@
106113
},
107114
{
108115
"metric": {
109-
"SrcK8S_Namespace": "openshift-network-diagnostics"
116+
"SrcK8S_Namespace": "openshift-network-diagnostics",
117+
"UDN": "my-udn"
110118
},
111119
"values": [
112120
[
@@ -121,7 +129,8 @@
121129
},
122130
{
123131
"metric": {
124-
"SrcK8S_Namespace": "openshift-service-ca"
132+
"SrcK8S_Namespace": "openshift-service-ca",
133+
"UDN": "my-udn"
125134
},
126135
"values": [
127136
[
@@ -136,7 +145,8 @@
136145
},
137146
{
138147
"metric": {
139-
"SrcK8S_Namespace": "openshift-service-ca-operator"
148+
"SrcK8S_Namespace": "openshift-service-ca-operator",
149+
"UDN": "my-udn"
140150
},
141151
"values": [
142152
[
@@ -258,4 +268,4 @@
258268
}
259269
}
260270
}
261-
}
271+
}

mocks/loki/flow_metrics_dropped_owner.json

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
"metric": {
88
"SrcK8S_Namespace": "netobserv",
99
"SrcK8S_OwnerName": "flowlogs-pipeline",
10-
"SrcK8S_OwnerType": "DaemonSet"
10+
"SrcK8S_OwnerType": "DaemonSet",
11+
"UDN": "my-udn"
1112
},
1213
"values": [
1314
[
@@ -24,7 +25,8 @@
2425
"metric": {
2526
"SrcK8S_Namespace": "openshift-console",
2627
"SrcK8S_OwnerName": "console",
27-
"SrcK8S_OwnerType": "Deployment"
28+
"SrcK8S_OwnerType": "Deployment",
29+
"UDN": "my-udn"
2830
},
2931
"values": [
3032
[
@@ -41,7 +43,8 @@
4143
"metric": {
4244
"SrcK8S_Namespace": "openshift-console-operator",
4345
"SrcK8S_OwnerName": "console-operator",
44-
"SrcK8S_OwnerType": "Deployment"
46+
"SrcK8S_OwnerType": "Deployment",
47+
"UDN": "my-udn"
4548
},
4649
"values": [
4750
[
@@ -58,7 +61,8 @@
5861
"metric": {
5962
"SrcK8S_Namespace": "openshift-insights",
6063
"SrcK8S_OwnerName": "insights-operator",
61-
"SrcK8S_OwnerType": "Deployment"
64+
"SrcK8S_OwnerType": "Deployment",
65+
"UDN": "my-udn"
6266
},
6367
"values": [
6468
[
@@ -75,7 +79,8 @@
7579
"metric": {
7680
"SrcK8S_Namespace": "openshift-kube-storage-version-migrator-operator",
7781
"SrcK8S_OwnerName": "kube-storage-version-migrator-operator",
78-
"SrcK8S_OwnerType": "Deployment"
82+
"SrcK8S_OwnerType": "Deployment",
83+
"UDN": "my-udn"
7984
},
8085
"values": [
8186
[
@@ -92,7 +97,8 @@
9297
"metric": {
9398
"SrcK8S_Namespace": "openshift-monitoring",
9499
"SrcK8S_OwnerName": "prometheus-k8s",
95-
"SrcK8S_OwnerType": "StatefulSet"
100+
"SrcK8S_OwnerType": "StatefulSet",
101+
"UDN": "my-udn"
96102
},
97103
"values": [
98104
[
@@ -109,7 +115,8 @@
109115
"metric": {
110116
"SrcK8S_Namespace": "openshift-multus",
111117
"SrcK8S_OwnerName": "network-metrics-daemon",
112-
"SrcK8S_OwnerType": "DaemonSet"
118+
"SrcK8S_OwnerType": "DaemonSet",
119+
"UDN": "my-udn"
113120
},
114121
"values": [
115122
[
@@ -122,7 +129,8 @@
122129
"metric": {
123130
"SrcK8S_Namespace": "openshift-network-diagnostics",
124131
"SrcK8S_OwnerName": "network-check-source",
125-
"SrcK8S_OwnerType": "Deployment"
132+
"SrcK8S_OwnerType": "Deployment",
133+
"UDN": "my-udn"
126134
},
127135
"values": [
128136
[
@@ -139,7 +147,8 @@
139147
"metric": {
140148
"SrcK8S_Namespace": "openshift-service-ca",
141149
"SrcK8S_OwnerName": "service-ca",
142-
"SrcK8S_OwnerType": "Deployment"
150+
"SrcK8S_OwnerType": "Deployment",
151+
"UDN": "my-udn"
143152
},
144153
"values": [
145154
[
@@ -156,7 +165,8 @@
156165
"metric": {
157166
"SrcK8S_Namespace": "openshift-service-ca-operator",
158167
"SrcK8S_OwnerName": "service-ca-operator",
159-
"SrcK8S_OwnerType": "Deployment"
168+
"SrcK8S_OwnerType": "Deployment",
169+
"UDN": "my-udn"
160170
},
161171
"values": [
162172
[
@@ -172,7 +182,8 @@
172182
{
173183
"metric": {
174184
"SrcK8S_OwnerName": "ip-10-0-1-7.ec2.internal",
175-
"SrcK8S_OwnerType": "Node"
185+
"SrcK8S_OwnerType": "Node",
186+
"UDN": "my-udn"
176187
},
177188
"values": [
178189
[
@@ -281,4 +292,4 @@
281292
}
282293
}
283294
}
284-
}
295+
}

0 commit comments

Comments
 (0)