@Stability(value=Stable)
public static interface CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty
extends software.amazon.jsii.JsiiSerializable
If you are using the Fargate launch type, task placement constraints are not supported.
For more information, see Task Placement Constraints in the Amazon Elastic Container Service Developer Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ecs.*;
TaskDefinitionPlacementConstraintProperty taskDefinitionPlacementConstraintProperty = TaskDefinitionPlacementConstraintProperty.builder()
.type("type")
// the properties below are optional
.expression("expression")
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty.Builder
|
static class |
CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty.Jsii$Proxy
An implementation for
CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty |
| Modifier and Type | Method and Description |
|---|---|
static CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty.Builder |
builder() |
default String |
getExpression()
A cluster query language expression to apply to the constraint.
|
String |
getType()
The type of constraint.
|
@Stability(value=Stable) @NotNull String getType()
The MemberOf constraint restricts selection to be from a group of valid candidates.
@Stability(value=Stable) @Nullable default String getExpression()
For more information, see Cluster query language in the Amazon Elastic Container Service Developer Guide .
@Stability(value=Stable) static CfnTaskDefinition.TaskDefinitionPlacementConstraintProperty.Builder builder()
Copyright © 2022. All rights reserved.