srplugin

package
v2.2.0-beta+incompatible Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2019 License: Apache-2.0 Imports: 14 Imported by: 0

README

SR plugin

The srplugin is a Core Agent Plugin designed to configure Segment routing for IPv6 (SRv6) in the VPP. Configuration managed by this plugin is modelled by srv6 proto file.

All configuration must be stored in ETCD using the srv6 key prefix:

/vnf-agent/<agent-label>/config/vpp/srv6/v2/

Configuring Local SIDs

The local SID can be configured using this key:

/vnf-agent/<agent-label>/config/vpp/srv6/v2/localsid/<SID>

where <SID> (Segment ID) is a unique ID of local sid and it must be an valid IPv6 address. The SID in NB key must be the same as in the json configuration (value of NB key-value pair).

Configuring Policy

The segment routing policy can be configured using this key:

/vnf-agent/<agent-label>/config/vpp/srv6/v2/policy/<bsid>

where <bsid> is unique binding SID of the policy. As any other SRv6 SID it must be an valid IPv6 address. Also the SID in NB key must be the same as in the json configuration (value of NB key-value pair).
The policy can have defined inside value multiple segment lists. The VPP implementation doesn't allow to have policy without at least one segment list. Therefore inserting(updating with) policy that has not defined at least one segment list will fail (value can be written in ETCD, but its application to VPP will fail as validation error).

Configuring Steering

The steering (the VPP's policy for steering traffic into SR policy) can be configured using this key:

/vnf-agent/<agent-label>/config/vpp/srv6/v2/steering/<name>

where <name> is a unique name of steering.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultPlugin = *NewPlugin()

DefaultPlugin is a default instance of SRPlugin.

Functions

This section is empty.

Types

type Deps

type Deps struct {
	infra.PluginDeps
	Scheduler   scheduler.KVScheduler
	GoVppmux    govppmux.API
	IfPlugin    ifplugin.API
	StatusCheck statuscheck.PluginStatusWriter // optional
}

Deps lists dependencies of the interface p.

type Option

type Option func(*SRPlugin)

Option is a function that can be used in NewPlugin to customize Plugin.

func UseDeps

func UseDeps(f func(*Deps)) Option

UseDeps returns Option that can inject custom dependencies.

type SRPlugin

type SRPlugin struct {
	Deps
	// contains filtered or unexported fields
}

SRPlugin configures segment routing.

func NewPlugin

func NewPlugin(opts ...Option) *SRPlugin

NewPlugin creates a new Plugin with the provides Options

func (*SRPlugin) AfterInit

func (p *SRPlugin) AfterInit() error

AfterInit registers plugin with StatusCheck.

func (*SRPlugin) Init

func (p *SRPlugin) Init() error

Init initializes and registers descriptors for Linux ARPs and Routes.

Directories

Path Synopsis
vpp1901
Package vpp1901 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage
Package vpp1901 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage
vpp1904
Package vpp1904 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage
Package vpp1904 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage
vpp1908
Package vpp1908 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage
Package vpp1908 contains wrappers over VPP (version 19.01) binary APIs to simplify their usage

Jump to

Keyboard shortcuts

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