rest

package
v0.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2025 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterSessionsByIP

func FilterSessionsByIP(nodeMap *map[string]*core.NodeAssociation, filterByIP net.IP) *core.Session

func FilterSessionsByTeid

func FilterSessionsByTeid(nodeMap *map[string]*core.NodeAssociation, filterByTeid uint32) *core.Session

func GetAllSessions

func GetAllSessions(nodeMap *map[string]*core.NodeAssociation) (sessions []core.Session)

Types

type ApiHandler

type ApiHandler struct {
	BpfObjects        *ebpf.BpfObjects
	PfcpSrv           *core.PfcpConnection
	ForwardPlaneStats *ebpf.UpfXdpActionStatistic
	Cfg               *config.UpfConfig
}

func NewApiHandler

func NewApiHandler(bpfObjects *ebpf.BpfObjects, pfcpSrv *core.PfcpConnection, forwardPlaneStats *ebpf.UpfXdpActionStatistic, cfg *config.UpfConfig) *ApiHandler

func (*ApiHandler) InitMetricsRoute

func (h *ApiHandler) InitMetricsRoute() *gin.Engine

func (*ApiHandler) InitRoutes

func (h *ApiHandler) InitRoutes() *gin.Engine

type FarMapElement added in v0.6.1

type FarMapElement struct {
	Id                    uint32 `json:"id"`
	Action                uint8  `json:"action"`
	OuterHeaderCreation   uint8  `json:"outer_header_creation"`
	Teid                  uint32 `json:"teid"`
	RemoteIP              uint32 `json:"remote_ip"`
	LocalIP               uint32 `json:"local_ip"`
	TransportLevelMarking uint16 `json:"transport_level_marking"`
}

type NodeAssociationMapNoSession added in v0.6.1

type NodeAssociationMapNoSession map[string]NodeAssociationNoSession

type NodeAssociationNoSession added in v0.6.1

type NodeAssociationNoSession struct {
	ID            string
	Addr          string
	NextSessionID uint64
}

type PacketStats added in v0.6.1

type PacketStats struct {
	RxArp      uint64 `json:"rx_arp"`
	RxIcmp     uint64 `json:"rx_icmp"`
	RxIcmp6    uint64 `json:"rx_icmp6"`
	RxIp4      uint64 `json:"rx_ip4"`
	RxIp6      uint64 `json:"rx_ip6"`
	RxTcp      uint64 `json:"rx_tcp"`
	RxUdp      uint64 `json:"rx_udp"`
	RxOther    uint64 `json:"rx_other"`
	RxGtpEcho  uint64 `json:"rx_gtp_echo"`
	RxGtpPdu   uint64 `json:"rx_gtp_pdu"`
	RxGtpOther uint64 `json:"rx_gtp_other"`
	RxGtpUnexp uint64 `json:"rx_gtp_unexp"`
}

type PdrElement added in v0.6.1

type PdrElement struct {
	Id                 uint32 `json:"id"`
	OuterHeaderRemoval uint8  `json:"outer_header_removal"`
	FarId              uint32 `json:"far_id"`
	QerId              uint32 `json:"qer_id"`
}

type XdpStats added in v0.6.1

type XdpStats struct {
	Aborted  uint64 `json:"aborted"`
	Drop     uint64 `json:"drop"`
	Pass     uint64 `json:"pass"`
	Tx       uint64 `json:"tx"`
	Redirect uint64 `json:"redirect"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL