public static final class CreateScheduledTaskRequest.Builder extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
CreateScheduledTaskRequest |
build() |
CreateScheduledTaskRequest.Builder |
description(String description)
The description of the scheduled task.
|
CreateScheduledTaskRequest.Builder |
desiredCapacity(Integer desiredCapacity)
The expected number of instances in the scaling group if you specify the ScalingGroupId parameter.
|
CreateScheduledTaskRequest.Builder |
launchExpirationTime(Integer launchExpirationTime)
The time period during which the failed scheduled task can be retried.
|
CreateScheduledTaskRequest.Builder |
launchTime(String launchTime)
The point in time at which the scheduled task is triggered.
|
CreateScheduledTaskRequest.Builder |
maxValue(Integer maxValue)
The maximum number of instances in the scaling group if you specify the ScalingGroupId parameter.
|
CreateScheduledTaskRequest.Builder |
minValue(Integer minValue)
The minimum number of instances in the scaling group if you specify the ScalingGroupId parameter.
|
CreateScheduledTaskRequest.Builder |
ownerAccount(String ownerAccount)
OwnerAccount.
|
CreateScheduledTaskRequest.Builder |
ownerId(Long ownerId)
OwnerId.
|
CreateScheduledTaskRequest.Builder |
recurrenceEndTime(String recurrenceEndTime)
The end time of the scheduled task.
|
CreateScheduledTaskRequest.Builder |
recurrenceType(String recurrenceType)
The interval at which the scheduled task is repeated.
|
CreateScheduledTaskRequest.Builder |
recurrenceValue(String recurrenceValue)
The number of recurrences of the scheduled task.
|
CreateScheduledTaskRequest.Builder |
regionId(String regionId)
The region ID of the scheduled task.
|
CreateScheduledTaskRequest.Builder |
resourceOwnerAccount(String resourceOwnerAccount)
ResourceOwnerAccount.
|
CreateScheduledTaskRequest.Builder |
scalingGroupId(String scalingGroupId)
The ID of the scaling group.
|
CreateScheduledTaskRequest.Builder |
scheduledAction(String scheduledAction)
The scaling rule that you want to execute when the scheduled task is triggered.
|
CreateScheduledTaskRequest.Builder |
scheduledTaskName(String scheduledTaskName)
The name of the scheduled task.
|
CreateScheduledTaskRequest.Builder |
taskEnabled(Boolean taskEnabled)
Specifies whether to enable the scheduled task.
|
public CreateScheduledTaskRequest.Builder description(String description)
public CreateScheduledTaskRequest.Builder desiredCapacity(Integer desiredCapacity)
> You must specify the `DesiredCapacity` parameter when you create a scaling group.
public CreateScheduledTaskRequest.Builder launchExpirationTime(Integer launchExpirationTime)
Default value: 600.
public CreateScheduledTaskRequest.Builder launchTime(String launchTime)
* If you specify the `RecurrenceType` parameter, the scheduled task is repeatedly executed at the point in time that is specified by the LaunchTime parameter. * If you do not specify the `RecurrenceType` parameter, the task is executed only once at the point in time that is specified by the LaunchTime parameter.
public CreateScheduledTaskRequest.Builder maxValue(Integer maxValue)
public CreateScheduledTaskRequest.Builder minValue(Integer minValue)
public CreateScheduledTaskRequest.Builder ownerAccount(String ownerAccount)
public CreateScheduledTaskRequest.Builder ownerId(Long ownerId)
public CreateScheduledTaskRequest.Builder recurrenceEndTime(String recurrenceEndTime)
The time must be in UTC. You cannot enter a point in time that is later than 365 days from the point in time at which the scheduled task is created.
public CreateScheduledTaskRequest.Builder recurrenceType(String recurrenceType)
* Daily: The scheduled task is executed once every specified number of days. * Weekly: The scheduled task is executed on each specified day of the week. * Monthly: The scheduled task is executed on each specified day of the month. * Cron: The scheduled task is executed based on the specified cron expression. You must specify the `RecurrenceType` and `RecurrenceValue` parameters at the same time.
public CreateScheduledTaskRequest.Builder recurrenceValue(String recurrenceValue)
* If you set the `RecurrenceType` parameter to `Daily`, you can specify only one value for this parameter. Valid values: 1 to 31. * If you set the `RecurrenceType` parameter to `Weekly`, you can specify multiple values for this parameter. Separate the values with commas (,). The values that correspond to Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, and Saturday are 0, 1, 2, 3, 4, 5, and 6.`` * If you set the `RecurrenceType` parameter to `Monthly`, you can specify two values in the `A-B` format for this parameter. Valid values of A and B: 1 to 31. B must be greater than or equal to A. * If you set the `RecurrenceType` parameter to `Cron`, you can specify a cron expression. A cron expression is written in UTC time and consists of the following fields: minute, hour, day, month, and week. The expression can contain the letters L and W and the following wildcard characters: commas (,), question marks (?), hyphens (-), asterisks (\*), number signs (#), and forward slashes (/). You must specify both the `RecurrenceType` parameter and the `RecurrenceValue` parameter.
public CreateScheduledTaskRequest.Builder regionId(String regionId)
public CreateScheduledTaskRequest.Builder resourceOwnerAccount(String resourceOwnerAccount)
public CreateScheduledTaskRequest.Builder scalingGroupId(String scalingGroupId)
If you specify `ScalingGroupId`, you must also specify at least one of the following parameters: `MinValue`, `MaxValue`, and `DesiredCapacity`. You cannot specify `ScheduledAction` and `ScalingGroupId` at the same time.
public CreateScheduledTaskRequest.Builder scheduledAction(String scheduledAction)
If you specify `ScheduledAction`, the scheduled task uses an existing scaling rule. You cannot specify `ScheduledAction` and `ScalingGroupId` at the same time.
public CreateScheduledTaskRequest.Builder scheduledTaskName(String scheduledTaskName)
If you do not specify this parameter, the value of the `ScheduledTaskId` parameter is used.
public CreateScheduledTaskRequest.Builder taskEnabled(Boolean taskEnabled)
* true * false Default value: true.
public CreateScheduledTaskRequest build()
Copyright © 2024. All rights reserved.