#[non_exhaustive]pub struct Builder { /* private fields */ }
Expand description
A builder for TaskSet
Implementations
sourceimpl Builder
impl Builder
sourcepub fn task_set_arn(self, input: impl Into<String>) -> Self
pub fn task_set_arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the task set.
sourcepub fn set_task_set_arn(self, input: Option<String>) -> Self
pub fn set_task_set_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the task set.
sourcepub fn service_arn(self, input: impl Into<String>) -> Self
pub fn service_arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the service the task set exists in.
sourcepub fn set_service_arn(self, input: Option<String>) -> Self
pub fn set_service_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the service the task set exists in.
sourcepub fn cluster_arn(self, input: impl Into<String>) -> Self
pub fn cluster_arn(self, input: impl Into<String>) -> Self
The Amazon Resource Name (ARN) of the cluster that the service that hosts the task set exists in.
sourcepub fn set_cluster_arn(self, input: Option<String>) -> Self
pub fn set_cluster_arn(self, input: Option<String>) -> Self
The Amazon Resource Name (ARN) of the cluster that the service that hosts the task set exists in.
sourcepub fn started_by(self, input: impl Into<String>) -> Self
pub fn started_by(self, input: impl Into<String>) -> Self
The tag specified when a task set is started. If an CodeDeploy deployment created the task set, the startedBy
parameter is CODE_DEPLOY
. If an external deployment created the task set, the startedBy field isn't used.
sourcepub fn set_started_by(self, input: Option<String>) -> Self
pub fn set_started_by(self, input: Option<String>) -> Self
The tag specified when a task set is started. If an CodeDeploy deployment created the task set, the startedBy
parameter is CODE_DEPLOY
. If an external deployment created the task set, the startedBy field isn't used.
sourcepub fn external_id(self, input: impl Into<String>) -> Self
pub fn external_id(self, input: impl Into<String>) -> Self
The external ID associated with the task set.
If an CodeDeploy deployment created a task set, the externalId
parameter contains the CodeDeploy deployment ID.
If a task set is created for an external deployment and is associated with a service discovery registry, the externalId
parameter contains the ECS_TASK_SET_EXTERNAL_ID
Cloud Map attribute.
sourcepub fn set_external_id(self, input: Option<String>) -> Self
pub fn set_external_id(self, input: Option<String>) -> Self
The external ID associated with the task set.
If an CodeDeploy deployment created a task set, the externalId
parameter contains the CodeDeploy deployment ID.
If a task set is created for an external deployment and is associated with a service discovery registry, the externalId
parameter contains the ECS_TASK_SET_EXTERNAL_ID
Cloud Map attribute.
sourcepub fn status(self, input: impl Into<String>) -> Self
pub fn status(self, input: impl Into<String>) -> Self
The status of the task set. The following describes each state.
- PRIMARY
-
The task set is serving production traffic.
- ACTIVE
-
The task set isn't serving production traffic.
- DRAINING
-
The tasks in the task set are being stopped, and their corresponding targets are being deregistered from their target group.
sourcepub fn set_status(self, input: Option<String>) -> Self
pub fn set_status(self, input: Option<String>) -> Self
The status of the task set. The following describes each state.
- PRIMARY
-
The task set is serving production traffic.
- ACTIVE
-
The task set isn't serving production traffic.
- DRAINING
-
The tasks in the task set are being stopped, and their corresponding targets are being deregistered from their target group.
sourcepub fn task_definition(self, input: impl Into<String>) -> Self
pub fn task_definition(self, input: impl Into<String>) -> Self
The task definition that the task set is using.
sourcepub fn set_task_definition(self, input: Option<String>) -> Self
pub fn set_task_definition(self, input: Option<String>) -> Self
The task definition that the task set is using.
sourcepub fn computed_desired_count(self, input: i32) -> Self
pub fn computed_desired_count(self, input: i32) -> Self
The computed desired count for the task set. This is calculated by multiplying the service's desiredCount
by the task set's scale
percentage. The result is always rounded up. For example, if the computed desired count is 1.2, it rounds up to 2 tasks.
sourcepub fn set_computed_desired_count(self, input: Option<i32>) -> Self
pub fn set_computed_desired_count(self, input: Option<i32>) -> Self
The computed desired count for the task set. This is calculated by multiplying the service's desiredCount
by the task set's scale
percentage. The result is always rounded up. For example, if the computed desired count is 1.2, it rounds up to 2 tasks.
sourcepub fn pending_count(self, input: i32) -> Self
pub fn pending_count(self, input: i32) -> Self
The number of tasks in the task set that are in the PENDING
status during a deployment. A task in the PENDING
state is preparing to enter the RUNNING
state. A task set enters the PENDING
status when it launches for the first time or when it's restarted after being in the STOPPED
state.
sourcepub fn set_pending_count(self, input: Option<i32>) -> Self
pub fn set_pending_count(self, input: Option<i32>) -> Self
The number of tasks in the task set that are in the PENDING
status during a deployment. A task in the PENDING
state is preparing to enter the RUNNING
state. A task set enters the PENDING
status when it launches for the first time or when it's restarted after being in the STOPPED
state.
sourcepub fn running_count(self, input: i32) -> Self
pub fn running_count(self, input: i32) -> Self
The number of tasks in the task set that are in the RUNNING
status during a deployment. A task in the RUNNING
state is running and ready for use.
sourcepub fn set_running_count(self, input: Option<i32>) -> Self
pub fn set_running_count(self, input: Option<i32>) -> Self
The number of tasks in the task set that are in the RUNNING
status during a deployment. A task in the RUNNING
state is running and ready for use.
sourcepub fn created_at(self, input: DateTime) -> Self
pub fn created_at(self, input: DateTime) -> Self
The Unix timestamp for the time when the task set was created.
sourcepub fn set_created_at(self, input: Option<DateTime>) -> Self
pub fn set_created_at(self, input: Option<DateTime>) -> Self
The Unix timestamp for the time when the task set was created.
sourcepub fn updated_at(self, input: DateTime) -> Self
pub fn updated_at(self, input: DateTime) -> Self
The Unix timestamp for the time when the task set was last updated.
sourcepub fn set_updated_at(self, input: Option<DateTime>) -> Self
pub fn set_updated_at(self, input: Option<DateTime>) -> Self
The Unix timestamp for the time when the task set was last updated.
sourcepub fn launch_type(self, input: LaunchType) -> Self
pub fn launch_type(self, input: LaunchType) -> Self
The launch type the tasks in the task set are using. For more information, see Amazon ECS launch types in the Amazon Elastic Container Service Developer Guide.
sourcepub fn set_launch_type(self, input: Option<LaunchType>) -> Self
pub fn set_launch_type(self, input: Option<LaunchType>) -> Self
The launch type the tasks in the task set are using. For more information, see Amazon ECS launch types in the Amazon Elastic Container Service Developer Guide.
sourcepub fn capacity_provider_strategy(
self,
input: CapacityProviderStrategyItem
) -> Self
pub fn capacity_provider_strategy(
self,
input: CapacityProviderStrategyItem
) -> Self
Appends an item to capacity_provider_strategy
.
To override the contents of this collection use set_capacity_provider_strategy
.
The capacity provider strategy that are associated with the task set.
sourcepub fn set_capacity_provider_strategy(
self,
input: Option<Vec<CapacityProviderStrategyItem>>
) -> Self
pub fn set_capacity_provider_strategy(
self,
input: Option<Vec<CapacityProviderStrategyItem>>
) -> Self
The capacity provider strategy that are associated with the task set.
sourcepub fn platform_version(self, input: impl Into<String>) -> Self
pub fn platform_version(self, input: impl Into<String>) -> Self
The Fargate platform version where the tasks in the task set are running. A platform version is only specified for tasks run on Fargate. For more information, see Fargate platform versions in the Amazon Elastic Container Service Developer Guide.
sourcepub fn set_platform_version(self, input: Option<String>) -> Self
pub fn set_platform_version(self, input: Option<String>) -> Self
The Fargate platform version where the tasks in the task set are running. A platform version is only specified for tasks run on Fargate. For more information, see Fargate platform versions in the Amazon Elastic Container Service Developer Guide.
sourcepub fn platform_family(self, input: impl Into<String>) -> Self
pub fn platform_family(self, input: impl Into<String>) -> Self
The operating system that your tasks in the set are running on. A platform family is specified only for tasks that use the Fargate launch type.
All tasks in the set must have the same value.
sourcepub fn set_platform_family(self, input: Option<String>) -> Self
pub fn set_platform_family(self, input: Option<String>) -> Self
The operating system that your tasks in the set are running on. A platform family is specified only for tasks that use the Fargate launch type.
All tasks in the set must have the same value.
sourcepub fn network_configuration(self, input: NetworkConfiguration) -> Self
pub fn network_configuration(self, input: NetworkConfiguration) -> Self
The network configuration for the task set.
sourcepub fn set_network_configuration(
self,
input: Option<NetworkConfiguration>
) -> Self
pub fn set_network_configuration(
self,
input: Option<NetworkConfiguration>
) -> Self
The network configuration for the task set.
sourcepub fn load_balancers(self, input: LoadBalancer) -> Self
pub fn load_balancers(self, input: LoadBalancer) -> Self
Appends an item to load_balancers
.
To override the contents of this collection use set_load_balancers
.
Details on a load balancer that are used with a task set.
sourcepub fn set_load_balancers(self, input: Option<Vec<LoadBalancer>>) -> Self
pub fn set_load_balancers(self, input: Option<Vec<LoadBalancer>>) -> Self
Details on a load balancer that are used with a task set.
sourcepub fn service_registries(self, input: ServiceRegistry) -> Self
pub fn service_registries(self, input: ServiceRegistry) -> Self
Appends an item to service_registries
.
To override the contents of this collection use set_service_registries
.
The details for the service discovery registries to assign to this task set. For more information, see Service discovery.
sourcepub fn set_service_registries(self, input: Option<Vec<ServiceRegistry>>) -> Self
pub fn set_service_registries(self, input: Option<Vec<ServiceRegistry>>) -> Self
The details for the service discovery registries to assign to this task set. For more information, see Service discovery.
sourcepub fn scale(self, input: Scale) -> Self
pub fn scale(self, input: Scale) -> Self
A floating-point percentage of your desired number of tasks to place and keep running in the task set.
sourcepub fn set_scale(self, input: Option<Scale>) -> Self
pub fn set_scale(self, input: Option<Scale>) -> Self
A floating-point percentage of your desired number of tasks to place and keep running in the task set.
sourcepub fn stability_status(self, input: StabilityStatus) -> Self
pub fn stability_status(self, input: StabilityStatus) -> Self
The stability status. This indicates whether the task set has reached a steady state. If the following conditions are met, the task set sre in STEADY_STATE
:
-
The task
runningCount
is equal to thecomputedDesiredCount
. -
The
pendingCount
is0
. -
There are no tasks that are running on container instances in the
DRAINING
status. -
All tasks are reporting a healthy status from the load balancers, service discovery, and container health checks.
If any of those conditions aren't met, the stability status returns STABILIZING
.
sourcepub fn set_stability_status(self, input: Option<StabilityStatus>) -> Self
pub fn set_stability_status(self, input: Option<StabilityStatus>) -> Self
The stability status. This indicates whether the task set has reached a steady state. If the following conditions are met, the task set sre in STEADY_STATE
:
-
The task
runningCount
is equal to thecomputedDesiredCount
. -
The
pendingCount
is0
. -
There are no tasks that are running on container instances in the
DRAINING
status. -
All tasks are reporting a healthy status from the load balancers, service discovery, and container health checks.
If any of those conditions aren't met, the stability status returns STABILIZING
.
sourcepub fn stability_status_at(self, input: DateTime) -> Self
pub fn stability_status_at(self, input: DateTime) -> Self
The Unix timestamp for the time when the task set stability status was retrieved.
sourcepub fn set_stability_status_at(self, input: Option<DateTime>) -> Self
pub fn set_stability_status_at(self, input: Option<DateTime>) -> Self
The Unix timestamp for the time when the task set stability status was retrieved.
Appends an item to tags
.
To override the contents of this collection use set_tags
.
The metadata that you apply to the task set to help you categorize and organize them. Each tag consists of a key and an optional value. You define both.
The following basic restrictions apply to tags:
-
Maximum number of tags per resource - 50
-
For each resource, each tag key must be unique, and each tag key can have only one value.
-
Maximum key length - 128 Unicode characters in UTF-8
-
Maximum value length - 256 Unicode characters in UTF-8
-
If your tagging schema is used across multiple services and resources, remember that other services may have restrictions on allowed characters. Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following characters: + - = . _ : / @.
-
Tag keys and values are case-sensitive.
-
Do not use
aws:
,AWS:
, or any upper or lowercase combination of such as a prefix for either keys or values as it is reserved for Amazon Web Services use. You cannot edit or delete tag keys or values with this prefix. Tags with this prefix do not count against your tags per resource limit.
The metadata that you apply to the task set to help you categorize and organize them. Each tag consists of a key and an optional value. You define both.
The following basic restrictions apply to tags:
-
Maximum number of tags per resource - 50
-
For each resource, each tag key must be unique, and each tag key can have only one value.
-
Maximum key length - 128 Unicode characters in UTF-8
-
Maximum value length - 256 Unicode characters in UTF-8
-
If your tagging schema is used across multiple services and resources, remember that other services may have restrictions on allowed characters. Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following characters: + - = . _ : / @.
-
Tag keys and values are case-sensitive.
-
Do not use
aws:
,AWS:
, or any upper or lowercase combination of such as a prefix for either keys or values as it is reserved for Amazon Web Services use. You cannot edit or delete tag keys or values with this prefix. Tags with this prefix do not count against your tags per resource limit.
Trait Implementations
impl StructuralPartialEq for Builder
Auto Trait Implementations
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more