Documentation ¶
Index ¶
Constants ¶
View Source
const ( ProxyNsmdK8sAddressEnv = "PROXY_NSMD_K8S_ADDRESS" ProxyNsmdK8sAddressDefaults = "pnsmgr-svc:5005" )
Default values and environment variables of proxy connection
View Source
const ( // ForwardingTimeout - Timeout waiting for Proxy NseRegistryClient ForwardingTimeout = 15 * time.Second // ProxyRegistryReconnectInterval - reconnect interval to Proxy NSMD-K8S if connection refused ProxyRegistryReconnectInterval = 15 * time.Second )
View Source
const PodNameEnv = utils.EnvVar("POD_NAME")
View Source
const PodUidEnv = utils.EnvVar("POD_UID")
Variables ¶
This section is empty.
Functions ¶
func FindNetworkServiceWithCache ¶
func FindNetworkServiceWithCache(cache RegistryCache, networkServiceName string) (*registry.FindNetworkServiceResponse, error)
FindNetworkServiceWithCache returns network service with name from registry cache
Types ¶
type RegistryCache ¶
type RegistryCache interface { AddNetworkService(ns *v1.NetworkService) (*v1.NetworkService, error) GetNetworkService(name string) (*v1.NetworkService, error) CreateOrUpdateNetworkServiceManager(nsm *v1.NetworkServiceManager) (*v1.NetworkServiceManager, error) GetNetworkServiceManager(name string) (*v1.NetworkServiceManager, error) AddNetworkServiceEndpoint(nse *v1.NetworkServiceEndpoint) (*v1.NetworkServiceEndpoint, error) DeleteNetworkServiceEndpoint(endpointName string) error GetEndpointsByNs(networkServiceName string) []*v1.NetworkServiceEndpoint GetEndpointsByNsm(nsmName string) []*v1.NetworkServiceEndpoint Start() error Stop() }
func NewRegistryCache ¶
func NewRegistryCache(cs *nsmClientset.Clientset, conf *ResourceFilterConfig) RegistryCache
NewRegistryCache creates new registry cache
type ResourceFilterConfig ¶
type ResourceFilterConfig struct { NetworkServiceEndpointFilterPolicy resourcecache.CacheFilterPolicy NetworkServiceManagerPolicy resourcecache.CacheFilterPolicy NetworkServiceFilterPolicy resourcecache.CacheFilterPolicy }
ResourceFilterConfig means filter resource config for nsm custom resources
Source Files ¶
Click to show internal directories.
Click to hide internal directories.