scheduled_actions
Creates, updates, deletes, gets or lists a scheduled_actions resource.
Overview
| Name | scheduled_actions |
| Type | Resource |
| Id | aws.autoscaling.scheduled_actions |
Fields
The following fields are returned by SELECT queries:
- describe_scheduled_actions
| Name | Datatype | Description |
|---|---|---|
auto_scaling_group_name | string | The name of the Auto Scaling group. |
desired_capacity | integer | The desired capacity is the initial capacity of the Auto Scaling group after the scheduled action runs and the capacity it attempts to maintain. |
end_time | string | The date and time in UTC for the recurring schedule to end. For example, "2019-06-01T00:00:00Z". |
max_size | integer | The maximum size of the Auto Scaling group. |
min_size | integer | The minimum size of the Auto Scaling group. |
recurrence | string | The recurring schedule for the action, in Unix cron syntax format. When StartTime and EndTime are specified with Recurrence, they form the boundaries of when the recurring action starts and stops. |
scheduled_action_arn | string | The Amazon Resource Name (ARN) of the scheduled action. |
scheduled_action_name | string | The name of the scheduled action. |
start_time | string | The date and time in UTC for this action to start. For example, "2019-06-01T00:00:00Z". |
time | string | This property is no longer used. |
time_zone | string | The time zone for the cron expression. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_scheduled_actions | select | region | AutoScalingGroupName, ScheduledActionNames, StartTime, EndTime, NextToken, MaxRecords | Gets information about the scheduled actions that haven't run or that have not reached their end time. To describe the scaling activities for scheduled actions that have already run, call the DescribeScalingActivities API. |
delete_scheduled_action | delete | AutoScalingGroupName, ScheduledActionName, region | Deletes the specified scheduled action. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
AutoScalingGroupName | string | The name of the Auto Scaling group. |
ScheduledActionName | string | The name of the action to delete. |
region | string | AWS region (default: us-east-1) |
AutoScalingGroupName | string | The name of the Auto Scaling group. |
EndTime | string (date-time) | The latest scheduled start time to return. If scheduled action names are provided, this property is ignored. |
MaxRecords | integer | The maximum number of items to return with this call. The default value is 50 and the maximum value is 100. |
NextToken | string | The token for the next set of items to return. (You received this token from a previous call.) |
ScheduledActionNames | array | The names of one or more scheduled actions. If you omit this property, all scheduled actions are described. If you specify an unknown scheduled action, it is ignored with no error. Array Members: Maximum number of 50 actions. |
StartTime | string (date-time) | The earliest scheduled start time to return. If scheduled action names are provided, this property is ignored. |
SELECT examples
- describe_scheduled_actions
Gets information about the scheduled actions that haven't run or that have not reached their end time. To describe the scaling activities for scheduled actions that have already run, call the DescribeScalingActivities API.
SELECT
auto_scaling_group_name,
desired_capacity,
end_time,
max_size,
min_size,
recurrence,
scheduled_action_arn,
scheduled_action_name,
start_time,
time,
time_zone
FROM aws.autoscaling.scheduled_actions
WHERE region = '{{ region }}' -- required
AND AutoScalingGroupName = '{{ AutoScalingGroupName }}'
AND ScheduledActionNames = '{{ ScheduledActionNames }}'
AND StartTime = '{{ StartTime }}'
AND EndTime = '{{ EndTime }}'
AND NextToken = '{{ NextToken }}'
AND MaxRecords = '{{ MaxRecords }}'
;
DELETE examples
- delete_scheduled_action
Deletes the specified scheduled action.
DELETE FROM aws.autoscaling.scheduled_actions
WHERE AutoScalingGroupName = '{{ AutoScalingGroupName }}' --required
AND ScheduledActionName = '{{ ScheduledActionName }}' --required
AND region = '{{ region }}' --required
;