Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
96 changes: 59 additions & 37 deletions controllers/consoleplugin/config/static-frontend-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,14 @@ columns:
default: false
width: 10
feature: subnetLabels
- id: SrcNetworkName
group: Source
name: Network Name
tooltip: Network name, such as Secondary network or UDN.
field: SrcK8S_NetworkName
filter: src_network
default: false
width: 15
- id: DstK8S_Name
group: Destination
name: Name
Expand Down Expand Up @@ -301,6 +309,14 @@ columns:
default: false
width: 10
feature: subnetLabels
- id: DstNetworkName
group: Destination
name: Network Name
tooltip: Network name, such as Secondary network or UDN.
field: DstK8S_NetworkName
filter: dst_network
default: false
width: 15
- id: K8S_Name
name: Names
calculated: '[SrcK8S_Name,DstK8S_Name]'
Expand Down Expand Up @@ -439,24 +455,18 @@ columns:
width: 10
- id: Udns
name: UDN labels
tooltip: The list of User Defined Networks.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

while u are here can u increase the width of this field to 15

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

field: Udns
filter: udns
default: true
width: 10
width: 15
feature: udnMapping
- id: FlowDirInts
name: Interfaces and Directions
tooltip: Pairs of network interface and direction of the Flow observed at the network interface observation point.
field: Interfaces
default: false
width: 15
- id: UDN
name: User Defined Network
tooltip: The user defined network identifier.
field: UdnId
filter: udn
default: false
width: 15
- id: Bytes
name: Bytes
tooltip: The total aggregated number of bytes.
Expand Down Expand Up @@ -906,6 +916,14 @@ filters:
- Starting text like cluster, "cluster-*"
- Ending text like "*-registry"
- Pattern like "cluster-*-registry", "c*-*-r*y", -i*e-
- id: src_network
name: Network Name
component: text
category: source
- id: dst_network
name: Network Name
component: text
category: destination
- id: protocol
name: Protocol
component: autocomplete
Expand Down Expand Up @@ -958,12 +976,10 @@ filters:
component: autocomplete
placeholder: 'E.g: Ingress, Egress'
hint: Specify the direction of the Flow observed at the network interface observation point.
- id: udn
- id: udns
name: User Defined Network
component: autocomplete
hint: Specify a user defined network name.
- id: udns
name: interface assigned udn label
- id: id
name: Conversation Id
component: text
Expand Down Expand Up @@ -1051,13 +1067,17 @@ scopes:
feature: multiCluster
filter: cluster_name
stepInto: zone
- id: udn
name: UDN
shortName: UDN
description: User Defined Network
- id: network
name: Network
shortName: Net
description: Network name, such as User Defined Network
labels:
- UdnId
filter: udn
- SrcK8S_NetworkName
- DstK8S_NetworkName
feature: udnMapping
filters:
- src_network
- dst_network
stepInto: namespace
- id: zone
name: Zone
Expand All @@ -1081,12 +1101,12 @@ scopes:
- SrcK8S_HostName
- DstK8S_HostName
groups:
- udns
- networks
- zones
- clusters
- clusters+zones
- clusters+udns
- udns+zones
- clusters+networks
- networks+zones
filters:
- src_host_name
- dst_host_name
Expand All @@ -1105,9 +1125,9 @@ scopes:
- zones
- zones+hosts
- hosts
- udns
- udns+zones
- udns+hosts
- networks
- networks+zones
- networks+hosts
filters:
- src_namespace
- dst_namespace
Expand All @@ -1134,10 +1154,10 @@ scopes:
- hosts
- hosts+namespaces
- namespaces
- udns
- udns+zones
- udns+hosts
- udns+namespaces
- networks
- networks+zones
- networks+hosts
- networks+namespaces
filters:
- src_owner_name
- dst_owner_name
Expand Down Expand Up @@ -1177,11 +1197,11 @@ scopes:
- namespaces
- namespaces+owners
- owners
- udns
- udns+zones
- udns+hosts
- udns+namespaces
- udns+owners
- networks
- networks+zones
- networks+hosts
- networks+namespaces
- networks+owners
filters:
- src_resource
- dst_resource
Expand Down Expand Up @@ -1234,6 +1254,9 @@ fields:
- name: SrcSubnetLabel
type: string
description: Source subnet label
- name: SrcK8S_NetworkName
type: string
description: Source network name
- name: DstK8S_Name
type: string
description: Name of the destination Kubernetes object, such as Pod name, Service name or Node name.
Expand Down Expand Up @@ -1272,6 +1295,9 @@ fields:
- name: DstSubnetLabel
type: string
description: Destination subnet label
- name: DstK8S_NetworkName
type: string
description: Destination network name
- name: K8S_FlowLayer
type: string
description: "Flow layer: 'app' or 'infra'"
Expand Down Expand Up @@ -1311,7 +1337,7 @@ fields:
description: Network interfaces
- name: Udns
type: string[]
description: Network interfaces UDNs mapping
description: List of User Defined Networks
- name: Flags
type: string[]
description: |
Expand Down Expand Up @@ -1389,10 +1415,6 @@ fields:
- name: K8S_ClusterName
type: string
description: Cluster name or identifier
- name: UdnId
type: string
description: User Defined Network
lokiLabel: true
- name: _RecordType
type: string
description: "Type of record: 'flowLog' for regular flow logs, or 'newConnection', 'heartbeat', 'endConnection' for conversation tracking"
Expand Down
15 changes: 5 additions & 10 deletions controllers/flp/flp_pipeline_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ func (b *PipelineBuilder) AddProcessorStages() error {
IPField: "SrcAddr",
MACField: "SrcMac",
InterfacesField: "Interfaces",
UDNsField: "Udns",
Output: "SrcK8S",
AddZone: addZone,
},
Expand All @@ -89,6 +90,7 @@ func (b *PipelineBuilder) AddProcessorStages() error {
IPField: "DstAddr",
MACField: "DstMac",
InterfacesField: "Interfaces",
UDNsField: "Udns",
Output: "DstK8S",
AddZone: addZone,
},
Expand Down Expand Up @@ -161,29 +163,22 @@ func (b *PipelineBuilder) AddProcessorStages() error {

// Propagate 2dary networks config
var secondaryNetworks []api.SecondaryNetwork
hasOvnk := false
if b.desired.Processor.Advanced != nil && len(b.desired.Processor.Advanced.SecondaryNetworks) > 0 {
for _, sn := range b.desired.Processor.Advanced.SecondaryNetworks {
flpSN := api.SecondaryNetwork{
Name: sn.Name,
Index: map[string]any{},
}
if sn.Name == ovnkSecondary {
hasOvnk = true
}
for _, index := range sn.Index {
flpSN.Index[strings.ToLower(string(index))] = nil
}
secondaryNetworks = append(secondaryNetworks, flpSN)
}
}
if !hasOvnk && helper.IsUDNMappingEnabled(&b.desired.Agent.EBPF) {
if helper.IsUDNMappingEnabled(&b.desired.Agent.EBPF) {
secondaryNetworks = append(secondaryNetworks, api.SecondaryNetwork{
Name: ovnkSecondary,
Index: map[string]any{
"ip": nil,
"interface": nil,
},
Name: ovnkSecondary,
Index: map[string]any{"udn": nil},
})
}

Expand Down
27 changes: 15 additions & 12 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ require (
github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/gopacket/gopacket v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.24.0 // indirect
github.com/heptiolabs/healthcheck v0.0.0-20211123025425-613501dd5deb // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/ip2location/ip2location-go/v9 v9.7.0 // indirect
Expand Down Expand Up @@ -131,34 +131,35 @@ require (
github.com/xdg-go/scram v1.1.2 // indirect
github.com/xdg-go/stringprep v1.0.4 // indirect
github.com/xrash/smetrics v0.0.0-20240312152122-5f08fbb34913 // indirect
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0 // indirect
go.opentelemetry.io/otel v1.32.0 // indirect
go.opentelemetry.io/otel v1.33.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.32.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp v1.29.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.28.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.27.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.26.0 // indirect
go.opentelemetry.io/otel/metric v1.32.0 // indirect
go.opentelemetry.io/otel/sdk v1.32.0 // indirect
go.opentelemetry.io/otel/metric v1.33.0 // indirect
go.opentelemetry.io/otel/sdk v1.33.0 // indirect
go.opentelemetry.io/otel/sdk/metric v1.32.0 // indirect
go.opentelemetry.io/otel/trace v1.32.0 // indirect
go.opentelemetry.io/proto/otlp v1.3.1 // indirect
go.opentelemetry.io/otel/trace v1.33.0 // indirect
go.opentelemetry.io/proto/otlp v1.4.0 // indirect
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/oauth2 v0.23.0 // indirect
golang.org/x/oauth2 v0.24.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/term v0.27.0 // indirect
golang.org/x/text v0.21.0 // indirect
golang.org/x/time v0.7.0 // indirect
golang.org/x/tools v0.28.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20241104194629-dd2ea8efbc28 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241104194629-dd2ea8efbc28 // indirect
google.golang.org/grpc v1.67.1 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20241209162323-e6fa225c2576 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241209162323-e6fa225c2576 // indirect
google.golang.org/grpc v1.68.1 // indirect
google.golang.org/protobuf v1.36.1 // indirect
gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect
gopkg.in/gcfg.v1 v1.2.3 // indirect
Expand All @@ -177,3 +178,5 @@ require (
)

replace github.com/prometheus/common v0.55.0 => github.com/netobserv/prometheus-common v0.55.0-netobserv

replace github.com/netobserv/flowlogs-pipeline => github.com/jotak/flowlogs-pipeline v0.0.0-20250123155116-d340ae3c81cb
Loading
Loading