Class CfnCapacityProvider
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.CfnCapacityProvider
- 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-11-06T23:25:09.214Z")
@Stability(Stable)
public class CfnCapacityProvider
extends CfnResource
implements IInspectable, ITaggable
Creates a new capacity provider.
Capacity providers are associated with an Amazon ECS cluster and are used in capacity provider strategies to facilitate cluster auto scaling.
Only capacity providers that use an Auto Scaling group can be created. Amazon ECS tasks on AWS Fargate use the FARGATE
and FARGATE_SPOT
capacity providers. These providers are available to all accounts in the AWS Regions that AWS Fargate supports.
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.*; CfnCapacityProvider cfnCapacityProvider = CfnCapacityProvider.Builder.create(this, "MyCfnCapacityProvider") .autoScalingGroupProvider(AutoScalingGroupProviderProperty.builder() .autoScalingGroupArn("autoScalingGroupArn") // the properties below are optional .managedDraining("managedDraining") .managedScaling(ManagedScalingProperty.builder() .instanceWarmupPeriod(123) .maximumScalingStepSize(123) .minimumScalingStepSize(123) .status("status") .targetCapacity(123) .build()) .managedTerminationProtection("managedTerminationProtection") .build()) .name("name") .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
The details of the Auto Scaling group for the capacity provider.static final class
A fluent builder forCfnCapacityProvider
.static interface
The managed scaling settings for the Auto Scaling group capacity provider.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
CfnCapacityProvider
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnCapacityProvider
(software.amazon.jsii.JsiiObjectRef objRef) CfnCapacityProvider
(software.constructs.Construct scope, String id) CfnCapacityProvider
(software.constructs.Construct scope, String id, CfnCapacityProviderProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe Auto Scaling group settings for the capacity provider.getName()
The name of the capacity provider.getTags()
Tag Manager which manages the tags for this resource.The metadata that you apply to the capacity provider to help you categorize and organize it.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
The Auto Scaling group settings for the capacity provider.void
The Auto Scaling group settings for the capacity provider.void
The name of the capacity provider.void
setTagsRaw
(List<CfnTag> value) The metadata that you apply to the capacity provider to help you categorize and organize it.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
-
CfnCapacityProvider
protected CfnCapacityProvider(software.amazon.jsii.JsiiObjectRef objRef) -
CfnCapacityProvider
protected CfnCapacityProvider(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnCapacityProvider
@Stability(Stable) public CfnCapacityProvider(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable CfnCapacityProviderProps 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.
-
CfnCapacityProvider
@Stability(Stable) public CfnCapacityProvider(@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.
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getTags
Tag Manager which manages the tags for this resource. -
getAutoScalingGroupProvider
The Auto Scaling group settings for the capacity provider. -
setAutoScalingGroupProvider
The Auto Scaling group settings for the capacity provider. -
setAutoScalingGroupProvider
@Stability(Stable) public void setAutoScalingGroupProvider(@Nullable CfnCapacityProvider.AutoScalingGroupProviderProperty value) The Auto Scaling group settings for the capacity provider. -
getName
The name of the capacity provider. -
setName
The name of the capacity provider. -
getTagsRaw
The metadata that you apply to the capacity provider to help you categorize and organize it. -
setTagsRaw
The metadata that you apply to the capacity provider to help you categorize and organize it.
-