schedule
Manages schedules.
Schedule Fields
The schedule object contains the following fields:
Field |
Value |
---|---|
id |
The ID of the schedule. |
name |
The name of the schedule. |
inuse |
Indicates whether the schedule is associated with an action. |
rules |
An array of JSON objects specifying how often the scheduled action occurs. See Rule Fields below. |
Rule Fields
The following table shows the fields to use when creating a rules object.
Field |
Values |
---|---|
frequency |
How often to perform the action:
|
retain |
How long to retain the data resulting from the action. For example, if the schedule creates a snapshot, the retain field sets the snapshot's expiration. The retain field consists of an integer and one of the following units of time:
NOTE For offload schedule, set the value for this to
0 . |
time |
The time of day to perform the action, in 24-hour format: HH |
date |
The date on which to perform the action:
|
Example
The following example JSON shows a schedule called "snapshot," with three rules.
{
"id":8,
"name":"snapshot",
"inuse":0,
"rules":[
{
"frequency":"monthly",
"date":"8",
"time":14,
"retain":"1m"
},
{
"frequency":"weekly",
"date":"sat",
"time":14,
"retain":"2w"
},
{
"frequency":"hourly",
"retain":"1d"
}
]
}