@Stability(value=Stable) public static final class ScheduledEc2Task.Builder extends Object
ScheduledEc2Task.| Modifier and Type | Method and Description |
|---|---|
ScheduledEc2Task |
build() |
ScheduledEc2Task.Builder |
cluster(ICluster cluster)
The name of the cluster that hosts the service.
|
static ScheduledEc2Task.Builder |
create(Construct scope,
String id) |
ScheduledEc2Task.Builder |
desiredTaskCount(Number desiredTaskCount)
The desired number of instantiations of the task definition to keep running on the service.
|
ScheduledEc2Task.Builder |
schedule(Schedule schedule)
The schedule or rate (frequency) that determines when CloudWatch Events runs the rule.
|
ScheduledEc2Task.Builder |
scheduledEc2TaskDefinitionOptions(ScheduledEc2TaskDefinitionOptions scheduledEc2TaskDefinitionOptions)
The properties to define if using an existing TaskDefinition in this construct.
|
ScheduledEc2Task.Builder |
scheduledEc2TaskImageOptions(ScheduledEc2TaskImageOptions scheduledEc2TaskImageOptions)
The properties to define if the construct is to create a TaskDefinition.
|
ScheduledEc2Task.Builder |
subnetSelection(SubnetSelection subnetSelection)
In what subnets to place the task's ENIs.
|
ScheduledEc2Task.Builder |
vpc(IVpc vpc)
The VPC where the container instances will be launched or the elastic network interfaces (ENIs) will be deployed.
|
@Stability(value=Stable) public static ScheduledEc2Task.Builder create(Construct scope, String id)
scope - This parameter is required.id - This parameter is required.ScheduledEc2Task.Builder.@Stability(value=Stable) public ScheduledEc2Task.Builder schedule(Schedule schedule)
For more information, see Schedule Expression Syntax for Rules in the Amazon CloudWatch User Guide.
schedule - The schedule or rate (frequency) that determines when CloudWatch Events runs the rule. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder cluster(ICluster cluster)
If a cluster is specified, the vpc construct should be omitted. Alternatively, you can omit both cluster and vpc.
Default: - create a new cluster; if both cluster and vpc are omitted, a new VPC will be created for you.
cluster - The name of the cluster that hosts the service. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder desiredTaskCount(Number desiredTaskCount)
Default: 1
desiredTaskCount - The desired number of instantiations of the task definition to keep running on the service. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder subnetSelection(SubnetSelection subnetSelection)
(Only applicable in case the TaskDefinition is configured for AwsVpc networking)
Default: Private subnets
subnetSelection - In what subnets to place the task's ENIs. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder vpc(IVpc vpc)
If a vpc is specified, the cluster construct should be omitted. Alternatively, you can omit both vpc and cluster.
Default: - uses the VPC defined in the cluster or creates a new VPC.
vpc - The VPC where the container instances will be launched or the elastic network interfaces (ENIs) will be deployed. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder scheduledEc2TaskDefinitionOptions(ScheduledEc2TaskDefinitionOptions scheduledEc2TaskDefinitionOptions)
ScheduledEc2TaskDefinitionOptions or ScheduledEc2TaskImageOptions must be defined, but not both.
Default: none
scheduledEc2TaskDefinitionOptions - The properties to define if using an existing TaskDefinition in this construct. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task.Builder scheduledEc2TaskImageOptions(ScheduledEc2TaskImageOptions scheduledEc2TaskImageOptions)
ScheduledEc2TaskDefinitionOptions or ScheduledEc2TaskImageOptions must be defined, but not both.
Default: none
scheduledEc2TaskImageOptions - The properties to define if the construct is to create a TaskDefinition. This parameter is required.this@Stability(value=Stable) public ScheduledEc2Task build()
Copyright © 2020. All rights reserved.