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.lambda.CfnCapacityProvider
- All Implemented Interfaces:
IInspectable,IEnvironmentAware,ICapacityProviderRef,ITaggableV2,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-12-01T16:02:23.532Z")
@Stability(Stable)
public class CfnCapacityProvider
extends CfnResource
implements IInspectable, ICapacityProviderRef, ITaggableV2
Resource Type definition for AWS::Lambda::CapacityProvider.
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.lambda.*;
CfnCapacityProvider cfnCapacityProvider = CfnCapacityProvider.Builder.create(this, "MyCfnCapacityProvider")
.permissionsConfig(CapacityProviderPermissionsConfigProperty.builder()
.capacityProviderOperatorRoleArn("capacityProviderOperatorRoleArn")
.build())
.vpcConfig(CapacityProviderVpcConfigProperty.builder()
.securityGroupIds(List.of("securityGroupIds"))
.subnetIds(List.of("subnetIds"))
.build())
// the properties below are optional
.capacityProviderName("capacityProviderName")
.capacityProviderScalingConfig(CapacityProviderScalingConfigProperty.builder()
.maxVCpuCount(123)
.scalingMode("scalingMode")
.scalingPolicies(List.of(TargetTrackingScalingPolicyProperty.builder()
.predefinedMetricType("predefinedMetricType")
.targetValue(123)
.build()))
.build())
.instanceRequirements(InstanceRequirementsProperty.builder()
.allowedInstanceTypes(List.of("allowedInstanceTypes"))
.architectures(List.of("architectures"))
.excludedInstanceTypes(List.of("excludedInstanceTypes"))
.build())
.kmsKeyArn("kmsKeyArn")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnCapacityProvider.static interfaceIAM permissions configuration for the capacity provider.static interfaceThe scaling configuration for the capacity provider.static interfaceVPC configuration for the capacity provider.static interfaceSpecifications for the types of EC2 instances that the capacity provider can use.static interfaceA target tracking scaling policy for the capacity provider.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.lambda.ICapacityProviderRef
ICapacityProviderRef.Jsii$Default, ICapacityProviderRef.Jsii$ProxyNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggableV2
ITaggableV2.Jsii$Default, ITaggableV2.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnCapacityProvider(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnCapacityProvider(software.amazon.jsii.JsiiObjectRef objRef) CfnCapacityProvider(software.constructs.Construct scope, String id, CfnCapacityProviderProps props) Create a newAWS::Lambda::CapacityProvider. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringarnForCapacityProvider(ICapacityProviderRef resource) The Amazon Resource Name (ARN) of the capacity provider.The current state of the capacity provider.The name of the capacity provider.A reference to a CapacityProvider resource.The scaling configuration for the capacity provider.Tag Manager which manages the tags for this resource.Specifications for the types of EC2 instances that the capacity provider can use.The ARN of the AWS Key Management Service (KMS) key used by the capacity provider.IAM permissions configuration for the capacity provider.getTags()A list of tags to apply to the capacity provider.VPC configuration for the capacity provider.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.static BooleanChecks whether the given object is a CfnCapacityProvider.renderProperties(Map<String, Object> props) voidsetCapacityProviderName(String value) The name of the capacity provider.voidThe scaling configuration for the capacity provider.voidThe scaling configuration for the capacity provider.voidSpecifications for the types of EC2 instances that the capacity provider can use.voidSpecifications for the types of EC2 instances that the capacity provider can use.voidsetKmsKeyArn(String value) The ARN of the AWS Key Management Service (KMS) key used by the capacity provider.voidsetPermissionsConfig(IResolvable value) IAM permissions configuration for the capacity provider.voidIAM permissions configuration for the capacity provider.voidA list of tags to apply to the capacity provider.voidsetVpcConfig(IResolvable value) VPC configuration for the capacity provider.voidVPC configuration for the capacity provider.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods 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, @NotNull CfnCapacityProviderProps props) Create a newAWS::Lambda::CapacityProvider.- 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. This parameter is required.
-
-
Method Details
-
arnForCapacityProvider
@Stability(Stable) @NotNull public static String arnForCapacityProvider(@NotNull ICapacityProviderRef resource) - Parameters:
resource- This parameter is required.
-
isCfnCapacityProvider
Checks whether the given object is a CfnCapacityProvider.- Parameters:
x- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin 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:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
The Amazon Resource Name (ARN) of the capacity provider.This is a read-only property that is automatically generated when the capacity provider is created.
-
getAttrState
The current state of the capacity provider.Indicates whether the provider is being created, is active and ready for use, has failed, or is being deleted.
-
getCapacityProviderRef
A reference to a CapacityProvider resource.- Specified by:
getCapacityProviderRefin interfaceICapacityProviderRef
-
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManagerin interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getPermissionsConfig
IAM permissions configuration for the capacity provider.Returns union: either
IResolvableorCfnCapacityProvider.CapacityProviderPermissionsConfigProperty -
setPermissionsConfig
IAM permissions configuration for the capacity provider. -
setPermissionsConfig
@Stability(Stable) public void setPermissionsConfig(@NotNull CfnCapacityProvider.CapacityProviderPermissionsConfigProperty value) IAM permissions configuration for the capacity provider. -
getVpcConfig
VPC configuration for the capacity provider.Returns union: either
IResolvableorCfnCapacityProvider.CapacityProviderVpcConfigProperty -
setVpcConfig
VPC configuration for the capacity provider. -
setVpcConfig
@Stability(Stable) public void setVpcConfig(@NotNull CfnCapacityProvider.CapacityProviderVpcConfigProperty value) VPC configuration for the capacity provider. -
getCapacityProviderName
The name of the capacity provider. -
setCapacityProviderName
The name of the capacity provider. -
getCapacityProviderScalingConfig
The scaling configuration for the capacity provider.Returns union: either
IResolvableorCfnCapacityProvider.CapacityProviderScalingConfigProperty -
setCapacityProviderScalingConfig
The scaling configuration for the capacity provider. -
setCapacityProviderScalingConfig
@Stability(Stable) public void setCapacityProviderScalingConfig(@Nullable CfnCapacityProvider.CapacityProviderScalingConfigProperty value) The scaling configuration for the capacity provider. -
getInstanceRequirements
Specifications for the types of EC2 instances that the capacity provider can use.Returns union: either
IResolvableorCfnCapacityProvider.InstanceRequirementsProperty -
setInstanceRequirements
Specifications for the types of EC2 instances that the capacity provider can use. -
setInstanceRequirements
@Stability(Stable) public void setInstanceRequirements(@Nullable CfnCapacityProvider.InstanceRequirementsProperty value) Specifications for the types of EC2 instances that the capacity provider can use. -
getKmsKeyArn
The ARN of the AWS Key Management Service (KMS) key used by the capacity provider. -
setKmsKeyArn
The ARN of the AWS Key Management Service (KMS) key used by the capacity provider. -
getTags
A list of tags to apply to the capacity provider. -
setTags
A list of tags to apply to the capacity provider.
-