Documentation ¶
Overview ¶
Package excludedprefixes provides a networkservice.NetworkServiceServer chain element that can read excluded prefixes from config map and add them to request to avoid repeated usage.
Index ¶
Constants ¶
View Source
const (
// PrefixesFilePathDefault - excluded prefixes file absolute path
PrefixesFilePathDefault = nsmConfigDir + "/" + prefixesFile
)
These variables set default path to the config file
Variables ¶
This section is empty.
Functions ¶
func NewServer ¶
func NewServer(ctx context.Context, setters ...ServerOption) networkservice.NetworkServiceServer
NewServer - creates a networkservice.NetworkServiceServer chain element that can read excluded prefixes from config map and add them to request to avoid repeated usage. Note: request.Connection and Connection.Context should not be nil when calling Request
Types ¶
type ServerOption ¶
type ServerOption func(server *excludedPrefixesServer)
ServerOption - method for excludedPrefixesServer
func WithConfigPath ¶
func WithConfigPath(s string) ServerOption
WithConfigPath - returns method that set configPath in excludedPrefixesServer
Click to show internal directories.
Click to hide internal directories.