Documentation ¶
Overview ¶
Package strategycode manages forwarding strategy BPF programs.
Index ¶
- Variables
- func DestroyAll()
- type Strategy
- func (sc *Strategy) CountRefs() int
- func (sc *Strategy) ID() int
- func (sc *Strategy) InitFunc() func(arg unsafe.Pointer, sizeofArg uintptr) uint64
- func (sc *Strategy) Name() string
- func (sc *Strategy) Ptr() unsafe.Pointer
- func (sc *Strategy) String() string
- func (sc *Strategy) Unref()
- func (sc *Strategy) ValidateParams(params map[string]any) error
- type Xsyms
Constants ¶
This section is empty.
Variables ¶
View Source
var (
GqlStrategyType *gqlserver.NodeType[*Strategy]
)
GraphQL types.
Functions ¶
func DestroyAll ¶
func DestroyAll()
DestroyAll immediately unloads all strategies. Panics if some strategies are still used in FIB entry.
Types ¶
type Strategy ¶
type Strategy struct {
// contains filtered or unexported fields
}
Strategy is a reference of a forwarding strategy.
func LoadFile ¶
LoadFile loads a strategy BPF program from ELF file. If filename is empty, search for an ELF file in default locations.
func (*Strategy) CountRefs ¶
CountRefs returns number of references. Each FIB entry using the strategy has a reference. There's also a reference from table.go.
Click to show internal directories.
Click to hide internal directories.