Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Latest commit

 

History

History
269 lines (250 loc) · 6.51 KB

chaosschedule-concepts.md

File metadata and controls

269 lines (250 loc) · 6.51 KB
id title sidebar_label
chaosschedule
Constructing the ChaosSchedule
ChaosSchedule

The ChaosSchedule is the user-facing chaos custom resource with a namespace scope and is designed to hold information around how the ChaosEngines are to be scheduled according to the specified template. It schedules a chaosengine instance .

This section describes the fields in the ChaosSchedule spec and the possible values that can be set against the same.

Note - This is the alpha version of ChaosScheduler. An enhanced version may be released in the future based on the user reviews

Schedule Specification

Schedule NOW

Field .spec.schedule.now
Description Flag to control the type of scheduling
Type Mandatory
Range true, false
Default n/a
Notes The now in the spec.schedule ensures immediate creation of chaosengine, i.e., injection of chaos.

Schedule Once

Field .spec.schedule.once.executionTime
Description Flag to specify execution timestamp at which chaos is injected, when the policy is once. The chaosengine is created exactly at this timestamp.
Type Mandatory
Range user-defined (type: UTC Timeformat)
Default n/a
Notes .spec.schedule.once refers to a single-instance execution of chaos at a particular timestamp specified by .spec.schedule.once.executionTime

Schedule Repeat

Field .spec.schedule.repeat.timeRange.startTime
Description Flag to specify start timestamp of the range within which chaos is injected, when the policy is repeat. The chaosengine is not created before this timestamp.
Type Mandatory
Range user-defined (type: UTC Timeformat)
Default n/a
Notes When startTime is specified against the policy repeat, ChaosEngine will not be formed before this time, no matter when it was created.
Field .spec.schedule.repeat.timeRange.endTime
Description Flag to specify end timestamp of the range within which chaos is injected, when the policy is repeat. The chaosengine is not created after this timestamp.
Type Mandatory
Range user-defined (type: UTC Timeformat)
Default n/a
Notes When endTime is specified against the policy repeat, ChaosEngine will not be formed after this time.
Field .spec.schedule.repeat.properties.minChaosInterval
Description Flag to specify the minimum interval between two chaosengines to be formed.
Type Mandatory
Range user-defined (type: string)(pattern: "{number}m", "{number}h").
Default n/a
Notes The minChaosInterval in the spec specifies a time interval that must be taken care of while repeatedly forming the chaosengines i.e. This much duration of time should be there as interval between the formation of two chaosengines.
Field .spec.schedule.repeat.workDays.includedDays
Description Flag to specify the days at which chaos is allowed to take place
Type Mandatory
Range user-defined (type: string)(pattern: [{day_name},{day_name}...]).
Default n/a
Notes The includedDays in the spec specifies a (comma-separated) list of days of the week at which chaos is allowed to take place. {day_name} is to be specified with the first 3 letters of the name of day such as Mon, Tue etc.
Field .spec.schedule.repeat.workHours.includedHours
Description Flag to specify the hours at which chaos is allowed to take place
Type Mandatory
Range {hour_number} will range from 0 to 23 (type: string)(pattern: {hour_number}-{hour_number}).
Default n/a
Notes The includedHours in the spec specifies a range of hours of the day at which chaos is allowed to take place. 24 hour format is followed

Engine Specification

Field .spec.engineTemplateSpec
Description Flag to control chaosengine to be formed
Type Mandatory
Range n/a
Default n/a
Notes The engineTemplateSpec is the ChaosEngineSpec of ChaosEngine that is to be formed.

State Specification

Field .spec.scheduleState
Description Flag to control chaosshedule state
Type Optional
Range active, halt, complete
Default active
Notes The scheduleState is the current state of ChaosSchedule. If the schedule is running its state will be active, if the schedule is halted its state will be halt and if the schedule is completed it state will be complete.