Documentation ¶
Index ¶
- Constants
- func NewEndpoint(clusterID, hostname string, subnets ...string) *submV1.Endpoint
- func NewNode(name string) *corev1.Node
- type ControllerSupport
- func (c *ControllerSupport) CreateEndpoint(endpoint *submV1.Endpoint) *submV1.Endpoint
- func (c *ControllerSupport) CreateLocalHostEndpoint() *submV1.Endpoint
- func (c *ControllerSupport) CreateNode(node *corev1.Node) *corev1.Node
- func (c *ControllerSupport) DeleteEndpoint(name string)
- func (c *ControllerSupport) DeleteNode(name string)
- func (c *ControllerSupport) Start(handler event.Handler)
- func (c *ControllerSupport) UpdateEndpoint(endpoint *submV1.Endpoint)
- func (c *ControllerSupport) UpdateNode(node *corev1.Node)
- type TestEvent
- type TestHandler
- func (t *TestHandler) FailOnEvent(eventName ...string)
- func (t *TestHandler) GetName() string
- func (t *TestHandler) GetNetworkPlugins() []string
- func (t *TestHandler) Init() error
- func (t *TestHandler) LocalEndpointCreated(endpoint *v1.Endpoint) error
- func (t *TestHandler) LocalEndpointRemoved(endpoint *v1.Endpoint) error
- func (t *TestHandler) LocalEndpointUpdated(endpoint *v1.Endpoint) error
- func (t *TestHandler) NodeCreated(node *v12.Node) error
- func (t *TestHandler) NodeRemoved(node *v12.Node) error
- func (t *TestHandler) NodeUpdated(node *v12.Node) error
- func (t *TestHandler) RemoteEndpointCreated(endpoint *v1.Endpoint) error
- func (t *TestHandler) RemoteEndpointRemoved(endpoint *v1.Endpoint) error
- func (t *TestHandler) RemoteEndpointUpdated(endpoint *v1.Endpoint) error
- func (t *TestHandler) Stop() error
- func (t *TestHandler) TransitionToGateway() error
- func (t *TestHandler) TransitionToNonGateway() error
- func (t *TestHandler) Uninstall() error
- type TestHandlerState
Constants ¶
View Source
const ( Namespace = "test-namespace" LocalClusterID = "local-cluster" )
View Source
const ( EvTransitionToNonGateway = "TransitionToNonGateway" EvTransitionToGateway = "TransitionToGateway" EvLocalEndpointCreated = "LocalEndpointCreated" EvLocalEndpointUpdated = "LocalEndpointUpdated" EvLocalEndpointRemoved = "LocalEndpointRemoved" EvRemoteEndpointCreated = "RemoteEndpointCreated" EvRemoteEndpointUpdated = "RemoteEndpointUpdated" EvRemoteEndpointRemoved = "RemoteEndpointRemoved" EvNodeCreated = "NodeCreated" EvNodeUpdated = "NodeUpdated" EvNodeRemoved = "NodeRemoved" EvStop = "Stop" EvUninstall = "Uninstall" )
Variables ¶
This section is empty.
Functions ¶
func NewEndpoint ¶ added in v0.17.0
Types ¶
type ControllerSupport ¶ added in v0.17.0
type ControllerSupport struct { Hostname string // contains filtered or unexported fields }
func NewControllerSupport ¶ added in v0.17.0
func NewControllerSupport() *ControllerSupport
func (*ControllerSupport) CreateEndpoint ¶ added in v0.17.0
func (c *ControllerSupport) CreateEndpoint(endpoint *submV1.Endpoint) *submV1.Endpoint
func (*ControllerSupport) CreateLocalHostEndpoint ¶ added in v0.17.0
func (c *ControllerSupport) CreateLocalHostEndpoint() *submV1.Endpoint
func (*ControllerSupport) CreateNode ¶ added in v0.17.0
func (c *ControllerSupport) CreateNode(node *corev1.Node) *corev1.Node
func (*ControllerSupport) DeleteEndpoint ¶ added in v0.17.0
func (c *ControllerSupport) DeleteEndpoint(name string)
func (*ControllerSupport) DeleteNode ¶ added in v0.17.0
func (c *ControllerSupport) DeleteNode(name string)
func (*ControllerSupport) Start ¶ added in v0.17.0
func (c *ControllerSupport) Start(handler event.Handler)
func (*ControllerSupport) UpdateEndpoint ¶ added in v0.17.0
func (c *ControllerSupport) UpdateEndpoint(endpoint *submV1.Endpoint)
func (*ControllerSupport) UpdateNode ¶ added in v0.17.0
func (c *ControllerSupport) UpdateNode(node *corev1.Node)
type TestHandler ¶
type TestHandler struct { event.HandlerBase Name string NetworkPlugin string Events chan TestEvent Initialized bool // contains filtered or unexported fields }
func NewTestHandler ¶
func NewTestHandler(name, networkPlugin string, events chan TestEvent) *TestHandler
func (*TestHandler) FailOnEvent ¶
func (t *TestHandler) FailOnEvent(eventName ...string)
func (*TestHandler) GetName ¶
func (t *TestHandler) GetName() string
func (*TestHandler) GetNetworkPlugins ¶
func (t *TestHandler) GetNetworkPlugins() []string
func (*TestHandler) Init ¶
func (t *TestHandler) Init() error
func (*TestHandler) LocalEndpointCreated ¶
func (t *TestHandler) LocalEndpointCreated(endpoint *v1.Endpoint) error
func (*TestHandler) LocalEndpointRemoved ¶
func (t *TestHandler) LocalEndpointRemoved(endpoint *v1.Endpoint) error
func (*TestHandler) LocalEndpointUpdated ¶
func (t *TestHandler) LocalEndpointUpdated(endpoint *v1.Endpoint) error
func (*TestHandler) NodeCreated ¶
func (t *TestHandler) NodeCreated(node *v12.Node) error
func (*TestHandler) NodeRemoved ¶
func (t *TestHandler) NodeRemoved(node *v12.Node) error
func (*TestHandler) NodeUpdated ¶
func (t *TestHandler) NodeUpdated(node *v12.Node) error
func (*TestHandler) RemoteEndpointCreated ¶
func (t *TestHandler) RemoteEndpointCreated(endpoint *v1.Endpoint) error
func (*TestHandler) RemoteEndpointRemoved ¶
func (t *TestHandler) RemoteEndpointRemoved(endpoint *v1.Endpoint) error
func (*TestHandler) RemoteEndpointUpdated ¶
func (t *TestHandler) RemoteEndpointUpdated(endpoint *v1.Endpoint) error
func (*TestHandler) Stop ¶
func (t *TestHandler) Stop() error
func (*TestHandler) TransitionToGateway ¶
func (t *TestHandler) TransitionToGateway() error
func (*TestHandler) TransitionToNonGateway ¶
func (t *TestHandler) TransitionToNonGateway() error
func (*TestHandler) Uninstall ¶ added in v0.17.0
func (t *TestHandler) Uninstall() error
type TestHandlerState ¶ added in v0.17.0
type TestHandlerState struct { event.DefaultHandlerState Gateway bool }
func (*TestHandlerState) IsOnGateway ¶ added in v0.17.0
func (c *TestHandlerState) IsOnGateway() bool
Click to show internal directories.
Click to hide internal directories.