driver

package
v1.6.2-rc Latest Latest
Warning

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

Go to latest
Published: May 24, 2023 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package driver include all the data path driver supported by cello, currently cello uses plain ENI driver for exclusive ENI mode, IPVlan driver for shared ENI with multi IP, veth driver for the fastpath of branch-trunk ENI mode.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetupDataPath

func SetupDataPath(setupConfig *types.SetupConfig) error

SetupDataPath setup data path for netns according to DP mode.

func TeardownNetwork

func TeardownNetwork(netNs string) error

TeardownNetwork all the networks netns.

Types

type DataPath

type DataPath interface {
	Name() string
	// SetupNetwork will set up datapath for netns.
	SetupNetwork(config *types.SetupConfig) error
}

DataPath is data path driver interface.

type ExclusiveENI

type ExclusiveENI struct{}

func NewExclusiveENIDriver

func NewExclusiveENIDriver() *ExclusiveENI

func (*ExclusiveENI) Name

func (d *ExclusiveENI) Name() string

func (*ExclusiveENI) SetupNetwork

func (d *ExclusiveENI) SetupNetwork(config *types.SetupConfig) (err error)

type FastPath

type FastPath struct {
	// contains filtered or unexported fields
}

FastPath is the local fastpath between pods and host.

type IPVlanDriver

type IPVlanDriver struct{}

IPVlanDriver is used in shared ENI mode.

func NewIPVlanDriver

func NewIPVlanDriver() *IPVlanDriver

NewIPVlanDriver creates an IPVlan driver.

func (*IPVlanDriver) Name

func (d *IPVlanDriver) Name() string

func (*IPVlanDriver) SetupNetwork

func (d *IPVlanDriver) SetupNetwork(config *types.SetupConfig) (err error)

SetupNetwork sets IPVlan data path up for netns, and also creates a fastpath (IPvlan slave interface) in host netns.

type VlanDriver

type VlanDriver struct{}

func NewVlanDriver

func NewVlanDriver() *VlanDriver

NewVlanDriver creates vlan driver.

func (*VlanDriver) Name

func (d *VlanDriver) Name() string

Name will return the name of Vlan driver.

func (*VlanDriver) SetupNetwork

func (d *VlanDriver) SetupNetwork(cfg *types.SetupConfig) (err error)

SetupNetwork sets vlan data path up.

Jump to

Keyboard shortcuts

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