...

Package v1alpha1

import "github.com/chaos-mesh/chaos-mesh/api/v1alpha1"
Overview
Index

Overview ▾

Package v1alpha1 contains API Schema definitions for the chaosmesh v1alpha1 API group +kubebuilder:object:generate=true +groupName=chaos-mesh.org

Index ▾

Constants
Variables
func AllKinds() map[string]*ChaosKind
func ParseCron(standardSpec string, cronField *field.Path) (cronv3.Schedule, field.ErrorList)
func RegisterPodIoHandler(newHandler PodIoChaosHandler)
func RegisterRawPodNetworkHandler(newHandler PodNetworkChaosHandler)
func ValidatePodMode(value string, mode PodMode, valueField *field.Path) field.ErrorList
func ValidateScheduler(schedulerObject InnerSchedulerObject, spec *field.Path) field.ErrorList
type AttrOverrideSpec
    func (in *AttrOverrideSpec) DeepCopy() *AttrOverrideSpec
    func (in *AttrOverrideSpec) DeepCopyInto(out *AttrOverrideSpec)
type BandwidthSpec
    func (in *BandwidthSpec) DeepCopy() *BandwidthSpec
    func (in *BandwidthSpec) DeepCopyInto(out *BandwidthSpec)
    func (in *BandwidthSpec) ToTbf() (*chaosdaemonpb.Tbf, error)
type CPUStressor
    func (in *CPUStressor) DeepCopy() *CPUStressor
    func (in *CPUStressor) DeepCopyInto(out *CPUStressor)
    func (in *CPUStressor) Validate(parent *field.Path) field.ErrorList
type ChainDirection
type ChaosInstance
type ChaosKind
type ChaosList
type ChaosPhase
type ChaosStatus
    func (in *ChaosStatus) DeepCopy() *ChaosStatus
    func (in *ChaosStatus) DeepCopyInto(out *ChaosStatus)
type ChaosValidator
type CorruptSpec
    func (in *CorruptSpec) DeepCopy() *CorruptSpec
    func (in *CorruptSpec) DeepCopyInto(out *CorruptSpec)
    func (in *CorruptSpec) ToNetem() (*chaosdaemonpb.Netem, error)
type DelaySpec
    func (in *DelaySpec) DeepCopy() *DelaySpec
    func (in *DelaySpec) DeepCopyInto(out *DelaySpec)
    func (in *DelaySpec) ToNetem() (*chaosdaemonpb.Netem, error)
type Direction
type DuplicateSpec
    func (in *DuplicateSpec) DeepCopy() *DuplicateSpec
    func (in *DuplicateSpec) DeepCopyInto(out *DuplicateSpec)
    func (in *DuplicateSpec) ToNetem() (*chaosdaemonpb.Netem, error)
type ExperimentPhase
type ExperimentStatus
    func (in *ExperimentStatus) DeepCopy() *ExperimentStatus
    func (in *ExperimentStatus) DeepCopyInto(out *ExperimentStatus)
type FailKernRequest
    func (in *FailKernRequest) DeepCopy() *FailKernRequest
    func (in *FailKernRequest) DeepCopyInto(out *FailKernRequest)
type FileType
type Filter
    func (in *Filter) DeepCopy() *Filter
    func (in *Filter) DeepCopyInto(out *Filter)
type Frame
    func (in *Frame) DeepCopy() *Frame
    func (in *Frame) DeepCopyInto(out *Frame)
type IOLayer
type InnerObject
type InnerSchedulerObject
type IoChaos
    func (in *IoChaos) DeepCopy() *IoChaos
    func (in *IoChaos) DeepCopyInto(out *IoChaos)
    func (in *IoChaos) DeepCopyObject() runtime.Object
    func (in *IoChaos) Default()
    func (in *IoChaos) GetChaos() *ChaosInstance
    func (in *IoChaos) GetDuration() (*time.Duration, error)
    func (in *IoChaos) GetNextRecover() time.Time
    func (in *IoChaos) GetNextStart() time.Time
    func (in *IoChaos) GetScheduler() *SchedulerSpec
    func (in *IoChaos) GetStatus() *ChaosStatus
    func (in *IoChaos) IsDeleted() bool
    func (in *IoChaos) IsPaused() bool
    func (in *IoChaos) SetNextRecover(t time.Time)
    func (in *IoChaos) SetNextStart(t time.Time)
    func (in *IoChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *IoChaos) Validate() error
    func (in *IoChaos) ValidateCreate() error
    func (in *IoChaos) ValidateDelete() error
    func (in *IoChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *IoChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *IoChaos) ValidateUpdate(old runtime.Object) error
type IoChaosAction
    func (in *IoChaosAction) DeepCopy() *IoChaosAction
    func (in *IoChaosAction) DeepCopyInto(out *IoChaosAction)
type IoChaosList
    func (in *IoChaosList) DeepCopy() *IoChaosList
    func (in *IoChaosList) DeepCopyInto(out *IoChaosList)
    func (in *IoChaosList) DeepCopyObject() runtime.Object
    func (in *IoChaosList) ListChaos() []*ChaosInstance
type IoChaosSpec
    func (in *IoChaosSpec) DeepCopy() *IoChaosSpec
    func (in *IoChaosSpec) DeepCopyInto(out *IoChaosSpec)
    func (in *IoChaosSpec) GetMode() PodMode
    func (in *IoChaosSpec) GetSelector() SelectorSpec
    func (in *IoChaosSpec) GetValue() string
type IoChaosStatus
    func (in *IoChaosStatus) DeepCopy() *IoChaosStatus
    func (in *IoChaosStatus) DeepCopyInto(out *IoChaosStatus)
type IoChaosType
type IoFault
    func (in *IoFault) DeepCopy() *IoFault
    func (in *IoFault) DeepCopyInto(out *IoFault)
type IoMethod
type KernelChaos
    func (in *KernelChaos) DeepCopy() *KernelChaos
    func (in *KernelChaos) DeepCopyInto(out *KernelChaos)
    func (in *KernelChaos) DeepCopyObject() runtime.Object
    func (in *KernelChaos) Default()
    func (in *KernelChaos) GetChaos() *ChaosInstance
    func (in *KernelChaos) GetDuration() (*time.Duration, error)
    func (in *KernelChaos) GetNextRecover() time.Time
    func (in *KernelChaos) GetNextStart() time.Time
    func (in *KernelChaos) GetScheduler() *SchedulerSpec
    func (in *KernelChaos) GetStatus() *ChaosStatus
    func (in *KernelChaos) IsDeleted() bool
    func (in *KernelChaos) IsPaused() bool
    func (in *KernelChaos) SetNextRecover(t time.Time)
    func (in *KernelChaos) SetNextStart(t time.Time)
    func (in *KernelChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *KernelChaos) Validate() error
    func (in *KernelChaos) ValidateCreate() error
    func (in *KernelChaos) ValidateDelete() error
    func (in *KernelChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *KernelChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *KernelChaos) ValidateUpdate(old runtime.Object) error
type KernelChaosList
    func (in *KernelChaosList) DeepCopy() *KernelChaosList
    func (in *KernelChaosList) DeepCopyInto(out *KernelChaosList)
    func (in *KernelChaosList) DeepCopyObject() runtime.Object
    func (in *KernelChaosList) ListChaos() []*ChaosInstance
type KernelChaosSpec
    func (in *KernelChaosSpec) DeepCopy() *KernelChaosSpec
    func (in *KernelChaosSpec) DeepCopyInto(out *KernelChaosSpec)
    func (in *KernelChaosSpec) GetMode() PodMode
    func (in *KernelChaosSpec) GetSelector() SelectorSpec
    func (in *KernelChaosSpec) GetValue() string
type KernelChaosStatus
    func (in *KernelChaosStatus) DeepCopy() *KernelChaosStatus
    func (in *KernelChaosStatus) DeepCopyInto(out *KernelChaosStatus)
type LossSpec
    func (in *LossSpec) DeepCopy() *LossSpec
    func (in *LossSpec) DeepCopyInto(out *LossSpec)
    func (in *LossSpec) ToNetem() (*chaosdaemonpb.Netem, error)
type MemoryStressor
    func (in *MemoryStressor) DeepCopy() *MemoryStressor
    func (in *MemoryStressor) DeepCopyInto(out *MemoryStressor)
    func (in *MemoryStressor) Validate(parent *field.Path) field.ErrorList
type NetworkChaos
    func (in *NetworkChaos) DeepCopy() *NetworkChaos
    func (in *NetworkChaos) DeepCopyInto(out *NetworkChaos)
    func (in *NetworkChaos) DeepCopyObject() runtime.Object
    func (in *NetworkChaos) Default()
    func (in *NetworkChaos) GetChaos() *ChaosInstance
    func (in *NetworkChaos) GetDuration() (*time.Duration, error)
    func (in *NetworkChaos) GetNextRecover() time.Time
    func (in *NetworkChaos) GetNextStart() time.Time
    func (in *NetworkChaos) GetScheduler() *SchedulerSpec
    func (in *NetworkChaos) GetStatus() *ChaosStatus
    func (in *NetworkChaos) IsDeleted() bool
    func (in *NetworkChaos) IsPaused() bool
    func (in *NetworkChaos) SetNextRecover(t time.Time)
    func (in *NetworkChaos) SetNextStart(t time.Time)
    func (in *NetworkChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *NetworkChaos) Validate() error
    func (in *NetworkChaos) ValidateCreate() error
    func (in *NetworkChaos) ValidateDelete() error
    func (in *NetworkChaos) ValidateExternalTargets(target *field.Path) field.ErrorList
    func (in *NetworkChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *NetworkChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *NetworkChaos) ValidateUpdate(old runtime.Object) error
type NetworkChaosAction
type NetworkChaosList
    func (in *NetworkChaosList) DeepCopy() *NetworkChaosList
    func (in *NetworkChaosList) DeepCopyInto(out *NetworkChaosList)
    func (in *NetworkChaosList) DeepCopyObject() runtime.Object
    func (in *NetworkChaosList) ListChaos() []*ChaosInstance
type NetworkChaosSpec
    func (in *NetworkChaosSpec) DeepCopy() *NetworkChaosSpec
    func (in *NetworkChaosSpec) DeepCopyInto(out *NetworkChaosSpec)
    func (in *NetworkChaosSpec) DefaultDelay()
    func (in *NetworkChaosSpec) GetMode() PodMode
    func (in *NetworkChaosSpec) GetSelector() SelectorSpec
    func (in *NetworkChaosSpec) GetValue() string
type NetworkChaosStatus
    func (in *NetworkChaosStatus) DeepCopy() *NetworkChaosStatus
    func (in *NetworkChaosStatus) DeepCopyInto(out *NetworkChaosStatus)
type PodChaos
    func (in *PodChaos) DeepCopy() *PodChaos
    func (in *PodChaos) DeepCopyInto(out *PodChaos)
    func (in *PodChaos) DeepCopyObject() runtime.Object
    func (in *PodChaos) Default()
    func (in *PodChaos) GetChaos() *ChaosInstance
    func (in *PodChaos) GetDuration() (*time.Duration, error)
    func (in *PodChaos) GetNextRecover() time.Time
    func (in *PodChaos) GetNextStart() time.Time
    func (in *PodChaos) GetScheduler() *SchedulerSpec
    func (in *PodChaos) GetStatus() *ChaosStatus
    func (in *PodChaos) IsDeleted() bool
    func (in *PodChaos) IsPaused() bool
    func (in *PodChaos) SetNextRecover(t time.Time)
    func (in *PodChaos) SetNextStart(t time.Time)
    func (in *PodChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *PodChaos) Validate() error
    func (in *PodChaos) ValidateCreate() error
    func (in *PodChaos) ValidateDelete() error
    func (in *PodChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *PodChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *PodChaos) ValidateUpdate(old runtime.Object) error
type PodChaosAction
type PodChaosList
    func (in *PodChaosList) DeepCopy() *PodChaosList
    func (in *PodChaosList) DeepCopyInto(out *PodChaosList)
    func (in *PodChaosList) DeepCopyObject() runtime.Object
    func (in *PodChaosList) ListChaos() []*ChaosInstance
