@Generated(value="software.amazon.awssdk:codegen") public final class TaskSet extends Object implements SdkPojo, Serializable, ToCopyableBuilder<TaskSet.Builder,TaskSet>
Information about a set of Amazon ECS tasks in either an CodeDeploy or an EXTERNAL deployment. An Amazon
ECS task set includes details such as the desired number of tasks, how many tasks are running, and whether the task
set serves production traffic.
| Modifier and Type | Class and Description |
|---|---|
static interface |
TaskSet.Builder |
| Modifier and Type | Method and Description |
|---|---|
static TaskSet.Builder |
builder() |
List<CapacityProviderStrategyItem> |
capacityProviderStrategy()
The capacity provider strategy that are associated with the task set.
|
String |
clusterArn()
The Amazon Resource Name (ARN) of the cluster that the service that hosts the task set exists in.
|
Integer |
computedDesiredCount()
The computed desired count for the task set.
|
Instant |
createdAt()
The Unix timestamp for the time when the task set was created.
|
boolean |
equals(Object obj) |
boolean |
equalsBySdkFields(Object obj) |
String |
externalId()
The external ID associated with the task set.
|
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
boolean |
hasCapacityProviderStrategy()
For responses, this returns true if the service returned a value for the CapacityProviderStrategy property.
|
int |
hashCode() |
boolean |
hasLoadBalancers()
For responses, this returns true if the service returned a value for the LoadBalancers property.
|
boolean |
hasServiceRegistries()
For responses, this returns true if the service returned a value for the ServiceRegistries property.
|
boolean |
hasTags()
For responses, this returns true if the service returned a value for the Tags property.
|
String |
id()
The ID of the task set.
|
LaunchType |
launchType()
The launch type the tasks in the task set are using.
|
String |
launchTypeAsString()
The launch type the tasks in the task set are using.
|
List<LoadBalancer> |
loadBalancers()
Details on a load balancer that are used with a task set.
|
NetworkConfiguration |
networkConfiguration()
The network configuration for the task set.
|
Integer |
pendingCount()
The number of tasks in the task set that are in the
PENDING status during a deployment. |
String |
platformFamily()
The operating system that your tasks in the set are running on.
|
String |
platformVersion()
The Fargate platform version where the tasks in the task set are running.
|
Integer |
runningCount()
The number of tasks in the task set that are in the
RUNNING status during a deployment. |
Scale |
scale()
A floating-point percentage of your desired number of tasks to place and keep running in the task set.
|
List<SdkField<?>> |
sdkFields() |
static Class<? extends TaskSet.Builder> |
serializableBuilderClass() |
String |
serviceArn()
The Amazon Resource Name (ARN) of the service the task set exists in.
|
List<ServiceRegistry> |
serviceRegistries()
The details for the service discovery registries to assign to this task set.
|
StabilityStatus |
stabilityStatus()
The stability status.
|
String |
stabilityStatusAsString()
The stability status.
|
Instant |
stabilityStatusAt()
The Unix timestamp for the time when the task set stability status was retrieved.
|
String |
startedBy()
The tag specified when a task set is started.
|
String |
status()
The status of the task set.
|
List<Tag> |
tags()
The metadata that you apply to the task set to help you categorize and organize them.
|
String |
taskDefinition()
The task definition that the task set is using.
|
String |
taskSetArn()
The Amazon Resource Name (ARN) of the task set.
|
TaskSet.Builder |
toBuilder() |
String |
toString()
Returns a string representation of this object.
|
Instant |
updatedAt()
The Unix timestamp for the time when the task set was last updated.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcopypublic final String id()
The ID of the task set.
public final String taskSetArn()
The Amazon Resource Name (ARN) of the task set.
public final String serviceArn()
The Amazon Resource Name (ARN) of the service the task set exists in.
public final String clusterArn()
The Amazon Resource Name (ARN) of the cluster that the service that hosts the task set exists in.
public final String startedBy()
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.
startedBy parameter is CODE_DEPLOY. If an external deployment created the task
set, the startedBy field isn't used.public final String externalId()
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.
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.
public final String status()
The status of the task set. The following describes each state.
The task set is serving production traffic.
The task set isn't serving production traffic.
The tasks in the task set are being stopped, and their corresponding targets are being deregistered from their target group.
The task set is serving production traffic.
The task set isn't serving production traffic.
The tasks in the task set are being stopped, and their corresponding targets are being deregistered from their target group.
public final String taskDefinition()
The task definition that the task set is using.
public final Integer computedDesiredCount()
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.
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.public final Integer pendingCount()
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.
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.public final Integer runningCount()
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.
RUNNING status during a deployment. A
task in the RUNNING state is running and ready for use.public final Instant createdAt()
The Unix timestamp for the time when the task set was created.
public final Instant updatedAt()
The Unix timestamp for the time when the task set was last updated.
public final LaunchType launchType()
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.
If the service returns an enum value that is not available in the current SDK version, launchType will
return LaunchType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
launchTypeAsString().
LaunchTypepublic final String launchTypeAsString()
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.
If the service returns an enum value that is not available in the current SDK version, launchType will
return LaunchType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
launchTypeAsString().
LaunchTypepublic final boolean hasCapacityProviderStrategy()
isEmpty() method on the
property). This is useful because the SDK will never return a null collection or map, but you may need to
differentiate between the service returning nothing (or null) and the service returning an empty collection or
map. For requests, this returns true if a value for the property was specified in the request builder, and false
if a value was not specified.public final List<CapacityProviderStrategyItem> capacityProviderStrategy()
The capacity provider strategy that are associated with the task set.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasCapacityProviderStrategy() method.
public final String platformVersion()
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.
public final String platformFamily()
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.
All tasks in the set must have the same value.
public final NetworkConfiguration networkConfiguration()
The network configuration for the task set.
public final boolean hasLoadBalancers()
isEmpty() method on the property).
This is useful because the SDK will never return a null collection or map, but you may need to differentiate
between the service returning nothing (or null) and the service returning an empty collection or map. For
requests, this returns true if a value for the property was specified in the request builder, and false if a
value was not specified.public final List<LoadBalancer> loadBalancers()
Details on a load balancer that are used with a task set.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasLoadBalancers() method.
public final boolean hasServiceRegistries()
isEmpty() method on the property).
This is useful because the SDK will never return a null collection or map, but you may need to differentiate
between the service returning nothing (or null) and the service returning an empty collection or map. For
requests, this returns true if a value for the property was specified in the request builder, and false if a
value was not specified.public final List<ServiceRegistry> serviceRegistries()
The details for the service discovery registries to assign to this task set. For more information, see Service discovery.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasServiceRegistries() method.
public final Scale scale()
A floating-point percentage of your desired number of tasks to place and keep running in the task set.
public final StabilityStatus stabilityStatus()
The stability status. This indicates whether the task set has reached a steady state. If the following conditions
are met, the task set are in STEADY_STATE:
The task runningCount is equal to the computedDesiredCount.
The pendingCount is 0.
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.
If the service returns an enum value that is not available in the current SDK version, stabilityStatus
will return StabilityStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available
from stabilityStatusAsString().
STEADY_STATE:
The task runningCount is equal to the computedDesiredCount.
The pendingCount is 0.
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.
StabilityStatuspublic final String stabilityStatusAsString()
The stability status. This indicates whether the task set has reached a steady state. If the following conditions
are met, the task set are in STEADY_STATE:
The task runningCount is equal to the computedDesiredCount.
The pendingCount is 0.
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.
If the service returns an enum value that is not available in the current SDK version, stabilityStatus
will return StabilityStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available
from stabilityStatusAsString().
STEADY_STATE:
The task runningCount is equal to the computedDesiredCount.
The pendingCount is 0.
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.
StabilityStatuspublic final Instant stabilityStatusAt()
The Unix timestamp for the time when the task set stability status was retrieved.
public final boolean hasTags()
isEmpty() method on the property). This is useful
because the SDK will never return a null collection or map, but you may need to differentiate between the service
returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true
if a value for the property was specified in the request builder, and false if a value was not specified.public final List<Tag> 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.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasTags() method.
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.
public TaskSet.Builder toBuilder()
toBuilder in interface ToCopyableBuilder<TaskSet.Builder,TaskSet>public static TaskSet.Builder builder()
public static Class<? extends TaskSet.Builder> serializableBuilderClass()
public final boolean equalsBySdkFields(Object obj)
equalsBySdkFields in interface SdkPojopublic final String toString()
Copyright © 2022. All rights reserved.