ALIYUN::ESS::ScheduledTask is used to create a scheduled task based on specified parameters.
Syntax
{
"Type": "ALIYUN::ESS::ScheduledTask",
"Properties": {
"TaskEnabled": Boolean,
"Description": String,
"ScheduledTaskName": String,
"LaunchExpirationTime": Integer,
"LaunchTime": String,
"RecurrenceEndTime": String,
"RecurrenceType": String,
"RecurrenceValue": String,
"ScheduledAction": String
}
}
Properties
Property | Type | Required | Editable | Description | Constraint |
---|---|---|---|---|---|
TaskEnabled | Boolean | No | Yes | Specifies whether to enable the scheduled task. | Valid values:
|
Description | String | No | Yes | The description of the scheduled task. | The description must be 2 to 200 characters in length. |
ScheduledTaskName | String | No | Yes | The display name of the scheduled task. | The name must be 2 to 40 characters in length and can contain digits, letters, underscores (_), hyphens (-), and periods (.). It must start with a digit or letter. The name of the scheduled task must be unique to an Alibaba Cloud account in a region. If you do not specify this parameter, the default value is the ID of the scheduled scaling task. |
LaunchExpirationTime | Integer | No | Yes | The period of time over which a failed scheduled task is retried. | Valid values: 0 to 21600. Unit: seconds. Default value: 600. |
LaunchTime | String | Yes | Yes | The time at which the scheduled task is triggered. | Specify the time in the ISO 8601 standard in the YYYY-MM-DDThh:mmZ format. The time must be in UTC. You cannot enter a time point later than 90 days from the date of scheduled task creation or modification.
|
RecurrenceEndTime | String | No | Yes | The end time of the scheduled task to be repeated. | Specify the time in the ISO 8601 standard in the YYYY-MM-DDThh:mmZ format. The time must be in UTC. You cannot enter a time point later than 90 days from the date of scheduled task creation or modification. If you set RecurrenceEndTime, you must also set both RecurrenceType and RecurrenceValue. |
RecurrenceType | String | No | Yes | The interval at which the scheduled task is repeated. | Valid values:
If you set RecurrenceType, you must also set both RecurrenceEndTime and RecurrenceValue. |
RecurrenceValue | String | No | Yes | The recurrence value of the scheduled task to be repeated. |
If you set RecurrenceValue, you must also set both RecurrenceEndTime and RecurrenceType. |
ScheduledAction | String | Yes | Yes | The operations to be performed when the scheduled task is triggered. | The parameter value can be up to 200 characters in length. When you set this parameter, you must also enter the unique identifier of the scaling rule. |
Response parameters
Fn::GetAtt
ScheduledTaskId: the ID of the scheduled task. This ID is a globally unique identifier (GUID) generated by the system.
Examples
JSON
format{ "ROSTemplateFormatVersion": "2015-09-01", "Resources": { "ScheduledTask": { "Type": "ALIYUN::ESS::ScheduledTask", "Properties": { "TaskEnabled": "true", "Description": "scheduledtask", "ScheduledTaskName": "task1", "LaunchTime": "2014-08-17T16:52Z", "RecurrenceEndTime": "2014-08-17T16:55Z", "RecurrenceType": "Daily", "RecurrenceValue": "1", "ScheduledAction": "ari:acs:ess:cn-qingdao:1344371:scalingRule/cCBpdYdQuBe2cUxOdu6piOk" } } }, "Outputs": { "ScheduledTaskId": { "Value": { "FN::GetAtt": [ "ScheduledTask", "ScheduledTaskId" ] } } } }