chaos

package
v0.0.0-...-7c8b764 Latest Latest
Warning

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

Go to latest
Published: May 18, 2018 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NAMESPACE  = metav1.NamespaceDefault
	IDENTIFIER = "kube-monkey-id"
	KIND       = "Pod"
	NAME       = "name"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Chaos

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

func New

func New(killtime time.Time, victim victims.Victim) *Chaos

Create a new Chaos instance

func NewMock

func NewMock() *Chaos

func (*Chaos) DurationToKillTime

func (c *Chaos) DurationToKillTime() time.Duration

Calculates the duration from now until Chaos.killAt

func (*Chaos) Execute

func (c *Chaos) Execute(resultchan chan<- *ChaosResult)

Exposed function that calls the actual execution of the chaos, i.e. termination of pods The result is sent back over the channel provided

func (*Chaos) KillAt

func (c *Chaos) KillAt() time.Time

func (*Chaos) NewResult

func (c *Chaos) NewResult(e error) *ChaosResult

Create a ChaosResult instance

func (*Chaos) Schedule

func (c *Chaos) Schedule(resultchan chan<- *ChaosResult)

Schedule the execution of Chaos

func (*Chaos) Victim

func (c *Chaos) Victim() victims.Victim

type ChaosResult

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

func (*ChaosResult) Error

func (r *ChaosResult) Error() error

func (*ChaosResult) Victim

func (r *ChaosResult) Victim() victims.Victim

Jump to

Keyboard shortcuts

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