Class CfnCluster
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.ecs.CfnCluster
- All Implemented Interfaces:
IInspectable
,ITaggable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-12-27T17:02:01.188Z")
@Stability(Stable)
public class CfnCluster
extends CfnResource
implements IInspectable, ITaggable
The
AWS::ECS::Cluster
resource creates an Amazon Elastic Container Service (Amazon ECS) cluster.
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.*; CfnCluster cfnCluster = CfnCluster.Builder.create(this, "MyCfnCluster") .capacityProviders(List.of("capacityProviders")) .clusterName("clusterName") .clusterSettings(List.of(ClusterSettingsProperty.builder() .name("name") .value("value") .build())) .configuration(ClusterConfigurationProperty.builder() .executeCommandConfiguration(ExecuteCommandConfigurationProperty.builder() .kmsKeyId("kmsKeyId") .logConfiguration(ExecuteCommandLogConfigurationProperty.builder() .cloudWatchEncryptionEnabled(false) .cloudWatchLogGroupName("cloudWatchLogGroupName") .s3BucketName("s3BucketName") .s3EncryptionEnabled(false) .s3KeyPrefix("s3KeyPrefix") .build()) .logging("logging") .build()) .managedStorageConfiguration(ManagedStorageConfigurationProperty.builder() .fargateEphemeralStorageKmsKeyId("fargateEphemeralStorageKmsKeyId") .kmsKeyId("kmsKeyId") .build()) .build()) .defaultCapacityProviderStrategy(List.of(CapacityProviderStrategyItemProperty.builder() .base(123) .capacityProvider("capacityProvider") .weight(123) .build())) .serviceConnectDefaults(ServiceConnectDefaultsProperty.builder() .namespace("namespace") .build()) .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A fluent builder forCfnCluster
.static interface
TheCapacityProviderStrategyItem
property specifies the details of the default capacity provider strategy for the cluster.static interface
The execute command and managed storage configuration for the cluster.static interface
The settings to use when creating a cluster.static interface
The details of the execute command configuration.static interface
The log configuration for the results of the execute command actions.static interface
The managed storage configuration for the cluster.static interface
Use this parameter to set a default Service Connect namespace.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
Nested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionprotected
CfnCluster
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnCluster
(software.amazon.jsii.JsiiObjectRef objRef) CfnCluster
(software.constructs.Construct scope, String id) CfnCluster
(software.constructs.Construct scope, String id, CfnClusterProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe Amazon Resource Name (ARN) of the Amazon ECS cluster, such asarn:aws:ecs:us-east-2:123456789012:cluster/MyECSCluster
.The short name of one or more capacity providers to associate with the cluster.A user-generated string that you use to identify your cluster.The settings to use when creating a cluster.The execute command and managed storage configuration for the cluster.The default capacity provider strategy for the cluster.Use this parameter to set a default Service Connect namespace.getTags()
Tag Manager which manages the tags for this resource.The metadata that you apply to the cluster to help you categorize and organize them.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setCapacityProviders
(List<String> value) The short name of one or more capacity providers to associate with the cluster.void
setClusterName
(String value) A user-generated string that you use to identify your cluster.void
setClusterSettings
(List<Object> value) The settings to use when creating a cluster.void
setClusterSettings
(IResolvable value) The settings to use when creating a cluster.void
setConfiguration
(IResolvable value) The execute command and managed storage configuration for the cluster.void
The execute command and managed storage configuration for the cluster.void
The default capacity provider strategy for the cluster.void
The default capacity provider strategy for the cluster.void
Use this parameter to set a default Service Connect namespace.void
Use this parameter to set a default Service Connect namespace.void
setTagsRaw
(List<CfnTag> value) The metadata that you apply to the cluster to help you categorize and organize them.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.constructs.Construct
getNode, isConstruct
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnCluster
protected CfnCluster(software.amazon.jsii.JsiiObjectRef objRef) -
CfnCluster
protected CfnCluster(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnCluster
@Stability(Stable) public CfnCluster(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable CfnClusterProps props) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.props
- Resource properties.
-
CfnCluster
@Stability(Stable) public CfnCluster(@NotNull software.constructs.Construct scope, @NotNull String id) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getAttrArn
The Amazon Resource Name (ARN) of the Amazon ECS cluster, such asarn:aws:ecs:us-east-2:123456789012:cluster/MyECSCluster
. -
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getTags
Tag Manager which manages the tags for this resource. -
getCapacityProviders
The short name of one or more capacity providers to associate with the cluster. -
setCapacityProviders
The short name of one or more capacity providers to associate with the cluster. -
getClusterName
A user-generated string that you use to identify your cluster. -
setClusterName
A user-generated string that you use to identify your cluster. -
getClusterSettings
The settings to use when creating a cluster. -
setClusterSettings
The settings to use when creating a cluster. -
setClusterSettings
The settings to use when creating a cluster. -
getConfiguration
The execute command and managed storage configuration for the cluster. -
setConfiguration
The execute command and managed storage configuration for the cluster. -
setConfiguration
@Stability(Stable) public void setConfiguration(@Nullable CfnCluster.ClusterConfigurationProperty value) The execute command and managed storage configuration for the cluster. -
getDefaultCapacityProviderStrategy
The default capacity provider strategy for the cluster. -
setDefaultCapacityProviderStrategy
The default capacity provider strategy for the cluster. -
setDefaultCapacityProviderStrategy
The default capacity provider strategy for the cluster. -
getServiceConnectDefaults
Use this parameter to set a default Service Connect namespace. -
setServiceConnectDefaults
Use this parameter to set a default Service Connect namespace. -
setServiceConnectDefaults
@Stability(Stable) public void setServiceConnectDefaults(@Nullable CfnCluster.ServiceConnectDefaultsProperty value) Use this parameter to set a default Service Connect namespace. -
getTagsRaw
The metadata that you apply to the cluster to help you categorize and organize them. -
setTagsRaw
The metadata that you apply to the cluster to help you categorize and organize them.
-