{"modulePath":"github.com/EMnify/vpp-agent","version":"v1.4.1","isLatest":false,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package l4plugin\n\n## Types\n\n```go\ntype L4Configurator struct {\n\tLog logging.Logger\n\n\tServiceLabel servicelabel.ReaderAPI\n\tGoVppmux     govppmux.API\n\n\t// Indexes\n\tSwIfIndexes  ifaceidx.SwIfIndex\n\tAppNsIndexes nsidx.AppNsIndexRW\n\n\tAppNsCached nsidx.AppNsIndexRW // the mapping stores not-configurable app namespaces with metadata\n\tAppNsIdxSeq uint32             // used only for AppNsCached; incremented after every registration\n\n\t// timer used to measure and store time\n\tStopwatch *measure.Stopwatch\n\t// contains filtered or unexported fields\n}\n```\nL4Configurator runs in the background in its own goroutine where it watches for any changes in the configuration of interfaces as modelled by the proto file \"../model/l4/l4.proto\" and stored in ETCD under the keys \"/vnf-agent/{vnf-agent}/vpp/config/v1/l4/l4ftEnabled\" and \"/vnf-agent/{vnf-agent}/vpp/config/v1/l4/namespaces/{namespace\\_id}\". Updates received from the northbound API are compared with the VPP run-time configuration and differences are applied through the VPP binary API.\n\n```go\nfunc (plugin *L4Configurator) Close() error\n```\nClose members, channels\n\n```go\nfunc (plugin *L4Configurator) ConfigureAppNamespace(ns *l4.AppNamespaces_AppNamespace) error\n```\nConfigureAppNamespace process the NB AppNamespace config and propagates it to bin api calls\n\n```go\nfunc (plugin *L4Configurator) ConfigureL4FeatureFlag(features *l4.L4Features) error\n```\nConfigureL4FeatureFlag process the NB Features config and propagates it to bin api calls\n\n```go\nfunc (plugin *L4Configurator) DeleteAppNamespace(ns *l4.AppNamespaces_AppNamespace) error\n```\nDeleteAppNamespace process the NB AppNamespace config and propagates it to bin api calls. This case is not currently supported by VPP\n\n```go\nfunc (plugin *L4Configurator) DeleteL4FeatureFlag() error\n```\nDeleteL4FeatureFlag process the NB Features config and propagates it to bin api calls\n\n```go\nfunc (plugin *L4Configurator) Init() (err error)\n```\nInit members (channels...) and start go routines\n\n```go\nfunc (plugin *L4Configurator) ModifyAppNamespace(newNs *l4.AppNamespaces_AppNamespace, oldNs *l4.AppNamespaces_AppNamespace) error\n```\nModifyAppNamespace process the NB AppNamespace config and propagates it to bin api calls\n\n```go\nfunc (plugin *L4Configurator) ResolveCreatedInterface(interfaceName string, interfaceIndex uint32) error\n```\nResolveCreatedInterface looks for application namespace this interface is assigned to and configures them\n\n```go\nfunc (plugin *L4Configurator) ResolveDeletedInterface(interfaceName string, interfaceIndex uint32) error\n```\nResolveDeletedInterface looks for application namespace this interface is assigned to and removes\n\n```go\nfunc (plugin *L4Configurator) ResyncAppNs(appNamespaces []*l4.AppNamespaces_AppNamespace) error\n```\nResyncAppNs configures app namespaces to the empty VPP\n\n```go\nfunc (plugin *L4Configurator) ResyncFeatures(l4Features *l4.L4Features) error\n```\nResyncFeatures sets initital L4Features flag\n\n","path":"github.com/EMnify/vpp-agent/plugins/defaultplugins/l4plugin","name":"l4plugin","synopsis":"","isRedistributable":true}
