node

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2020 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

Package node provides functions and types to deal with the NodeConfiguration on the control plane

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WatchHandler

func WatchHandler(ctx context.Context, config *kubeconfig.KubeConfig, handler *ApateletHandler, stopInformerCh <-chan struct{}) error

WatchHandler watches a newly created informer for updates and calls functions on apateletHandler on updates

Types

type ApateletHandler

type ApateletHandler interface {
	// Updates the amount of apatelets based on a given node configuration
	GetDesiredApatelets(context.Context, *nodeconfigv1.NodeConfiguration) error

	// Spawns n apatelets with resources and label
	SpawnApatelets(context.Context, int64, scenario.NodeResources, string) error

	// Stops n apatelets with label
	StopApatelets(context.Context, int64, string) error
}

ApateletHandler contains utilities to spawn and stop apatelets, and to update them based on a given node configuration

func NewHandler

func NewHandler(st *store.Store, runnerRegistry *runner.Registry, info *service.ConnectionInfo, cl *kubernetes.Cluster) *ApateletHandler

NewHandler creates a new ApateletHandler

Jump to

Keyboard shortcuts

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