Documentation ¶
Index ¶
- Variables
- func AddHandlerVersion(version vpp.Version, msgs []govppapi.Message, h NewHandlerFunc)
- type ArpDetails
- type ArpMeta
- type ArpVppAPI
- type ArpVppRead
- type DHCPProxyAPI
- type DHCPProxyDetails
- type DHCPProxyRead
- type FibMplsLabel
- type IPNeighVppAPI
- type L3VppAPI
- type L3XC
- type L3XCVppAPI
- type L3XCVppRead
- type NewHandlerFunc
- type Path
- type ProxyArpInterfaceDetails
- type ProxyArpInterfaceMeta
- type ProxyArpRangesDetails
- type ProxyArpVppAPI
- type ProxyArpVppRead
- type RouteDetails
- type RouteMeta
- type RouteVppAPI
- type RouteVppRead
- type TeibVppAPI
- type TeibVppRead
- type VrfTableVppAPI
- type VrfTableVppRead
- type VrrpDetails
- type VrrpMeta
- type VrrpVppAPI
Constants ¶
This section is empty.
Variables ¶
var ( // ErrIPNeighborNotImplemented is used for IPScanNeighAPI handlers that are missing implementation. ErrIPNeighborNotImplemented = errors.New("ip neighbor config not implemented") // ErrTeibUnsupported error is returned if TEIB is not supported on given VPP version. ErrTeibUnsupported = errors.New("TEIB is not supported") // ErrVRRPUnsupported error is returned if VRRP is not supported on given VPP version. ErrVRRPUnsupported = errors.New("VRRP is not supported") )
var Handler = vpp.RegisterHandler(vpp.HandlerDesc{ Name: "l3", HandlerAPI: (*L3VppAPI)(nil), })
Functions ¶
func AddHandlerVersion ¶
func AddHandlerVersion(version vpp.Version, msgs []govppapi.Message, h NewHandlerFunc)
Types ¶
type ArpDetails ¶
ArpDetails holds info about ARP entry as a proto model
type ArpMeta ¶
type ArpMeta struct {
SwIfIndex uint32
}
ArpMeta contains interface index of the ARP interface
type ArpVppAPI ¶
type ArpVppAPI interface { ArpVppRead // VppAddArp adds ARP entry according to provided input VppAddArp(entry *l3.ARPEntry) error // VppDelArp removes old ARP entry according to provided input VppDelArp(entry *l3.ARPEntry) error }
ArpVppAPI provides methods for managing ARP entries
type ArpVppRead ¶
type ArpVppRead interface { // DumpArpEntries dumps ARPs from VPP and fills them into the provided static route map. DumpArpEntries() ([]*ArpDetails, error) }
ArpVppRead provides read methods for ARPs
type DHCPProxyAPI ¶
type DHCPProxyAPI interface { DHCPProxyRead // CreateDHCPProxy creates dhcp proxy according to provided input CreateDHCPProxy(entry *l3.DHCPProxy) error // DeleteDHCPProxy deletes created dhcp proxy DeleteDHCPProxy(entry *l3.DHCPProxy) error }
DHCPProxyAPI provides methods for managing ARP entries
type DHCPProxyDetails ¶
DHCPProxyDetails holds info about DHCP proxy entry as a proto model
type DHCPProxyRead ¶
type DHCPProxyRead interface { // DumpDHCPProxy returns configured DHCP proxy DumpDHCPProxy() ([]*DHCPProxyDetails, error) }
DHCPProxyRead provides read methods for routes
type FibMplsLabel ¶
FibMplsLabel is object returned with route dump.
type IPNeighVppAPI ¶
type IPNeighVppAPI interface { // SetIPScanNeighbor configures IP scan neighbor to the VPP SetIPScanNeighbor(data *l3.IPScanNeighbor) error // GetIPScanNeighbor returns IP scan neighbor configuration from the VPP GetIPScanNeighbor() (*l3.IPScanNeighbor, error) // DefaultIPScanNeighbor returns default IP scan neighbor configuration DefaultIPScanNeighbor() *l3.IPScanNeighbor }
IPNeighVppAPI provides methods for managing IP scan neighbor configuration
type L3VppAPI ¶
type L3VppAPI interface { ArpVppAPI ProxyArpVppAPI RouteVppAPI IPNeighVppAPI VrfTableVppAPI DHCPProxyAPI L3XCVppAPI TeibVppAPI VrrpVppAPI }
L3VppAPI groups L3 Vpp APIs.
func CompatibleL3VppHandler ¶
func CompatibleL3VppHandler( c vpp.Client, ifIdx ifaceidx.IfaceMetadataIndex, vrfIdx vrfidx.VRFMetadataIndex, addrAlloc netalloc.AddressAllocator, log logging.Logger, ) L3VppAPI
type L3XCVppAPI ¶
type L3XCVppAPI interface { L3XCVppRead UpdateL3XC(ctx context.Context, l3xc *L3XC) error DeleteL3XC(ctx context.Context, index uint32, ipv6 bool) error }
L3XCVppAPI provides methods for managing L3XC configuration.
type L3XCVppRead ¶
type L3XCVppRead interface { DumpAllL3XC(ctx context.Context) ([]L3XC, error) DumpL3XC(ctx context.Context, index uint32) ([]L3XC, error) }
L3XCVppRead provides read methods for L3XC configuration.
type NewHandlerFunc ¶
type NewHandlerFunc func(c vpp.Client, idx ifaceidx.IfaceMetadataIndex, vrfIdx vrfidx.VRFMetadataIndex, addrAlloc netalloc.AddressAllocator, log logging.Logger) L3VppAPI
type ProxyArpInterfaceDetails ¶
type ProxyArpInterfaceDetails struct { Interface *l3.ProxyARP_Interface Meta *ProxyArpInterfaceMeta }
ProxyArpInterfaceDetails holds info about proxy ARP interfaces as a proto modeled data
type ProxyArpInterfaceMeta ¶
type ProxyArpInterfaceMeta struct {
SwIfIndex uint32
}
ProxyArpInterfaceMeta contains interface vpp index
type ProxyArpRangesDetails ¶
type ProxyArpRangesDetails struct {
Range *l3.ProxyARP_Range
}
ProxyArpRangesDetails holds info about proxy ARP range as a proto modeled data
type ProxyArpVppAPI ¶
type ProxyArpVppAPI interface { ProxyArpVppRead // EnableProxyArpInterface enables interface for proxy ARP EnableProxyArpInterface(ifName string) error // DisableProxyArpInterface disables interface for proxy ARP DisableProxyArpInterface(ifName string) error // AddProxyArpRange adds new IP range for proxy ARP AddProxyArpRange(firstIP, lastIP []byte, vrfID uint32) error // DeleteProxyArpRange removes proxy ARP IP range DeleteProxyArpRange(firstIP, lastIP []byte, vrfID uint32) error }
ProxyArpVppAPI provides methods for managing proxy ARP entries
type ProxyArpVppRead ¶
type ProxyArpVppRead interface { // DumpProxyArpRanges returns configured proxy ARP ranges DumpProxyArpRanges() ([]*ProxyArpRangesDetails, error) // DumpProxyArpInterfaces returns configured proxy ARP interfaces DumpProxyArpInterfaces() ([]*ProxyArpInterfaceDetails, error) }
ProxyArpVppRead provides read methods for proxy ARPs
type RouteDetails ¶
RouteDetails is object returned as a VPP dump. It contains static route data in proto format, and VPP-specific metadata
type RouteMeta ¶
type RouteMeta struct { TableName string OutgoingIfIdx uint32 IsIPv6 bool Afi uint8 IsLocal bool IsUDPEncap bool IsUnreach bool IsProhibit bool IsResolveHost bool IsResolveAttached bool IsDvr bool IsSourceLookup bool NextHopID uint32 RpfID uint32 LabelStack []FibMplsLabel }
RouteMeta holds fields returned from the VPP as details which are not in the model
type RouteVppAPI ¶
type RouteVppAPI interface { RouteVppRead // VppAddRoute adds new route, according to provided input. // Every route has to contain VRF ID (default is 0). VppAddRoute(ctx context.Context, route *l3.Route) error // VppDelRoute removes old route, according to provided input. // Every route has to contain VRF ID (default is 0). VppDelRoute(ctx context.Context, route *l3.Route) error }
RouteVppAPI provides methods for managing routes
type RouteVppRead ¶
type RouteVppRead interface { // DumpRoutes dumps l3 routes from VPP and fills them // into the provided static route map. DumpRoutes() ([]*RouteDetails, error) }
RouteVppRead provides read methods for routes
type TeibVppAPI ¶ added in v3.2.0
type TeibVppAPI interface { TeibVppRead // VppAddTeibEntry adds a new TEIB entry. VppAddTeibEntry(ctx context.Context, entry *l3.TeibEntry) error // VppDelTeibEntry removes an existing TEIB entry. VppDelTeibEntry(ctx context.Context, entry *l3.TeibEntry) error }
TeibVppAPI provides methods for managing VPP tunnel information base.
type TeibVppRead ¶ added in v3.2.0
type TeibVppRead interface { // DumpTeib dumps TEIB entries from VPP and fills them into the provided TEIB entry map. DumpTeib() ([]*l3.TeibEntry, error) }
TeibVppRead provides read methods VPP tunnel information base.
type VrfTableVppAPI ¶
type VrfTableVppAPI interface { VrfTableVppRead // AddVrfTable adds new VRF table. AddVrfTable(table *l3.VrfTable) error // DelVrfTable deletes existing VRF table. DelVrfTable(table *l3.VrfTable) error // SetVrfFlowHashSettings sets IP flow hash settings for a VRF table. SetVrfFlowHashSettings(vrfID uint32, isIPv6 bool, hashFields *l3.VrfTable_FlowHashSettings) error }
VrfTableVppAPI provides methods for managing VRF tables.
type VrfTableVppRead ¶
type VrfTableVppRead interface { // DumpVrfTables dumps all configured VRF tables. DumpVrfTables() ([]*l3.VrfTable, error) }
VrfTableVppRead provides read methods for VRF tables.
type VrrpDetails ¶ added in v3.2.0
VrrpDetails is object returned as a VRRP dump.
type VrrpMeta ¶ added in v3.2.0
type VrrpMeta struct{}
VrrpMeta holds fields returned from the VPP as details which are not in the model
type VrrpVppAPI ¶ added in v3.2.0
type VrrpVppAPI interface { VppAddVrrp(entry *l3.VRRPEntry) error VppDelVrrp(entry *l3.VRRPEntry) error VppStartVrrp(entry *l3.VRRPEntry) error VppStopVrrp(entry *l3.VRRPEntry) error DumpVrrpEntries() ([]*VrrpDetails, error) }
VrrpVppAPI provides methods for managing VPP VRRP.
Directories ¶
Path | Synopsis |
---|---|
Package vppcalls contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them.
|
Package vppcalls contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them. |
Package vpp2106 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them.
|
Package vpp2106 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them. |
Package vpp2202 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them.
|
Package vpp2202 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them. |
Package vpp2210 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them.
|
Package vpp2210 contains wrappers over VPP binary APIs for ARPs, proxy ARPs, L3 FIBs and helpers for dumping them. |