l2respondermap

package
v1.14.0-snapshot.6 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MapName           = "cilium_l2_responder_v4"
	DefaultMaxEntries = 4096
)

Variables

Functions

This section is empty.

Types

type IterateCallback

type IterateCallback func(*L2ResponderKey, *L2ResponderStats)

IterateCallback represents the signature of the callback function expected by the IterateWithCallback method, which in turn is used to iterate all the keys/values of an auth map.

type L2ResponderKey

type L2ResponderKey struct {
	IP      types.IPv4 `align:"ip"`
	IfIndex uint32     `align:"ifindex"`
}

AuthKey implements the bpf.MapKey interface.

Must be in sync with struct auth_key in <bpf/lib/common.h>

func (*L2ResponderKey) String

func (k *L2ResponderKey) String() string

type L2ResponderStats

type L2ResponderStats struct {
	ResponsesSent uint64 `align:"responses_sent"`
}

L2ResponderStats implements the bpf.MapValue interface.

Must be in sync with struct l2_responder_v4_stats in <bpf/lib/common.h>

func (*L2ResponderStats) String

func (s *L2ResponderStats) String() string

type Map

type Map interface {
	Create(ip net.IP, ifIndex uint32) error
	Lookup(ip net.IP, ifIndex uint32) (*L2ResponderStats, error)
	Delete(ip net.IP, ifIndex uint32) error
	IterateWithCallback(cb IterateCallback) error
}

func NewFakeMap

func NewFakeMap() Map

func NewMap

func NewMap(lifecycle hive.Lifecycle) (Map, error)

Jump to

Keyboard shortcuts

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