type PodChaosSpec
    func (in *PodChaosSpec) DeepCopy() *PodChaosSpec
    func (in *PodChaosSpec) DeepCopyInto(out *PodChaosSpec)
    func (in *PodChaosSpec) GetMode() PodMode
    func (in *PodChaosSpec) GetSelector() SelectorSpec
    func (in *PodChaosSpec) GetValue() string
type PodChaosStatus
    func (in *PodChaosStatus) DeepCopy() *PodChaosStatus
    func (in *PodChaosStatus) DeepCopyInto(out *PodChaosStatus)
type PodIoChaos
    func (in *PodIoChaos) DeepCopy() *PodIoChaos
    func (in *PodIoChaos) DeepCopyInto(out *PodIoChaos)
    func (in *PodIoChaos) DeepCopyObject() runtime.Object
    func (in *PodIoChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
type PodIoChaosHandler
type PodIoChaosList
    func (in *PodIoChaosList) DeepCopy() *PodIoChaosList
    func (in *PodIoChaosList) DeepCopyInto(out *PodIoChaosList)
    func (in *PodIoChaosList) DeepCopyObject() runtime.Object
type PodIoChaosSpec
    func (in *PodIoChaosSpec) DeepCopy() *PodIoChaosSpec
    func (in *PodIoChaosSpec) DeepCopyInto(out *PodIoChaosSpec)
type PodIoChaosWebhookRunner
    func (r *PodIoChaosWebhookRunner) Handle(ctx context.Context, req admission.Request) admission.Response
    func (r *PodIoChaosWebhookRunner) InjectDecoder(d *admission.Decoder) error
type PodMode
type PodNetworkChaos
    func (in *PodNetworkChaos) DeepCopy() *PodNetworkChaos
    func (in *PodNetworkChaos) DeepCopyInto(out *PodNetworkChaos)
    func (in *PodNetworkChaos) DeepCopyObject() runtime.Object
    func (in *PodNetworkChaos) Default()
    func (in *PodNetworkChaos) GetChaos() *ChaosInstance
    func (in *PodNetworkChaos) GetStatus() *ChaosStatus
    func (in *PodNetworkChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *PodNetworkChaos) ValidateCreate() error
    func (in *PodNetworkChaos) ValidateDelete() error
    func (in *PodNetworkChaos) ValidateUpdate(old runtime.Object) error
type PodNetworkChaosHandler
type PodNetworkChaosList
    func (in *PodNetworkChaosList) DeepCopy() *PodNetworkChaosList
    func (in *PodNetworkChaosList) DeepCopyInto(out *PodNetworkChaosList)
    func (in *PodNetworkChaosList) DeepCopyObject() runtime.Object
    func (in *PodNetworkChaosList) ListChaos() []*ChaosInstance
type PodNetworkChaosSpec
    func (in *PodNetworkChaosSpec) DeepCopy() *PodNetworkChaosSpec
    func (in *PodNetworkChaosSpec) DeepCopyInto(out *PodNetworkChaosSpec)
type PodNetworkChaosStatus
    func (in *PodNetworkChaosStatus) DeepCopy() *PodNetworkChaosStatus
    func (in *PodNetworkChaosStatus) DeepCopyInto(out *PodNetworkChaosStatus)
type PodStatus
    func (in *PodStatus) DeepCopy() *PodStatus
    func (in *PodStatus) DeepCopyInto(out *PodStatus)
type RawIPSet
    func (in *RawIPSet) DeepCopy() *RawIPSet
    func (in *RawIPSet) DeepCopyInto(out *RawIPSet)
type RawIptables
    func (in *RawIptables) DeepCopy() *RawIptables
    func (in *RawIptables) DeepCopyInto(out *RawIptables)
type RawRuleSource
    func (in *RawRuleSource) DeepCopy() *RawRuleSource
    func (in *RawRuleSource) DeepCopyInto(out *RawRuleSource)
type RawTrafficControl
    func (in *RawTrafficControl) DeepCopy() *RawTrafficControl
    func (in *RawTrafficControl) DeepCopyInto(out *RawTrafficControl)
type ReorderSpec
    func (in *ReorderSpec) DeepCopy() *ReorderSpec
    func (in *ReorderSpec) DeepCopyInto(out *ReorderSpec)
type ScheduleStatus
    func (in *ScheduleStatus) DeepCopy() *ScheduleStatus
    func (in *ScheduleStatus) DeepCopyInto(out *ScheduleStatus)
type SchedulerSpec
    func (in *SchedulerSpec) DeepCopy() *SchedulerSpec
    func (in *SchedulerSpec) DeepCopyInto(out *SchedulerSpec)
type SelectorSpec
    func (in *SelectorSpec) DeepCopy() *SelectorSpec
    func (in *SelectorSpec) DeepCopyInto(out *SelectorSpec)
    func (in *SelectorSpec) DefaultNamespace(namespace string)
type StatefulObject
type StressChaos
    func (in *StressChaos) DeepCopy() *StressChaos
    func (in *StressChaos) DeepCopyInto(out *StressChaos)
    func (in *StressChaos) DeepCopyObject() runtime.Object
    func (in *StressChaos) Default()
    func (in *StressChaos) GetChaos() *ChaosInstance
    func (in *StressChaos) GetDuration() (*time.Duration, error)
    func (in *StressChaos) GetNextRecover() time.Time
    func (in *StressChaos) GetNextStart() time.Time
    func (in *StressChaos) GetScheduler() *SchedulerSpec
    func (in *StressChaos) GetStatus() *ChaosStatus
    func (in *StressChaos) IsDeleted() bool
    func (in *StressChaos) IsPaused() bool
    func (in *StressChaos) SetNextRecover(t time.Time)
    func (in *StressChaos) SetNextStart(t time.Time)
    func (in *StressChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *StressChaos) Validate() error
    func (in *StressChaos) ValidateCreate() error
    func (in *StressChaos) ValidateDelete() error
    func (in *StressChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *StressChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *StressChaos) ValidateUpdate(old runtime.Object) error
type StressChaosList
    func (in *StressChaosList) DeepCopy() *StressChaosList
    func (in *StressChaosList) DeepCopyInto(out *StressChaosList)
    func (in *StressChaosList) DeepCopyObject() runtime.Object
    func (in *StressChaosList) ListChaos() []*ChaosInstance
type StressChaosSpec
    func (in *StressChaosSpec) DeepCopy() *StressChaosSpec
    func (in *StressChaosSpec) DeepCopyInto(out *StressChaosSpec)
    func (in *StressChaosSpec) GetMode() PodMode
    func (in *StressChaosSpec) GetSelector() SelectorSpec
    func (in *StressChaosSpec) GetValue() string
    func (in *StressChaosSpec) Validate(parent *field.Path) field.ErrorList
type StressChaosStatus
    func (in *StressChaosStatus) DeepCopy() *StressChaosStatus
    func (in *StressChaosStatus) DeepCopyInto(out *StressChaosStatus)
type StressInstance
    func (in *StressInstance) DeepCopy() *StressInstance
    func (in *StressInstance) DeepCopyInto(out *StressInstance)
type Stressor
    func (in *Stressor) DeepCopy() *Stressor
    func (in *Stressor) DeepCopyInto(out *Stressor)
    func (in *Stressor) Validate(parent *field.Path) field.ErrorList
type Stressors
    func (in *Stressors) DeepCopy() *Stressors
    func (in *Stressors) DeepCopyInto(out *Stressors)
    func (in *Stressors) Normalize() (string, error)
    func (in *Stressors) Validate(parent *field.Path) field.ErrorList
type Target
    func (in *Target) DeepCopy() *Target
    func (in *Target) DeepCopyInto(out *Target)
    func (in *Target) GetMode() PodMode
    func (in *Target) GetSelector() SelectorSpec
    func (in *Target) GetValue() string
type TcParameter
    func (in *TcParameter) DeepCopy() *TcParameter
    func (in *TcParameter) DeepCopyInto(out *TcParameter)
type TcType
type TimeChaos
    func (in *TimeChaos) DeepCopy() *TimeChaos
    func (in *TimeChaos) DeepCopyInto(out *TimeChaos)
    func (in *TimeChaos) DeepCopyObject() runtime.Object
    func (in *TimeChaos) Default()
    func (in *TimeChaos) GetChaos() *ChaosInstance
    func (in *TimeChaos) GetDuration() (*time.Duration, error)
    func (in *TimeChaos) GetNextRecover() time.Time
    func (in *TimeChaos) GetNextStart() time.Time
    func (in *TimeChaos) GetScheduler() *SchedulerSpec
    func (in *TimeChaos) GetStatus() *ChaosStatus
    func (in *TimeChaos) IsDeleted() bool
    func (in *TimeChaos) IsPaused() bool
    func (in *TimeChaos) SetDefaultValue()
    func (in *TimeChaos) SetNextRecover(t time.Time)
    func (in *TimeChaos) SetNextStart(t time.Time)
    func (in *TimeChaos) SetupWebhookWithManager(mgr ctrl.Manager) error
    func (in *TimeChaos) Validate() error
    func (in *TimeChaos) ValidateCreate() error
    func (in *TimeChaos) ValidateDelete() error
    func (in *TimeChaos) ValidatePodMode(spec *field.Path) field.ErrorList
    func (in *TimeChaos) ValidateScheduler(spec *field.Path) field.ErrorList
    func (in *TimeChaos) ValidateUpdate(old runtime.Object) error
type TimeChaosList
    func (in *TimeChaosList) DeepCopy() *TimeChaosList
    func (in *TimeChaosList) DeepCopyInto(out *TimeChaosList)
    func (in *TimeChaosList) DeepCopyObject() runtime.Object
    func (in *TimeChaosList) ListChaos() []*ChaosInstance
type TimeChaosSpec
    func (in *TimeChaosSpec) DeepCopy() *TimeChaosSpec
    func (in *TimeChaosSpec) DeepCopyInto(out *TimeChaosSpec)
    func (in *TimeChaosSpec) DefaultClockIds()
    func (in *TimeChaosSpec) GetMode() PodMode
    func (in *TimeChaosSpec) GetSelector() SelectorSpec
    func (in *TimeChaosSpec) GetValue() string
type TimeChaosStatus
    func (in *TimeChaosStatus) DeepCopy() *TimeChaosStatus
    func (in *TimeChaosStatus) DeepCopyInto(out *TimeChaosStatus)
type Timespec
    func (in *Timespec) DeepCopy() *Timespec
    func (in *Timespec) DeepCopyInto(out *Timespec)
type Validateable

Package files

common_types.go common_validation.go common_webhook.go groupversion_info.go iochaos_types.go iochaos_webhook.go kernelchaos_types.go kernelchaos_webhook.go kinds.go networkchaos_types.go networkchaos_webhook.go podchaos_types.go podchaos_webhook.go podiochaos_types.go podiochaos_webhook.go podnetworkchaos_types.go podnetworkchaos_webhook.go stresschaos_types.go stresschaos_webhook.go timechaos_types.go timechaos_webhook.go zz_generated.deepcopy.go

Constants

const (
    // ValidateSchedulerError defines the error message for ValidateScheduler
    ValidateSchedulerError = "schedule and duration should be omitted or defined at the same time"

    // ValidatePodchaosSchedulerError defines the error message for ValidateScheduler of Podchaos
    ValidatePodchaosSchedulerError = "schedule should be omitted"

    // ValidateValueParseError defines the error message for value parse error
    ValidateValueParseError = "parse value field error:%s"
)
const (
    // DefaultJitter defines default value for jitter
    DefaultJitter = "0ms"

    // DefaultCorrelation defines default value for correlation
    DefaultCorrelation = "0"
)

KindIOChaos is the kind for io chaos

const KindIOChaos = "IoChaos"

KindKernelChaos is the kind for kernel chaos

const KindKernelChaos = "KernelChaos"

KindNetworkChaos is the kind for network chaos

const KindNetworkChaos = "NetworkChaos"

KindPodChaos is the kind for pod chaos

const KindPodChaos = "PodChaos"

KindPodNetworkChaos is the kind for network chaos

const KindPodNetworkChaos = "PodNetworkChaos"

KindStressChaos is the kind for stress chaos

const KindStressChaos = "StressChaos"

KindTimeChaos is the kind for time chaos

const KindTimeChaos = "TimeChaos"
const (
    // PauseAnnotationKey defines the annotation used to pause a chaos
    PauseAnnotationKey = "experiment.chaos-mesh.org/pause"
)

Variables

var (
    // GroupVersion is group version used to register these objects
    GroupVersion = schema.GroupVersion{Group: "chaos-mesh.org", Version: "v1alpha1"}

    // SchemeBuilder is used to add go types to the GroupVersionKind scheme
    SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

    // AddToScheme adds the types in this group-version to the given scheme.
    AddToScheme = SchemeBuilder.AddToScheme
)

func AllKinds

func AllKinds() map[string]*ChaosKind

AllKinds returns all chaos kinds.

func ParseCron

func ParseCron(standardSpec string, cronField *field.Path) (cronv3.Schedule, field.ErrorList)

ParseCron returns a new crontab schedule representing the given standardSpec (https://en.wikipedia.org/wiki/Cron)

func RegisterPodIoHandler

func RegisterPodIoHandler(newHandler PodIoChaosHandler)

RegisterPodIoHandler registers handler into webhook

func RegisterRawPodNetworkHandler

func RegisterRawPodNetworkHandler(newHandler PodNetworkChaosHandler)

RegisterRawPodNetworkHandler registers handler into webhook

func ValidatePodMode

func ValidatePodMode(value string, mode PodMode, valueField *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func ValidateScheduler

func ValidateScheduler(schedulerObject InnerSchedulerObject, spec *field.Path) field.ErrorList

ValidateScheduler validates the InnerSchedulerObject

type AttrOverrideSpec

AttrOverrideSpec represents an override of attribution

type AttrOverrideSpec struct {
    //+optional
    Ino *uint64 `json:"ino,omitempty"`
    //+optional
    Size *uint64 `json:"size,omitempty"`
    //+optional
    Blocks *uint64 `json:"blocks,omitempty"`
    //+optional
    Atime *Timespec `json:"atime,omitempty"`
    //+optional
    Mtime *Timespec `json:"mtime,omitempty"`
    //+optional
    Ctime *Timespec `json:"ctime,omitempty"`
    //+optional
    Kind *FileType `json:"kind,omitempty"`
    //+optional
    Perm *uint16 `json:"perm,omitempty"`
    //+optional
    Nlink *uint32 `json:"nlink,omitempty"`
    //+optional
    UID *uint32 `json:"uid,omitempty"`
    //+optional
    GID *uint32 `json:"gid,omitempty"`
    //+optional
    Rdev *uint32 `json:"rdev,omitempty"`
}

func (*AttrOverrideSpec) DeepCopy

func (in *AttrOverrideSpec) DeepCopy() *AttrOverrideSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AttrOverrideSpec.

func (*AttrOverrideSpec) DeepCopyInto

func (in *AttrOverrideSpec) DeepCopyInto(out *AttrOverrideSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BandwidthSpec

BandwidthSpec defines detail of bandwidth limit.

type BandwidthSpec struct {
    // Rate is the speed knob. Allows bps, kbps, mbps, gbps, tbps unit. bps means bytes per second.
    Rate string `json:"rate"`
    // Limit is the number of bytes that can be queued waiting for tokens to become available.
    // +kubebuilder:validation:Minimum=1
    Limit uint32 `json:"limit"`
    // Buffer is the maximum amount of bytes that tokens can be available for instantaneously.
    // +kubebuilder:validation:Minimum=1
    Buffer uint32 `json:"buffer"`
    // Peakrate is the maximum depletion rate of the bucket.
    // The peakrate does not need to be set, it is only necessary
    // if perfect millisecond timescale shaping is required.
    // +optional
    // +kubebuilder:validation:Minimum=0
    Peakrate *uint64 `json:"peakrate,omitempty"`
    // Minburst specifies the size of the peakrate bucket. For perfect
    // accuracy, should be set to the MTU of the interface.  If a
    // peakrate is needed, but some burstiness is acceptable, this
    // size can be raised. A 3000 byte minburst allows around 3mbit/s
    // of peakrate, given 1000 byte packets.
    // +optional
    // +kubebuilder:validation:Minimum=0
    Minburst *uint32 `json:"minburst,omitempty"`
}

func (*BandwidthSpec) DeepCopy

func (in *BandwidthSpec) DeepCopy() *BandwidthSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BandwidthSpec.

func (*BandwidthSpec) DeepCopyInto

func (in *BandwidthSpec) DeepCopyInto(out *BandwidthSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BandwidthSpec) ToTbf

func (in *BandwidthSpec) ToTbf() (*chaosdaemonpb.Tbf, error)

ToTbf converts BandwidthSpec to *chaosdaemonpb.Tbf Bandwidth action use TBF under the hood. TBF stands for Token Bucket Filter, is a classful queueing discipline available for traffic control with the tc command. http://man7.org/linux/man-pages/man8/tc-tbf.8.html

type CPUStressor

CPUStressor defines how to stress CPU out

type CPUStressor struct {
    Stressor `json:",inline"`
    // Load specifies P percent loading per CPU worker. 0 is effectively a sleep (no load) and 100
    // is full loading.
    // +optional
    Load *int `json:"load,omitempty"`

    // extend stress-ng options
    // +optional
    Options []string `json:"options,omitempty"`
}

func (*CPUStressor) DeepCopy

func (in *CPUStressor) DeepCopy() *CPUStressor

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CPUStressor.

func (*CPUStressor) DeepCopyInto

func (in *CPUStressor) DeepCopyInto(out *CPUStressor)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*CPUStressor) Validate

func (in *CPUStressor) Validate(parent *field.Path) field.ErrorList

Validate validates whether the CPUStressor is well defined

type ChainDirection

ChainDirection represents the direction of chain

type ChainDirection string
const (
    // Input means this chain is linked with INPUT chain
    Input ChainDirection = "input"

    // Output means this chain is linked with OUTPUT chain
    Output ChainDirection = "output"
)

type ChaosInstance

ChaosInstance defines some common attribute for a chaos

type ChaosInstance struct {
    Name      string
    Namespace string
    Kind      string
    StartTime time.Time
    EndTime   time.Time
    Action    string
    Duration  string
    Status    string
    UID       string
}

type ChaosKind

ChaosKind includes one kind of chaos and its list type

type ChaosKind struct {
    Chaos runtime.Object
    ChaosList
}

type ChaosList

ChaosList defines a common interface for chaos lists

type ChaosList interface {
    runtime.Object
    ListChaos() []*ChaosInstance
}

type ChaosPhase

ChaosPhase is the current status of chaos task.

type ChaosPhase string
const (
    ChaosPhaseNone     ChaosPhase = ""
    ChaosPhaseNormal   ChaosPhase = "Normal"
    ChaosPhaseAbnormal ChaosPhase = "Abnormal"
)

type ChaosStatus

type ChaosStatus struct {
    // Phase is the chaos status.
    Phase         ChaosPhase `json:"phase"`
    Reason        string     `json:"reason,omitempty"`
    FailedMessage string     `json:"failedMessage,omitempty"`

    Scheduler ScheduleStatus `json:"scheduler,omitempty"`

    // Experiment records the last experiment state.
    Experiment ExperimentStatus `json:"experiment"`
}

func (*ChaosStatus) DeepCopy

func (in *ChaosStatus) DeepCopy() *ChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ChaosStatus.

func (*ChaosStatus) DeepCopyInto

func (in *ChaosStatus) DeepCopyInto(out *ChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ChaosValidator

ChaosValidator describes the interface should be implemented in chaos

type ChaosValidator interface {
    webhook.Validator
    // Validate validates chaos object
    Validate() error
    // ValidateScheduler validates the scheduler and duration
    ValidateScheduler(spec *field.Path) field.ErrorList
    // ValidatePodMode validates the value with podmode
    ValidatePodMode(spec *field.Path) field.ErrorList
}

type CorruptSpec

CorruptSpec defines detail of a corrupt action

type CorruptSpec struct {
    Corrupt     string `json:"corrupt"`
    Correlation string `json:"correlation"`
}

func (*CorruptSpec) DeepCopy

func (in *CorruptSpec) DeepCopy() *CorruptSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CorruptSpec.

func (*CorruptSpec) DeepCopyInto

func (in *CorruptSpec) DeepCopyInto(out *CorruptSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*CorruptSpec) ToNetem

func (in *CorruptSpec) ToNetem() (*chaosdaemonpb.Netem, error)

ToNetem implements Netem interface.

type DelaySpec

DelaySpec defines detail of a delay action

type DelaySpec struct {
    Latency     string       `json:"latency"`
    Correlation string       `json:"correlation,omitempty"`
    Jitter      string       `json:"jitter,omitempty"`
    Reorder     *ReorderSpec `json:"reorder,omitempty"`
}

func (*DelaySpec) DeepCopy

func (in *DelaySpec) DeepCopy() *DelaySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DelaySpec.

func (*DelaySpec) DeepCopyInto

func (in *DelaySpec) DeepCopyInto(out *DelaySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*DelaySpec) ToNetem

func (in *DelaySpec) ToNetem() (*chaosdaemonpb.Netem, error)

ToNetem implements Netem interface.

type Direction

Direction represents traffic direction from source to target, it could be netem, delay, loss, duplicate, corrupt or partition, check comments below for detail direction flow.

type Direction string
const (
    // To represents network packet from source to target
    To Direction = "to"

    // From represents network packet to source from target
    From Direction = "from"

    // Both represents both directions
    Both Direction = "both"
)

type DuplicateSpec

DuplicateSpec defines detail of a duplicate action

type DuplicateSpec struct {
    Duplicate   string `json:"duplicate"`
    Correlation string `json:"correlation"`
}

func (*DuplicateSpec) DeepCopy

func (in *DuplicateSpec) DeepCopy() *DuplicateSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DuplicateSpec.

func (*DuplicateSpec) DeepCopyInto

func (in *DuplicateSpec) DeepCopyInto(out *DuplicateSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*DuplicateSpec) ToNetem

func (in *DuplicateSpec) ToNetem() (*chaosdaemonpb.Netem, error)

ToNetem implements Netem interface.

type ExperimentPhase

ExperimentPhase is the current status of chaos experiment.

type ExperimentPhase string
const (
    ExperimentPhaseRunning  ExperimentPhase = "Running"
    ExperimentPhaseWaiting  ExperimentPhase = "Waiting"
    ExperimentPhasePaused   ExperimentPhase = "Paused"
    ExperimentPhaseFailed   ExperimentPhase = "Failed"
    ExperimentPhaseFinished ExperimentPhase = "Finished"
)

type ExperimentStatus

type ExperimentStatus struct {
    // +optional
    Phase ExperimentPhase `json:"phase,omitempty"`
    // +optional
    Reason string `json:"reason,omitempty"`
    // +optional
    StartTime *metav1.Time `json:"startTime,omitempty"`
    // +optional
    EndTime *metav1.Time `json:"endTime,omitempty"`
    // +optional
    Duration string `json:"duration,omitempty"`
    // +optional
    PodRecords []PodStatus `json:"podRecords,omitempty"`
}

func (*ExperimentStatus) DeepCopy

func (in *ExperimentStatus) DeepCopy() *ExperimentStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExperimentStatus.

func (*ExperimentStatus) DeepCopyInto

func (in *ExperimentStatus) DeepCopyInto(out *ExperimentStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FailKernRequest

FailKernRequest defines the injection conditions

type FailKernRequest struct {
    // FailType indicates what to fail, can be set to '0' / '1' / '2'
    // If `0`, indicates slab to fail (should_failslab)
    // If `1`, indicates alloc_page to fail (should_fail_alloc_page)
    // If `2`, indicates bio to fail (should_fail_bio)
    // You can read:
    //   1. https://www.kernel.org/doc/html/latest/fault-injection/fault-injection.html
    //   2. http://github.com/iovisor/bcc/blob/master/tools/inject_example.txt
    // to learn more
    // +kubebuilder:validation:Maximum=2
    // +kubebuilder:validation:Minimum=0
    FailType int32 `json:"failtype"`

    // Headers indicates the appropriate kernel headers you need.
    // Eg: "linux/mmzone.h", "linux/blkdev.h" and so on
    Headers []string `json:"headers,omitempty"`

    // Callchain indicate a special call chain, such as:
    //     ext4_mount
    //       -> mount_subtree
    //          -> ...
    //             -> should_failslab
    // With an optional set of predicates and an optional set of
    // parameters, which used with predicates. You can read call chan
    // and predicate examples from https://github.com/chaos-mesh/bpfki/tree/develop/examples
    // to learn more.
    // If no special call chain, just keep Callchain empty, which means it will fail at any call chain
    // with slab alloc (eg: kmalloc).
    Callchain []Frame `json:"callchain,omitempty"`

    // Probability indicates the fails with probability.
    // If you want 1%, please set this field with 1.
    // +kubebuilder:validation:Minimum=0
    // +kubebuilder:validation:Maximum=100
    Probability uint32 `json:"probability,omitempty"`

    // Times indicates the max times of fails.
    // +kubebuilder:validation:Minimum=0
    Times uint32 `json:"times,omitempty"`
}

func (*FailKernRequest) DeepCopy

func (in *FailKernRequest) DeepCopy() *FailKernRequest

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FailKernRequest.

func (*FailKernRequest) DeepCopyInto

func (in *FailKernRequest) DeepCopyInto(out *FailKernRequest)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FileType

FileType represents type of a file

type FileType string
const (
    NamedPipe   FileType = "namedPipe"
    CharDevice  FileType = "charDevice"
    BlockDevice FileType = "blockDevice"
    Directory   FileType = "directory"
    RegularFile FileType = "regularFile"
    TSymlink    FileType = "symlink"
    Socket      FileType = "socket"
)

type Filter

Filter represents a filter of IoChaos action, which will define the scope of an IoChaosAction

type Filter struct {
    // Path represents a glob of injecting path
    Path string `json:"path"`

    // Methods represents the method that the action will inject in
    // +optional
    Methods []IoMethod `json:"methods,omitempty"`

    // Percent represents the percent probability of injecting this action
    Percent int `json:"percent"`
}

func (*Filter) DeepCopy

func (in *Filter) DeepCopy() *Filter

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Filter.

func (*Filter) DeepCopyInto

func (in *Filter) DeepCopyInto(out *Filter)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Frame

Frame defines the function signature and predicate in function's body

type Frame struct {
    // Funcname can be find from kernel source or `/proc/kallsyms`, such as `ext4_mount`
    Funcname string `json:"funcname,omitempty"`

    // Parameters is used with predicate, for example, if you want to inject slab error
    // in `d_alloc_parallel(struct dentry *parent, const struct qstr *name)` with a special
    // name `bananas`, you need to set it to `struct dentry *parent, const struct qstr *name`
    // otherwise omit it.
    Parameters string `json:"parameters,omitempty"`

    // Predicate will access the arguments of this Frame, example with Parameters's, you can
    // set it to `STRNCMP(name->name, "bananas", 8)` to make inject only with it, or omit it
    // to inject for all d_alloc_parallel call chain.
    Predicate string `json:"predicate,omitempty"`
}

func (*Frame) DeepCopy

func (in *Frame) DeepCopy() *Frame

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Frame.

func (*Frame) DeepCopyInto

func (in *Frame) DeepCopyInto(out *Frame)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IOLayer

IOLayer represents the layer of I/O system.

type IOLayer string

type InnerObject

InnerObject is basic Object for the Reconciler

type InnerObject interface {
    IsDeleted() bool
    IsPaused() bool
    GetChaos() *ChaosInstance
    StatefulObject
}

type InnerSchedulerObject

InnerSchedulerObject is the Object for the twophase reconcile

type InnerSchedulerObject interface {
    InnerObject
    GetDuration() (*time.Duration, error)

    GetNextStart() time.Time
    SetNextStart(time.Time)

    GetNextRecover() time.Time
    SetNextRecover(time.Time)

    GetScheduler() *SchedulerSpec
}

type IoChaos

IoChaos is the Schema for the iochaos API

type IoChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    Spec   IoChaosSpec   `json:"spec,omitempty"`
    Status IoChaosStatus `json:"status,omitempty"`
}

func (*IoChaos) DeepCopy

func (in *IoChaos) DeepCopy() *IoChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoChaos.

func (*IoChaos) DeepCopyInto

func (in *IoChaos) DeepCopyInto(out *IoChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*IoChaos) DeepCopyObject

func (in *IoChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*IoChaos) Default

func (in *IoChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*IoChaos) GetChaos

func (in *IoChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*IoChaos) GetDuration

func (in *IoChaos) GetDuration() (*time.Duration, error)

GetDuration would return the duration for chaos

func (*IoChaos) GetNextRecover

func (in *IoChaos) GetNextRecover() time.Time

func (*IoChaos) GetNextStart

func (in *IoChaos) GetNextStart() time.Time

func (*IoChaos) GetScheduler

func (in *IoChaos) GetScheduler() *SchedulerSpec

GetScheduler would return the scheduler for chaos

func (*IoChaos) GetStatus

func (in *IoChaos) GetStatus() *ChaosStatus

func (*IoChaos) IsDeleted

func (in *IoChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*IoChaos) IsPaused

func (in *IoChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*IoChaos) SetNextRecover

func (in *IoChaos) SetNextRecover(t time.Time)

func (*IoChaos) SetNextStart

func (in *IoChaos) SetNextStart(t time.Time)

func (*IoChaos) SetupWebhookWithManager

func (in *IoChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup IoChaos's webhook with manager

func (*IoChaos) Validate

func (in *IoChaos) Validate() error

Validate validates chaos object

func (*IoChaos) ValidateCreate

func (in *IoChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*IoChaos) ValidateDelete

func (in *IoChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*IoChaos) ValidatePodMode

func (in *IoChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*IoChaos) ValidateScheduler

func (in *IoChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates the scheduler and duration

func (*IoChaos) ValidateUpdate

func (in *IoChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type IoChaosAction

IoChaosAction defines an possible action of IoChaos

type IoChaosAction struct {
    Type IoChaosType `json:"type"`

    Filter `json:",inline"`

    // Faults represents the fault to inject
    // +optional
    Faults []IoFault `json:"faults,omitempty"`

    // Latency represents the latency to inject
    // +optional
    Latency string `json:"latency,omitempty"`

    // AttrOverride represents the attribution to override
    // +optional
    *AttrOverrideSpec `json:",inline"`

    // Source represents the source of current rules
    Source string `json:"source,omitempty"`
}

func (*IoChaosAction) DeepCopy

func (in *IoChaosAction) DeepCopy() *IoChaosAction

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoChaosAction.

func (*IoChaosAction) DeepCopyInto

func (in *IoChaosAction) DeepCopyInto(out *IoChaosAction)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IoChaosList

IoChaosList contains a list of IoChaos

type IoChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []IoChaos `json:"items"`
}

func (*IoChaosList) DeepCopy

func (in *IoChaosList) DeepCopy() *IoChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoChaosList.

func (*IoChaosList) DeepCopyInto

func (in *IoChaosList) DeepCopyInto(out *IoChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*IoChaosList) DeepCopyObject

func (in *IoChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*IoChaosList) ListChaos

func (in *IoChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of io chaos

type IoChaosSpec

IoChaosSpec defines the desired state of IoChaos

type IoChaosSpec struct {
    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // IF `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Action defines the specific pod chaos action.
    // Supported action: latency / fault / attrOverride
    // +kubebuilder:validation:Enum=latency;fault;attrOverride
    Action IoChaosType `json:"action"`

    // Delay defines the value of I/O chaos action delay.
    // A delay string is a possibly signed sequence of
    // decimal numbers, each with optional fraction and a unit suffix,
    // such as "300ms".
    // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    // +optional
    Delay string `json:"delay,omitempty"`

    // Errno defines the error code that returned by I/O action.
    // refer to: https://www-numi.fnal.gov/offline_software/srt_public_context/WebDocs/Errors/unix_system_errors.html
    // +optional
    Errno uint32 `json:"errno,omitempty"`

    // Attr defines the overrided attribution
    // +optional
    Attr *AttrOverrideSpec `json:"attr,omitempty"`

    // Path defines the path of files for injecting I/O chaos action.
    // +optional
    Path string `json:"path,omitempty"`

    // Methods defines the I/O methods for injecting I/O chaos action.
    // default: all I/O methods.
    // +optional
    Methods []IoMethod `json:"methods,omitempty"`

    // Percent defines the percentage of injection errors and provides a number from 0-100.
    // default: 100.
    // +optional
    Percent int `json:"percent,omitempty"`

    // VolumePath represents the mount path of injected volume
    VolumePath string `json:"volumePath"`

    // Scheduler defines some schedule rules to
    // control the running time of the chaos experiment about pods.
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`

    // Duration represents the duration of the chaos action.
    // It is required when the action is `PodFailureAction`.
    // A duration string is a possibly signed sequence of
    // decimal numbers, each with optional fraction and a unit suffix,
    // such as "300ms", "-1.5h" or "2h45m".
    // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    // +optional
    Duration *string `json:"duration,omitempty"`
}

func (*IoChaosSpec) DeepCopy

func (in *IoChaosSpec) DeepCopy() *IoChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoChaosSpec.

func (*IoChaosSpec) DeepCopyInto

func (in *IoChaosSpec) DeepCopyInto(out *IoChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*IoChaosSpec) GetMode

func (in *IoChaosSpec) GetMode() PodMode

func (*IoChaosSpec) GetSelector

func (in *IoChaosSpec) GetSelector() SelectorSpec

func (*IoChaosSpec) GetValue

func (in *IoChaosSpec) GetValue() string

type IoChaosStatus

IoChaosStatus defines the observed state of IoChaos

type IoChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*IoChaosStatus) DeepCopy

func (in *IoChaosStatus) DeepCopy() *IoChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoChaosStatus.

func (*IoChaosStatus) DeepCopyInto

func (in *IoChaosStatus) DeepCopyInto(out *IoChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IoChaosType

IoChaosType represents the type of an IoChaos Action

type IoChaosType string
const (
    // IoLatency represents injecting latency for io operation
    IoLatency IoChaosType = "latency"

    // IoFaults represents injecting faults for io operation
    IoFaults IoChaosType = "fault"

    // IoAttrOverride represents replacing attribution for io operation
    IoAttrOverride IoChaosType = "attrOverride"
)

type IoFault

IoFault represents the fault to inject and their weight

type IoFault struct {
    Errno  uint32 `json:"errno"`
    Weight int32  `json:"weight"`
}

func (*IoFault) DeepCopy

func (in *IoFault) DeepCopy() *IoFault

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IoFault.

func (*IoFault) DeepCopyInto

func (in *IoFault) DeepCopyInto(out *IoFault)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IoMethod

type IoMethod string
const (
    LookUp      IoMethod = "lookup"
    Forget      IoMethod = "forget"
    GetAttr     IoMethod = "getattr"
    SetAttr     IoMethod = "setattr"
    ReadLink    IoMethod = "readlink"
    Mknod       IoMethod = "mknod"
    Mkdir       IoMethod = "mkdir"
    UnLink      IoMethod = "unlink"
    Rmdir       IoMethod = "rmdir"
    MSymlink    IoMethod = "symlink"
    Rename      IoMethod = "rename"
    Link        IoMethod = "link"
    Open        IoMethod = "open"
    Read        IoMethod = "read"
    Write       IoMethod = "write"
    Flush       IoMethod = "flush"
    Release     IoMethod = "release"
    Fsync       IoMethod = "fsync"
    Opendir     IoMethod = "opendir"
    Readdir     IoMethod = "readdir"
    Releasedir  IoMethod = "releasedir"
    Fsyncdir    IoMethod = "fsyncdir"
    Statfs      IoMethod = "statfs"
    SetXAttr    IoMethod = "setxattr"
    GetXAttr    IoMethod = "getxattr"
    ListXAttr   IoMethod = "listxattr"
    RemoveXAttr IoMethod = "removexattr"
    Access      IoMethod = "access"
    Create      IoMethod = "create"
    GetLk       IoMethod = "getlk"
    SetLk       IoMethod = "setlk"
    Bmap        IoMethod = "bmap"
)

type KernelChaos

KernelChaos is the Schema for the kernelchaos API

type KernelChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a kernel chaos experiment
    Spec KernelChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the kernel chaos experiment
    Status KernelChaosStatus `json:"status"`
}

func (*KernelChaos) DeepCopy

func (in *KernelChaos) DeepCopy() *KernelChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelChaos.

func (*KernelChaos) DeepCopyInto

func (in *KernelChaos) DeepCopyInto(out *KernelChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KernelChaos) DeepCopyObject

func (in *KernelChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*KernelChaos) Default

func (in *KernelChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*KernelChaos) GetChaos

func (in *KernelChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*KernelChaos) GetDuration

func (in *KernelChaos) GetDuration() (*time.Duration, error)

GetDuration gets the duration of KernelChaos

func (*KernelChaos) GetNextRecover

func (in *KernelChaos) GetNextRecover() time.Time

GetNextRecover gets NextRecover field of KernelChaos

func (*KernelChaos) GetNextStart

func (in *KernelChaos) GetNextStart() time.Time

GetNextStart gets NextStart field of KernelChaos

func (*KernelChaos) GetScheduler

func (in *KernelChaos) GetScheduler() *SchedulerSpec

GetScheduler returns the scheduler of KernelChaos

func (*KernelChaos) GetStatus

func (in *KernelChaos) GetStatus() *ChaosStatus

GetStatus returns the status of KernelChaos

func (*KernelChaos) IsDeleted

func (in *KernelChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*KernelChaos) IsPaused

func (in *KernelChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*KernelChaos) SetNextRecover

func (in *KernelChaos) SetNextRecover(t time.Time)

SetNextRecover sets NextRecover field of KernelChaos

func (*KernelChaos) SetNextStart

func (in *KernelChaos) SetNextStart(t time.Time)

SetNextStart sets NextStart field of KernelChaos

func (*KernelChaos) SetupWebhookWithManager

func (in *KernelChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup KernelChaos's webhook with manager

func (*KernelChaos) Validate

func (in *KernelChaos) Validate() error

Validate validates chaos object

func (*KernelChaos) ValidateCreate

func (in *KernelChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*KernelChaos) ValidateDelete

func (in *KernelChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*KernelChaos) ValidatePodMode

func (in *KernelChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*KernelChaos) ValidateScheduler

func (in *KernelChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates the scheduler and duration

func (*KernelChaos) ValidateUpdate

func (in *KernelChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type KernelChaosList

KernelChaosList contains a list of KernelChaos

type KernelChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []KernelChaos `json:"items"`
}

func (*KernelChaosList) DeepCopy

func (in *KernelChaosList) DeepCopy() *KernelChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelChaosList.

func (*KernelChaosList) DeepCopyInto

func (in *KernelChaosList) DeepCopyInto(out *KernelChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KernelChaosList) DeepCopyObject

func (in *KernelChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*KernelChaosList) ListChaos

func (in *KernelChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of kernel chaos

type KernelChaosSpec

KernelChaosSpec defines the desired state of KernelChaos

type KernelChaosSpec struct {
    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // If `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // FailKernRequest defines the request of kernel injection
    FailKernRequest FailKernRequest `json:"failKernRequest"`

    // Duration represents the duration of the chaos action
    Duration *string `json:"duration,omitempty"`

    // Scheduler defines some schedule rules to control the running time of the chaos experiment about time.
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`
}

func (*KernelChaosSpec) DeepCopy

func (in *KernelChaosSpec) DeepCopy() *KernelChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelChaosSpec.

func (*KernelChaosSpec) DeepCopyInto

func (in *KernelChaosSpec) DeepCopyInto(out *KernelChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KernelChaosSpec) GetMode

func (in *KernelChaosSpec) GetMode() PodMode

GetMode is a getter for Mode (for implementing SelectSpec)

func (*KernelChaosSpec) GetSelector

func (in *KernelChaosSpec) GetSelector() SelectorSpec

GetSelector is a getter for Selector (for implementing SelectSpec)

func (*KernelChaosSpec) GetValue

func (in *KernelChaosSpec) GetValue() string

GetValue is a getter for Value (for implementing SelectSpec)

type KernelChaosStatus

KernelChaosStatus defines the observed state of KernelChaos

type KernelChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*KernelChaosStatus) DeepCopy

func (in *KernelChaosStatus) DeepCopy() *KernelChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KernelChaosStatus.

func (*KernelChaosStatus) DeepCopyInto

func (in *KernelChaosStatus) DeepCopyInto(out *KernelChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LossSpec

LossSpec defines detail of a loss action

type LossSpec struct {
    Loss        string `json:"loss"`
    Correlation string `json:"correlation"`
}

func (*LossSpec) DeepCopy

func (in *LossSpec) DeepCopy() *LossSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LossSpec.

func (*LossSpec) DeepCopyInto

func (in *LossSpec) DeepCopyInto(out *LossSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LossSpec) ToNetem

func (in *LossSpec) ToNetem() (*chaosdaemonpb.Netem, error)

ToNetem implements Netem interface.

type MemoryStressor

MemoryStressor defines how to stress memory out

type MemoryStressor struct {
    Stressor `json:",inline"`

    // extend stress-ng options
    // +optional
    Options []string `json:"options,omitempty"`
}

func (*MemoryStressor) DeepCopy

func (in *MemoryStressor) DeepCopy() *MemoryStressor

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemoryStressor.

func (*MemoryStressor) DeepCopyInto

func (in *MemoryStressor) DeepCopyInto(out *MemoryStressor)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MemoryStressor) Validate

func (in *MemoryStressor) Validate(parent *field.Path) field.ErrorList

Validate validates whether the MemoryStressor is well defined

type NetworkChaos

NetworkChaos is the Schema for the networkchaos API

type NetworkChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a pod chaos experiment
    Spec NetworkChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the chaos experiment about pods
    Status NetworkChaosStatus `json:"status"`
}

func (*NetworkChaos) DeepCopy

func (in *NetworkChaos) DeepCopy() *NetworkChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkChaos.

func (*NetworkChaos) DeepCopyInto

func (in *NetworkChaos) DeepCopyInto(out *NetworkChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NetworkChaos) DeepCopyObject

func (in *NetworkChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*NetworkChaos) Default

func (in *NetworkChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*NetworkChaos) GetChaos

func (in *NetworkChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*NetworkChaos) GetDuration

func (in *NetworkChaos) GetDuration() (*time.Duration, error)

GetDuration would return the duration for chaos

func (*NetworkChaos) GetNextRecover

func (in *NetworkChaos) GetNextRecover() time.Time

func (*NetworkChaos) GetNextStart

func (in *NetworkChaos) GetNextStart() time.Time

func (*NetworkChaos) GetScheduler

func (in *NetworkChaos) GetScheduler() *SchedulerSpec

GetScheduler would return the scheduler for chaos

func (*NetworkChaos) GetStatus

func (in *NetworkChaos) GetStatus() *ChaosStatus

func (*NetworkChaos) IsDeleted

func (in *NetworkChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*NetworkChaos) IsPaused

func (in *NetworkChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*NetworkChaos) SetNextRecover

func (in *NetworkChaos) SetNextRecover(t time.Time)

func (*NetworkChaos) SetNextStart

func (in *NetworkChaos) SetNextStart(t time.Time)

func (*NetworkChaos) SetupWebhookWithManager

func (in *NetworkChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup NetworkChaos's webhook with manager

func (*NetworkChaos) Validate

func (in *NetworkChaos) Validate() error

Validate validates chaos object

func (*NetworkChaos) ValidateCreate

func (in *NetworkChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*NetworkChaos) ValidateDelete

func (in *NetworkChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*NetworkChaos) ValidateExternalTargets

func (in *NetworkChaos) ValidateExternalTargets(target *field.Path) field.ErrorList

ValidateExternalTargets validates externalTargets must be with `to` direction

func (*NetworkChaos) ValidatePodMode

func (in *NetworkChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*NetworkChaos) ValidateScheduler

func (in *NetworkChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates the scheduler and duration

func (*NetworkChaos) ValidateUpdate

func (in *NetworkChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type NetworkChaosAction

ChaosAction represents the chaos action about pods.

type NetworkChaosAction string
const (
    // NetemAction is a combination of several chaos actions i.e. delay, loss, duplicate, corrupt.
    // When using this action multiple specs are merged into one Netem RPC and sends to chaos daemon.
    NetemAction NetworkChaosAction = "netem"

    // DelayAction represents the chaos action of adding delay on pods.
    DelayAction NetworkChaosAction = "delay"

    // LossAction represents the chaos action of losing packets on pods.
    LossAction NetworkChaosAction = "loss"

    // DuplicateAction represents the chaos action of duplicating packets on pods.
    DuplicateAction NetworkChaosAction = "duplicate"

    // CorruptAction represents the chaos action of corrupting packets on pods.
    CorruptAction NetworkChaosAction = "corrupt"

    // PartitionAction represents the chaos action of network partition of pods.
    PartitionAction NetworkChaosAction = "partition"

    // BandwidthAction represents the chaos action of network bandwidth of pods.
    BandwidthAction NetworkChaosAction = "bandwidth"
)

type NetworkChaosList

NetworkChaosList contains a list of NetworkChaos

type NetworkChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []NetworkChaos `json:"items"`
}

func (*NetworkChaosList) DeepCopy

func (in *NetworkChaosList) DeepCopy() *NetworkChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkChaosList.

func (*NetworkChaosList) DeepCopyInto

func (in *NetworkChaosList) DeepCopyInto(out *NetworkChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NetworkChaosList) DeepCopyObject

func (in *NetworkChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*NetworkChaosList) ListChaos

func (in *NetworkChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of network chaos

type NetworkChaosSpec

NetworkChaosSpec defines the desired state of NetworkChaos

type NetworkChaosSpec struct {
    // Action defines the specific network chaos action.
    // Supported action: partition, netem, delay, loss, duplicate, corrupt
    // Default action: delay
    // +kubebuilder:validation:Enum=netem;delay;loss;duplicate;corrupt;partition;bandwidth
    Action NetworkChaosAction `json:"action"`

    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // If `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // Duration represents the duration of the chaos action
    Duration *string `json:"duration,omitempty"`

    // Scheduler defines some schedule rules to control the running time of the chaos experiment about network.
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`

    // TcParameter represents the traffic control definition
    TcParameter `json:",inline"`

    // Direction represents the direction, this applies on netem and network partition action
    // +optional
    // +kubebuilder:validation:Enum=to;from;both;""
    Direction Direction `json:"direction,omitempty"`

    // Target represents network target, this applies on netem and network partition action
    // +optional
    Target *Target `json:"target,omitempty"`

    // ExternalTargets represents network targets outside k8s
    // +optional
    ExternalTargets []string `json:"externalTargets,omitempty"`
}

func (*NetworkChaosSpec) DeepCopy

func (in *NetworkChaosSpec) DeepCopy() *NetworkChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkChaosSpec.

func (*NetworkChaosSpec) DeepCopyInto

func (in *NetworkChaosSpec) DeepCopyInto(out *NetworkChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NetworkChaosSpec) DefaultDelay

func (in *NetworkChaosSpec) DefaultDelay()

DefaultDelay set the default value if Jitter or Correlation is not set

func (*NetworkChaosSpec) GetMode

func (in *NetworkChaosSpec) GetMode() PodMode

GetMode is a getter for Mode (for implementing SelectSpec)

func (*NetworkChaosSpec) GetSelector

func (in *NetworkChaosSpec) GetSelector() SelectorSpec

GetSelector is a getter for Selector (for implementing SelectSpec)

func (*NetworkChaosSpec) GetValue

func (in *NetworkChaosSpec) GetValue() string

GetValue is a getter for Value (for implementing SelectSpec)

type NetworkChaosStatus

NetworkChaosStatus defines the observed state of NetworkChaos

type NetworkChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*NetworkChaosStatus) DeepCopy

func (in *NetworkChaosStatus) DeepCopy() *NetworkChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NetworkChaosStatus.

func (*NetworkChaosStatus) DeepCopyInto

func (in *NetworkChaosStatus) DeepCopyInto(out *NetworkChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodChaos

PodChaos is the control script`s spec.

type PodChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a pod chaos experiment
    Spec PodChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the chaos experiment about pods
    Status PodChaosStatus `json:"status"`
}

func (*PodChaos) DeepCopy

func (in *PodChaos) DeepCopy() *PodChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodChaos.

func (*PodChaos) DeepCopyInto

func (in *PodChaos) DeepCopyInto(out *PodChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodChaos) DeepCopyObject

func (in *PodChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PodChaos) Default

func (in *PodChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*PodChaos) GetChaos

func (in *PodChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*PodChaos) GetDuration

func (in *PodChaos) GetDuration() (*time.Duration, error)

GetDuration would return the duration for chaos

func (*PodChaos) GetNextRecover

func (in *PodChaos) GetNextRecover() time.Time

func (*PodChaos) GetNextStart

func (in *PodChaos) GetNextStart() time.Time

func (*PodChaos) GetScheduler

func (in *PodChaos) GetScheduler() *SchedulerSpec

GetScheduler would return the scheduler for chaos

func (*PodChaos) GetStatus

func (in *PodChaos) GetStatus() *ChaosStatus

func (*PodChaos) IsDeleted

func (in *PodChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*PodChaos) IsPaused

func (in *PodChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*PodChaos) SetNextRecover

func (in *PodChaos) SetNextRecover(t time.Time)

func (*PodChaos) SetNextStart

func (in *PodChaos) SetNextStart(t time.Time)

func (*PodChaos) SetupWebhookWithManager

func (in *PodChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup PodChaos's webhook with manager

func (*PodChaos) Validate

func (in *PodChaos) Validate() error

Validate validates chaos object

func (*PodChaos) ValidateCreate

func (in *PodChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*PodChaos) ValidateDelete

func (in *PodChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*PodChaos) ValidatePodMode

func (in *PodChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*PodChaos) ValidateScheduler

func (in *PodChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates the scheduler and duration

func (*PodChaos) ValidateUpdate

func (in *PodChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type PodChaosAction

PodChaosAction represents the chaos action about pods.

type PodChaosAction string
const (
    // PodKillAction represents the chaos action of killing pods.
    PodKillAction PodChaosAction = "pod-kill"
    // PodFailureAction represents the chaos action of injecting errors to pods.
    // This action will cause the pod to not be created for a while.
    PodFailureAction PodChaosAction = "pod-failure"
    // ContainerKillAction represents the chaos action of killing the container
    ContainerKillAction PodChaosAction = "container-kill"
)

type PodChaosList

PodChaosList is PodChaos list.

type PodChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata"`

    Items []PodChaos `json:"items"`
}

func (*PodChaosList) DeepCopy

func (in *PodChaosList) DeepCopy() *PodChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodChaosList.

func (*PodChaosList) DeepCopyInto

func (in *PodChaosList) DeepCopyInto(out *PodChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodChaosList) DeepCopyObject

func (in *PodChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PodChaosList) ListChaos

func (in *PodChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of pod chaos

type PodChaosSpec

PodChaosSpec defines the attributes that a user creates on a chaos experiment about pods.

type PodChaosSpec struct {
    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // Scheduler defines some schedule rules to
    // control the running time of the chaos experiment about pods.
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`

    // Action defines the specific pod chaos action.
    // Supported action: pod-kill / pod-failure / container-kill
    // Default action: pod-kill
    // +kubebuilder:validation:Enum=pod-kill;pod-failure;container-kill
    Action PodChaosAction `json:"action"`

    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // IF `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Duration represents the duration of the chaos action.
    // It is required when the action is `PodFailureAction`.
    // A duration string is a possibly signed sequence of
    // decimal numbers, each with optional fraction and a unit suffix,
    // such as "300ms", "-1.5h" or "2h45m".
    // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    // +optional
    Duration *string `json:"duration,omitempty"`

    // ContainerName indicates the name of the container.
    // Needed in container-kill.
    // +optional
    ContainerName string `json:"containerName"`

    // GracePeriod is used in pod-kill action. It represents the duration in seconds before the pod should be deleted.
    // Value must be non-negative integer. The default value is zero that indicates delete immediately.
    // +optional
    // +kubebuilder:validation:Minimum=0
    GracePeriod int64 `json:"gracePeriod"`
}

func (*PodChaosSpec) DeepCopy

func (in *PodChaosSpec) DeepCopy() *PodChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodChaosSpec.

func (*PodChaosSpec) DeepCopyInto

func (in *PodChaosSpec) DeepCopyInto(out *PodChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodChaosSpec) GetMode

func (in *PodChaosSpec) GetMode() PodMode

func (*PodChaosSpec) GetSelector

func (in *PodChaosSpec) GetSelector() SelectorSpec

func (*PodChaosSpec) GetValue

func (in *PodChaosSpec) GetValue() string

type PodChaosStatus

PodChaosStatus represents the current status of the chaos experiment about pods.

type PodChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*PodChaosStatus) DeepCopy

func (in *PodChaosStatus) DeepCopy() *PodChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodChaosStatus.

func (*PodChaosStatus) DeepCopyInto

func (in *PodChaosStatus) DeepCopyInto(out *PodChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodIoChaos

PodIoChaos is the Schema for the podiochaos API

type PodIoChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    Spec PodIoChaosSpec `json:"spec,omitempty"`
}

func (*PodIoChaos) DeepCopy

func (in *PodIoChaos) DeepCopy() *PodIoChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIoChaos.

func (*PodIoChaos) DeepCopyInto

func (in *PodIoChaos) DeepCopyInto(out *PodIoChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodIoChaos) DeepCopyObject

func (in *PodIoChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PodIoChaos) SetupWebhookWithManager

func (in *PodIoChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup PodIoChaos's webhook with manager

type PodIoChaosHandler

PodIoChaosHandler represents the implementation of podiochaos

type PodIoChaosHandler interface {
    Apply(context.Context, *PodIoChaos) error
}

type PodIoChaosList

PodIoChaosList contains a list of PodIoChaos

type PodIoChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []PodIoChaos `json:"items"`
}

func (*PodIoChaosList) DeepCopy

func (in *PodIoChaosList) DeepCopy() *PodIoChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIoChaosList.

func (*PodIoChaosList) DeepCopyInto

func (in *PodIoChaosList) DeepCopyInto(out *PodIoChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodIoChaosList) DeepCopyObject

func (in *PodIoChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PodIoChaosSpec

PodIoChaosSpec defines the desired state of IoChaos

type PodIoChaosSpec struct {
    // VolumeMountPath represents the target mount path
    // It must be a root of mount path now.
    // TODO: search the mount parent of any path automatically.
    // TODO: support multiple different volume mount path in one pod
    VolumeMountPath string `json:"volumeMountPath"`

    // Pid represents a running toda process id
    // +optional
    Pid int64 `json:"pid,omitempty"`

    // StartTime represents the start time of a toda process
    // +optional
    StartTime int64 `json:"startTime,omitempty"`

    // Actions are a list of IoChaos actions
    // +optional
    Actions []IoChaosAction `json:"actions,omitempty"`
}

func (*PodIoChaosSpec) DeepCopy

func (in *PodIoChaosSpec) DeepCopy() *PodIoChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIoChaosSpec.

func (*PodIoChaosSpec) DeepCopyInto

func (in *PodIoChaosSpec) DeepCopyInto(out *PodIoChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodIoChaosWebhookRunner

PodIoChaosWebhookRunner runs webhook for podiochaos

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

func (*PodIoChaosWebhookRunner) Handle

func (r *PodIoChaosWebhookRunner) Handle(ctx context.Context, req admission.Request) admission.Response

Handle will run poiochaoshandler for this resource

func (*PodIoChaosWebhookRunner) InjectDecoder

func (r *PodIoChaosWebhookRunner) InjectDecoder(d *admission.Decoder) error

InjectDecoder injects decoder into webhook runner

type PodMode

PodMode represents the mode to run pod chaos action.

type PodMode string
const (
    // OnePodMode represents that the system will do the chaos action on one pod selected randomly.
    OnePodMode PodMode = "one"
    // AllPodMode represents that the system will do the chaos action on all pods
    // regardless of status (not ready or not running pods includes).
    // Use this label carefully.
    AllPodMode PodMode = "all"
    // FixedPodMode represents that the system will do the chaos action on a specific number of running pods.
    FixedPodMode PodMode = "fixed"
    // FixedPercentPodMode to specify a fixed % that can be inject chaos action.
    FixedPercentPodMode PodMode = "fixed-percent"
    // RandomMaxPercentPodMode to specify a maximum % that can be inject chaos action.
    RandomMaxPercentPodMode PodMode = "random-max-percent"
)

type PodNetworkChaos

PodNetworkChaos is the Schema for the PodNetworkChaos API

type PodNetworkChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a pod chaos experiment
    Spec PodNetworkChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the chaos experiment about pods
    Status PodNetworkChaosStatus `json:"status"`
}

func (*PodNetworkChaos) DeepCopy

func (in *PodNetworkChaos) DeepCopy() *PodNetworkChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodNetworkChaos.

func (*PodNetworkChaos) DeepCopyInto

func (in *PodNetworkChaos) DeepCopyInto(out *PodNetworkChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodNetworkChaos) DeepCopyObject

func (in *PodNetworkChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PodNetworkChaos) Default

func (in *PodNetworkChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*PodNetworkChaos) GetChaos

func (in *PodNetworkChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*PodNetworkChaos) GetStatus

func (in *PodNetworkChaos) GetStatus() *ChaosStatus

GetStatus returns the status of chaos

func (*PodNetworkChaos) SetupWebhookWithManager

func (in *PodNetworkChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup PodNetworkChaos's webhook with manager

func (*PodNetworkChaos) ValidateCreate

func (in *PodNetworkChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*PodNetworkChaos) ValidateDelete

func (in *PodNetworkChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*PodNetworkChaos) ValidateUpdate

func (in *PodNetworkChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type PodNetworkChaosHandler

PodNetworkChaosHandler represents the implementation of podnetworkchaos

type PodNetworkChaosHandler interface {
    Apply(context.Context, *PodNetworkChaos) error
}

type PodNetworkChaosList

PodNetworkChaosList contains a list of PodNetworkChaos

type PodNetworkChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []PodNetworkChaos `json:"items"`
}

func (*PodNetworkChaosList) DeepCopy

func (in *PodNetworkChaosList) DeepCopy() *PodNetworkChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodNetworkChaosList.

func (*PodNetworkChaosList) DeepCopyInto

func (in *PodNetworkChaosList) DeepCopyInto(out *PodNetworkChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PodNetworkChaosList) DeepCopyObject

func (in *PodNetworkChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PodNetworkChaosList) ListChaos

func (in *PodNetworkChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of network chaos

type PodNetworkChaosSpec

PodNetworkChaosSpec defines the desired state of PodNetworkChaos

type PodNetworkChaosSpec struct {
    // The ipset on the pod
    // +optional
    IPSets []RawIPSet `json:"ipsets,omitempty"`

    // The iptables rules on the pod
    // +optional
    Iptables []RawIptables `json:"iptables,omitempty"`

    // The tc rules on the pod
    // +optional
    TrafficControls []RawTrafficControl `json:"tcs,omitempty"`
}

func (*PodNetworkChaosSpec) DeepCopy

func (in *PodNetworkChaosSpec) DeepCopy() *PodNetworkChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodNetworkChaosSpec.

func (*PodNetworkChaosSpec) DeepCopyInto

func (in *PodNetworkChaosSpec) DeepCopyInto(out *PodNetworkChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodNetworkChaosStatus

PodNetworkChaosStatus defines the observed state of PodNetworkChaos

type PodNetworkChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*PodNetworkChaosStatus) DeepCopy

func (in *PodNetworkChaosStatus) DeepCopy() *PodNetworkChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodNetworkChaosStatus.

func (*PodNetworkChaosStatus) DeepCopyInto

func (in *PodNetworkChaosStatus) DeepCopyInto(out *PodNetworkChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PodStatus

PodStatus represents information about the status of a pod in chaos experiment.

type PodStatus struct {
    Namespace string `json:"namespace"`
    Name      string `json:"name"`
    Action    string `json:"action"`
    HostIP    string `json:"hostIP"`
    PodIP     string `json:"podIP"`

    // A brief CamelCase message indicating details about the chaos action.
    // e.g. "delete this pod" or "pause this pod duration 5m"
    // +optional
    Message string `json:"message"`
}

func (*PodStatus) DeepCopy

func (in *PodStatus) DeepCopy() *PodStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodStatus.

func (*PodStatus) DeepCopyInto

func (in *PodStatus) DeepCopyInto(out *PodStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RawIPSet

RawIPSet represents an ipset on specific pod

type RawIPSet struct {
    // The name of ipset
    Name string `json:"name"`

    // The contents of ipset
    Cidrs []string `json:"cidrs"`

    // The name and namespace of the source network chaos
    RawRuleSource `json:",inline"`
}

func (*RawIPSet) DeepCopy

func (in *RawIPSet) DeepCopy() *RawIPSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RawIPSet.

func (*RawIPSet) DeepCopyInto

func (in *RawIPSet) DeepCopyInto(out *RawIPSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RawIptables

RawIptables represents the iptables rules on specific pod

type RawIptables struct {
    // The name of iptables chain
    Name string `json:"name"`

    // The name of related ipset
    IPSets []string `json:"ipsets"`

    // The block direction of this iptables rule
    Direction ChainDirection `json:"direction"`

    RawRuleSource `json:",inline"`
}

func (*RawIptables) DeepCopy

func (in *RawIptables) DeepCopy() *RawIptables

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RawIptables.

func (*RawIptables) DeepCopyInto

func (in *RawIptables) DeepCopyInto(out *RawIptables)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RawRuleSource

RawRuleSource represents the name and namespace of the source network chaos

type RawRuleSource struct {
    Source string `json:"source"`
}

func (*RawRuleSource) DeepCopy

func (in *RawRuleSource) DeepCopy() *RawRuleSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RawRuleSource.

func (*RawRuleSource) DeepCopyInto

func (in *RawRuleSource) DeepCopyInto(out *RawRuleSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RawTrafficControl

RawTrafficControl represents the traffic control chaos on specific pod

type RawTrafficControl struct {
    // The type of traffic control
    Type TcType `json:"type"`

    TcParameter `json:",inline"`

    // The name of target ipset
    // +optional
    IPSet string `json:"ipset,omitempty"`

    // The name and namespace of the source network chaos
    Source string `json:"source"`
}

func (*RawTrafficControl) DeepCopy

func (in *RawTrafficControl) DeepCopy() *RawTrafficControl

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RawTrafficControl.

func (*RawTrafficControl) DeepCopyInto

func (in *RawTrafficControl) DeepCopyInto(out *RawTrafficControl)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ReorderSpec

ReorderSpec defines details of packet reorder.

type ReorderSpec struct {
    Reorder     string `json:"reorder"`
    Correlation string `json:"correlation"`
    Gap         int    `json:"gap"`
}

func (*ReorderSpec) DeepCopy

func (in *ReorderSpec) DeepCopy() *ReorderSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReorderSpec.

func (*ReorderSpec) DeepCopyInto

func (in *ReorderSpec) DeepCopyInto(out *ReorderSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScheduleStatus

ScheduleStatus is the current status of chaos scheduler.

type ScheduleStatus struct {
    // Next time when this action will be applied again
    // +optional
    NextStart *metav1.Time `json:"nextStart,omitempty"`

    // Next time when this action will be recovered
    // +optional
    NextRecover *metav1.Time `json:"nextRecover,omitempty"`
}

func (*ScheduleStatus) DeepCopy

func (in *ScheduleStatus) DeepCopy() *ScheduleStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScheduleStatus.

func (*ScheduleStatus) DeepCopyInto

func (in *ScheduleStatus) DeepCopyInto(out *ScheduleStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SchedulerSpec

SchedulerSpec defines information about schedule of the chaos experiment.

type SchedulerSpec struct {
    // Cron defines a cron job rule.
    //
    // Some rule examples:
    // "0 30 * * * *" means to "Every hour on the half hour"
    // "@hourly"      means to "Every hour"
    // "@every 1h30m" means to "Every hour thirty"
    //
    // More rule info: https://godoc.org/github.com/robfig/cron
    Cron string `json:"cron"`
}

func (*SchedulerSpec) DeepCopy

func (in *SchedulerSpec) DeepCopy() *SchedulerSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulerSpec.

func (*SchedulerSpec) DeepCopyInto

func (in *SchedulerSpec) DeepCopyInto(out *SchedulerSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SelectorSpec

SelectorSpec defines the some selectors to select objects. If the all selectors are empty, all objects will be used in chaos experiment.

type SelectorSpec struct {
    // Namespaces is a set of namespace to which objects belong.
    // +optional
    Namespaces []string `json:"namespaces,omitempty"`

    // Nodes is a set of node name and objects must belong to these nodes.
    // +optional
    Nodes []string `json:"nodes,omitempty"`

    // Pods is a map of string keys and a set values that used to select pods.
    // The key defines the namespace which pods belong,
    // and the each values is a set of pod names.
    // +optional
    Pods map[string][]string `json:"pods,omitempty"`

    // Map of string keys and values that can be used to select nodes.
    // Selector which must match a node's labels,
    // and objects must belong to these selected nodes.
    // +optional
    NodeSelectors map[string]string `json:"nodeSelectors,omitempty"`

    // Map of string keys and values that can be used to select objects.
    // A selector based on fields.
    // +optional
    FieldSelectors map[string]string `json:"fieldSelectors,omitempty"`

    // Map of string keys and values that can be used to select objects.
    // A selector based on labels.
    // +optional
    LabelSelectors map[string]string `json:"labelSelectors,omitempty"`

    // Map of string keys and values that can be used to select objects.
    // A selector based on annotations.
    // +optional
    AnnotationSelectors map[string]string `json:"annotationSelectors,omitempty"`

    // PodPhaseSelectors is a set of condition of a pod at the current time.
    // supported value: Pending / Running / Succeeded / Failed / Unknown
    // +optional
    PodPhaseSelectors []string `json:"podPhaseSelectors,omitempty"`
}

func (*SelectorSpec) DeepCopy

func (in *SelectorSpec) DeepCopy() *SelectorSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SelectorSpec.

func (*SelectorSpec) DeepCopyInto

func (in *SelectorSpec) DeepCopyInto(out *SelectorSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*SelectorSpec) DefaultNamespace

func (in *SelectorSpec) DefaultNamespace(namespace string)

DefaultNamespace set the namespace of chaos object as the default namespace selector if namespaces not set

type StatefulObject

StatefulObject defines a basic Object that can get the status

type StatefulObject interface {
    runtime.Object
    GetStatus() *ChaosStatus
}

type StressChaos

StressChaos is the Schema for the stresschaos API

type StressChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a time chaos experiment
    Spec StressChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the time chaos experiment
    Status StressChaosStatus `json:"status"`
}

func (*StressChaos) DeepCopy

func (in *StressChaos) DeepCopy() *StressChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StressChaos.

func (*StressChaos) DeepCopyInto

func (in *StressChaos) DeepCopyInto(out *StressChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*StressChaos) DeepCopyObject

func (in *StressChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*StressChaos) Default

func (in *StressChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*StressChaos) GetChaos

func (in *StressChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*StressChaos) GetDuration

func (in *StressChaos) GetDuration() (*time.Duration, error)

GetDuration gets the duration of StressChaos

func (*StressChaos) GetNextRecover

func (in *StressChaos) GetNextRecover() time.Time

GetNextRecover get NextRecover field of StressChaos

func (*StressChaos) GetNextStart

func (in *StressChaos) GetNextStart() time.Time

GetNextStart gets NextStart field of StressChaos

func (*StressChaos) GetScheduler

func (in *StressChaos) GetScheduler() *SchedulerSpec

GetScheduler returns the scheduler of StressChaos

func (*StressChaos) GetStatus

func (in *StressChaos) GetStatus() *ChaosStatus

GetStatus returns the status of StressChaos

func (*StressChaos) IsDeleted

func (in *StressChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*StressChaos) IsPaused

func (in *StressChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*StressChaos) SetNextRecover

func (in *StressChaos) SetNextRecover(t time.Time)

SetNextRecover sets NextRecover field of StressChaos

func (*StressChaos) SetNextStart

func (in *StressChaos) SetNextStart(t time.Time)

SetNextStart sets NextStart field of StressChaos

func (*StressChaos) SetupWebhookWithManager

func (in *StressChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setups StressChaos's webhook with manager

func (*StressChaos) Validate

func (in *StressChaos) Validate() error

Validate validates chaos object

func (*StressChaos) ValidateCreate

func (in *StressChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*StressChaos) ValidateDelete

func (in *StressChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*StressChaos) ValidatePodMode

func (in *StressChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*StressChaos) ValidateScheduler

func (in *StressChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates whether scheduler is well defined

func (*StressChaos) ValidateUpdate

func (in *StressChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type StressChaosList

StressChaosList contains a list of StressChaos

type StressChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []StressChaos `json:"items"`
}

func (*StressChaosList) DeepCopy

func (in *StressChaosList) DeepCopy() *StressChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StressChaosList.

func (*StressChaosList) DeepCopyInto

func (in *StressChaosList) DeepCopyInto(out *StressChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*StressChaosList) DeepCopyObject

func (in *StressChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*StressChaosList) ListChaos

func (in *StressChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of stress chaos

type StressChaosSpec

StressChaosSpec defines the desired state of StressChaos

type StressChaosSpec struct {
    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the max % of pods the server can do chaos action.
    // If `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the % of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // Stressors defines plenty of stressors supported to stress system components out.
    // You can use one or more of them to make up various kinds of stresses. At least
    // one of the stressors should be specified.
    // +optional
    Stressors *Stressors `json:"stressors,omitempty"`

    // StressngStressors defines plenty of stressors just like `Stressors` except that it's an experimental
    // feature and more powerful. You can define stressors in `stress-ng` (see also `man stress-ng`) dialect,
    // however not all of the supported stressors are well tested. It maybe retired in later releases. You
    // should always use `Stressors` to define the stressors and use this only when you want more stressors
    // unsupported by `Stressors`. When both `StressngStressors` and `Stressors` are defined, `StressngStressors`
    // wins.
    // +optional
    StressngStressors string `json:"stressngStressors,omitempty"`

    // ContainerName indicates the target container to inject stress in
    // +optional
    ContainerName *string `json:"containerName,omitempty"`

    // Duration represents the duration of the chaos action
    // +optional
    Duration *string `json:"duration,omitempty"`

    // Scheduler defines some schedule rules to control the running time of the chaos experiment about time.
    // +optional
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`
}

func (*StressChaosSpec) DeepCopy

func (in *StressChaosSpec) DeepCopy() *StressChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StressChaosSpec.

func (*StressChaosSpec) DeepCopyInto

func (in *StressChaosSpec) DeepCopyInto(out *StressChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*StressChaosSpec) GetMode

func (in *StressChaosSpec) GetMode() PodMode

GetMode is a getter for Mode (for implementing SelectSpec)

func (*StressChaosSpec) GetSelector

func (in *StressChaosSpec) GetSelector() SelectorSpec

GetSelector is a getter for Selector (for implementing SelectSpec)

func (*StressChaosSpec) GetValue

func (in *StressChaosSpec) GetValue() string

GetValue is a getter for Value (for implementing SelectSpec)

func (*StressChaosSpec) Validate

func (in *StressChaosSpec) Validate(parent *field.Path) field.ErrorList

Validate validates the scheduler and duration

type StressChaosStatus

StressChaosStatus defines the observed state of StressChaos

type StressChaosStatus struct {
    ChaosStatus `json:",inline"`
    // Instances always specifies stressing instances
    // +optional
    Instances map[string]StressInstance `json:"instances,omitempty"`
}

func (*StressChaosStatus) DeepCopy

func (in *StressChaosStatus) DeepCopy() *StressChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StressChaosStatus.

func (*StressChaosStatus) DeepCopyInto

func (in *StressChaosStatus) DeepCopyInto(out *StressChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type StressInstance

StressInstance is an instance generates stresses

type StressInstance struct {
    // UID is the instance identifier
    // +optional
    UID string `json:"uid"`
    // StartTime specifies when the instance starts
    // +optional
    StartTime *metav1.Time `json:"startTime"`
}

func (*StressInstance) DeepCopy

func (in *StressInstance) DeepCopy() *StressInstance

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StressInstance.

func (*StressInstance) DeepCopyInto

func (in *StressInstance) DeepCopyInto(out *StressInstance)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Stressor

Stressor defines common configurations of a stressor

type Stressor struct {
    // Workers specifies N workers to apply the stressor.
    Workers int `json:"workers"`
}

func (*Stressor) DeepCopy

func (in *Stressor) DeepCopy() *Stressor

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Stressor.

func (*Stressor) DeepCopyInto

func (in *Stressor) DeepCopyInto(out *Stressor)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Stressor) Validate

func (in *Stressor) Validate(parent *field.Path) field.ErrorList

Validate validates whether the Stressor is well defined

type Stressors

Stressors defines plenty of stressors supported to stress system components out. You can use one or more of them to make up various kinds of stresses

type Stressors struct {
    // MemoryStressor stresses virtual memory out
    // +optional
    MemoryStressor *MemoryStressor `json:"memory,omitempty"`
    // CPUStressor stresses CPU out
    // +optional
    CPUStressor *CPUStressor `json:"cpu,omitempty"`
}

func (*Stressors) DeepCopy

func (in *Stressors) DeepCopy() *Stressors

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Stressors.

func (*Stressors) DeepCopyInto

func (in *Stressors) DeepCopyInto(out *Stressors)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Stressors) Normalize

func (in *Stressors) Normalize() (string, error)

Normalize the stressors to comply with stress-ng

func (*Stressors) Validate

func (in *Stressors) Validate(parent *field.Path) field.ErrorList

Validate validates whether the Stressors are all well defined

type Target

Target represents network partition and netem action target.

type Target struct {
    // TargetSelector defines the target selector
    TargetSelector SelectorSpec `json:"selector"`

    // TargetMode defines the target selector mode
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent;""
    TargetMode PodMode `json:"mode"`

    // TargetValue is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // If `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    TargetValue string `json:"value"`
}

func (*Target) DeepCopy

func (in *Target) DeepCopy() *Target

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Target.

func (*Target) DeepCopyInto

func (in *Target) DeepCopyInto(out *Target)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Target) GetMode

func (in *Target) GetMode() PodMode

GetMode is a getter for Mode (for implementing SelectSpec)

func (*Target) GetSelector

func (in *Target) GetSelector() SelectorSpec

GetSelector is a getter for Selector (for implementing SelectSpec)

func (*Target) GetValue

func (in *Target) GetValue() string

GetValue is a getter for Value (for implementing SelectSpec)

type TcParameter

TcParameter represents the parameters for a traffic control chaos

type TcParameter struct {
    // Delay represents the detail about delay action
    // +optional
    Delay *DelaySpec `json:"delay,omitempty"`

    // Loss represents the detail about loss action
    // +optional
    Loss *LossSpec `json:"loss,omitempty"`

    // DuplicateSpec represents the detail about loss action
    // +optional
    Duplicate *DuplicateSpec `json:"duplicate,omitempty"`

    // Corrupt represents the detail about corrupt action
    // +optional
    Corrupt *CorruptSpec `json:"corrupt,omitempty"`

    // Bandwidth represents the detail about bandwidth control action
    // +optional
    Bandwidth *BandwidthSpec `json:"bandwidth,omitempty"`
}

func (*TcParameter) DeepCopy

func (in *TcParameter) DeepCopy() *TcParameter

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TcParameter.

func (*TcParameter) DeepCopyInto

func (in *TcParameter) DeepCopyInto(out *TcParameter)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TcType

TcType the type of traffic control

type TcType string
const (
    // Netem represents netem traffic control
    Netem TcType = "netem"

    // Bandwidth represents bandwidth shape traffic control
    Bandwidth TcType = "bandwidth"
)

type TimeChaos

TimeChaos is the Schema for the timechaos API

type TimeChaos struct {
    metav1.TypeMeta   `json:",inline"`
    metav1.ObjectMeta `json:"metadata,omitempty"`

    // Spec defines the behavior of a time chaos experiment
    Spec TimeChaosSpec `json:"spec"`

    // +optional
    // Most recently observed status of the time chaos experiment
    Status TimeChaosStatus `json:"status"`
}

func (*TimeChaos) DeepCopy

func (in *TimeChaos) DeepCopy() *TimeChaos

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TimeChaos.

func (*TimeChaos) DeepCopyInto

func (in *TimeChaos) DeepCopyInto(out *TimeChaos)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TimeChaos) DeepCopyObject

func (in *TimeChaos) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*TimeChaos) Default

func (in *TimeChaos) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*TimeChaos) GetChaos

func (in *TimeChaos) GetChaos() *ChaosInstance

GetChaos returns a chaos instance

func (*TimeChaos) GetDuration

func (in *TimeChaos) GetDuration() (*time.Duration, error)

GetDuration gets the duration of TimeChaos

func (*TimeChaos) GetNextRecover

func (in *TimeChaos) GetNextRecover() time.Time

GetNextRecover get NextRecover field of TimeChaos

func (*TimeChaos) GetNextStart

func (in *TimeChaos) GetNextStart() time.Time

GetNextStart gets NextStart field of TimeChaos

func (*TimeChaos) GetScheduler

func (in *TimeChaos) GetScheduler() *SchedulerSpec

GetScheduler returns the scheduler of TimeChaos

func (*TimeChaos) GetStatus

func (in *TimeChaos) GetStatus() *ChaosStatus

GetStatus returns the status of TimeChaos

func (*TimeChaos) IsDeleted

func (in *TimeChaos) IsDeleted() bool

IsDeleted returns whether this resource has been deleted

func (*TimeChaos) IsPaused

func (in *TimeChaos) IsPaused() bool

IsPaused returns whether this resource has been paused

func (*TimeChaos) SetDefaultValue

func (in *TimeChaos) SetDefaultValue()

SetDefaultValue will set default value for empty fields

func (*TimeChaos) SetNextRecover

func (in *TimeChaos) SetNextRecover(t time.Time)

SetNextRecover sets NextRecover field of TimeChaos

func (*TimeChaos) SetNextStart

func (in *TimeChaos) SetNextStart(t time.Time)

SetNextStart sets NextStart field of TimeChaos

func (*TimeChaos) SetupWebhookWithManager

func (in *TimeChaos) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager setup TimeChaos's webhook with manager

func (*TimeChaos) Validate

func (in *TimeChaos) Validate() error

Validate validates chaos object

func (*TimeChaos) ValidateCreate

func (in *TimeChaos) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*TimeChaos) ValidateDelete

func (in *TimeChaos) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*TimeChaos) ValidatePodMode

func (in *TimeChaos) ValidatePodMode(spec *field.Path) field.ErrorList

ValidatePodMode validates the value with podmode

func (*TimeChaos) ValidateScheduler

func (in *TimeChaos) ValidateScheduler(spec *field.Path) field.ErrorList

ValidateScheduler validates the scheduler and duration

func (*TimeChaos) ValidateUpdate

func (in *TimeChaos) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type TimeChaosList

TimeChaosList contains a list of TimeChaos

type TimeChaosList struct {
    metav1.TypeMeta `json:",inline"`
    metav1.ListMeta `json:"metadata,omitempty"`
    Items           []TimeChaos `json:"items"`
}

func (*TimeChaosList) DeepCopy

func (in *TimeChaosList) DeepCopy() *TimeChaosList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TimeChaosList.

func (*TimeChaosList) DeepCopyInto

func (in *TimeChaosList) DeepCopyInto(out *TimeChaosList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TimeChaosList) DeepCopyObject

func (in *TimeChaosList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*TimeChaosList) ListChaos

func (in *TimeChaosList) ListChaos() []*ChaosInstance

ListChaos returns a list of time chaos

type TimeChaosSpec

TimeChaosSpec defines the desired state of TimeChaos

type TimeChaosSpec struct {
    // Mode defines the mode to run chaos action.
    // Supported mode: one / all / fixed / fixed-percent / random-max-percent
    // +kubebuilder:validation:Enum=one;all;fixed;fixed-percent;random-max-percent
    Mode PodMode `json:"mode"`

    // Value is required when the mode is set to `FixedPodMode` / `FixedPercentPodMod` / `RandomMaxPercentPodMod`.
    // If `FixedPodMode`, provide an integer of pods to do chaos action.
    // If `FixedPercentPodMod`, provide a number from 0-100 to specify the percent of pods the server can do chaos action.
    // If `RandomMaxPercentPodMod`,  provide a number from 0-100 to specify the max percent of pods to do chaos action
    // +optional
    Value string `json:"value"`

    // Selector is used to select pods that are used to inject chaos action.
    Selector SelectorSpec `json:"selector"`

    // TimeOffset defines the delta time of injected program. It's a possibly signed sequence of decimal numbers, such as
    // "300ms", "-1.5h" or "2h45m". Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    TimeOffset string `json:"timeOffset"`

    // ClockIds defines all affected clock id
    // All available options are ["CLOCK_REALTIME","CLOCK_MONOTONIC","CLOCK_PROCESS_CPUTIME_ID","CLOCK_THREAD_CPUTIME_ID",
    // "CLOCK_MONOTONIC_RAW","CLOCK_REALTIME_COARSE","CLOCK_MONOTONIC_COARSE","CLOCK_BOOTTIME","CLOCK_REALTIME_ALARM",
    // "CLOCK_BOOTTIME_ALARM"]
    // Default value is ["CLOCK_REALTIME"]
    ClockIds []string `json:"clockIds,omitempty"`

    // ContainerName indicates the name of affected container.
    // If not set, all containers will be injected
    // +optional
    ContainerNames []string `json:"containerNames,omitempty"`

    // Duration represents the duration of the chaos action
    Duration *string `json:"duration,omitempty"`

    // Scheduler defines some schedule rules to control the running time of the chaos experiment about time.
    Scheduler *SchedulerSpec `json:"scheduler,omitempty"`
}

func (*TimeChaosSpec) DeepCopy

func (in *TimeChaosSpec) DeepCopy() *TimeChaosSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TimeChaosSpec.

func (*TimeChaosSpec) DeepCopyInto

func (in *TimeChaosSpec) DeepCopyInto(out *TimeChaosSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TimeChaosSpec) DefaultClockIds

func (in *TimeChaosSpec) DefaultClockIds()

DefaultClockIds will set default value for empty ClockIds fields

func (*TimeChaosSpec) GetMode

func (in *TimeChaosSpec) GetMode() PodMode

GetMode is a getter for Mode (for implementing SelectSpec)

func (*TimeChaosSpec) GetSelector

func (in *TimeChaosSpec) GetSelector() SelectorSpec

GetSelector is a getter for Selector (for implementing SelectSpec)

func (*TimeChaosSpec) GetValue

func (in *TimeChaosSpec) GetValue() string

GetValue is a getter for Value (for implementing SelectSpec)

type TimeChaosStatus

TimeChaosStatus defines the observed state of TimeChaos

type TimeChaosStatus struct {
    ChaosStatus `json:",inline"`
}

func (*TimeChaosStatus) DeepCopy

func (in *TimeChaosStatus) DeepCopy() *TimeChaosStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TimeChaosStatus.

func (*TimeChaosStatus) DeepCopyInto

func (in *TimeChaosStatus) DeepCopyInto(out *TimeChaosStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Timespec

Timespec represents a time

type Timespec struct {
    Sec  int64 `json:"sec"`
    Nsec int64 `json:"nsec"`
}

func (*Timespec) DeepCopy

func (in *Timespec) DeepCopy() *Timespec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Timespec.

func (*Timespec) DeepCopyInto

func (in *Timespec) DeepCopyInto(out *Timespec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Validateable

Validateable defines how a resource is validated

type Validateable interface {
    Validate(parent *field.Path) field.ErrorList
}