nsmgr

package
v1.14.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2024 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Overview

Package nsmgr provides a Network Service Manager (nsmgrServer), but interface and implementation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Nsmgr

Nsmgr - A simple combination of the Endpoint, registry.NetworkServiceRegistryServer, and registry.NetworkServiceDiscoveryServer interfaces

func NewServer

func NewServer(ctx context.Context, tokenGenerator token.GeneratorFunc, options ...Option) Nsmgr

NewServer - Creates a new Nsmgr

          tokenGenerator - authorization token generator
			 options - a set of Nsmgr options.

type Option

type Option func(o *serverOptions)

Option modifies server option value

func WithAuthorizeMonitorConnectionServer added in v1.5.0

func WithAuthorizeMonitorConnectionServer(authorizeMonitorConnectionServer networkservice.MonitorConnectionServer) Option

WithAuthorizeMonitorConnectionServer sets authorization MonitorConnectionServer chain element

func WithAuthorizeNSERegistryClient added in v1.7.0

func WithAuthorizeNSERegistryClient(authorizeNSERegistryClient registryapi.NetworkServiceEndpointRegistryClient) Option

WithAuthorizeNSERegistryClient sets authorization NetworkServiceEndpointRegistry chain element

func WithAuthorizeNSERegistryServer added in v1.6.0

func WithAuthorizeNSERegistryServer(authorizeNSERegistryServer registryapi.NetworkServiceEndpointRegistryServer) Option

WithAuthorizeNSERegistryServer sets authorization NetworkServiceEndpointRegistry chain element

func WithAuthorizeNSRegistryClient added in v1.7.0

func WithAuthorizeNSRegistryClient(authorizeNSRegistryClient registryapi.NetworkServiceRegistryClient) Option

WithAuthorizeNSRegistryClient sets authorization NetworkServiceRegistry chain element

func WithAuthorizeNSRegistryServer added in v1.6.0

func WithAuthorizeNSRegistryServer(authorizeNSRegistryServer registryapi.NetworkServiceRegistryServer) Option

WithAuthorizeNSRegistryServer sets authorization NetworkServiceRegistry chain element

func WithAuthorizeServer

func WithAuthorizeServer(authorizeServer networkservice.NetworkServiceServer) Option

WithAuthorizeServer sets authorization server chain element

func WithDefaultExpiration added in v1.7.1

func WithDefaultExpiration(d time.Duration) Option

WithDefaultExpiration sets the default expiration for endpoints

func WithDialOptions added in v1.1.0

func WithDialOptions(dialOptions ...grpc.DialOption) Option

WithDialOptions sets grpc.DialOptions for the client

func WithDialTimeout added in v1.1.0

func WithDialTimeout(dialTimeout time.Duration) Option

WithDialTimeout sets dial timeout for the client

func WithForwarderServiceName added in v1.1.0

func WithForwarderServiceName(forwarderServiceName string) Option

WithForwarderServiceName overrides default forwarder service name By default "forwarder"

func WithName

func WithName(name string) Option

WithName - set a nsmgr name, a default name is `Nsmgr`.

func WithRegistry

func WithRegistry(regURL *url.URL) Option

WithRegistry sets URL and dial options to reach the upstream registry, if not passed memory storage will be used.

func WithURL

func WithURL(u string) Option

WithURL - set a public URL address for NetworkServiceManager, it is used to access endpoints within this NSMgr from remote clients. Default value is not set, and endpoints address will not be changed.

Jump to

Keyboard shortcuts

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