Documentation
¶
Overview ¶
Package chaos handles the setup necessary to run chaos tests across chainlnk nodes and blockchains
Index ¶
Constants ¶
View Source
const ( // APIBasePath in form of /apis/<spec.group>/<spec.versions.name>, see Chaosmesh CRD 2.0.0 APIBasePath = "/apis/chaos-mesh.org/v1alpha1" // TemplatesPath path to the chaos templates TemplatesPath = "chaos/templates" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Client *kubernetes.Clientset
Namespace string
}
Config Chaosmesh controller config
type Controller ¶
type Controller struct {
Client *kubernetes.Clientset
Requests map[string]*rest.Request
Cfg *Config
}
Controller is controller that manages Chaosmesh CRD instances to run experiments
func NewController ¶
func NewController(cfg *Config) (*Controller, error)
NewController creates controller to run and stop chaos experiments
func (*Controller) Run ¶
func (c *Controller) Run(exp Experimentable) (string, error)
Run runs experiment and saves it's ID
func (*Controller) Stop ¶
func (c *Controller) Stop(name string) error
Stop removes experiment's entity
func (*Controller) StopAll ¶
func (c *Controller) StopAll() error
StopAll removes all experiments entities
type Experimentable ¶
type Experimentable interface {
SetBase(base experiments.Base)
Filename() string
Resource() string
}
Experimentable interface for chaos experiments
Click to show internal directories.
Click to hide internal directories.