Class CfnAutoScalingConfiguration
- All Implemented Interfaces:
IInspectable,IAutoScalingConfigurationRef,IEnvironmentAware,ITaggableV2,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
AWS::AppRunner::AutoScalingConfiguration resource in an AWS CloudFormation template.
The AWS::AppRunner::AutoScalingConfiguration resource is an AWS App Runner resource type that specifies an App Runner automatic scaling configuration.
App Runner requires this resource to set non-default auto scaling settings for instances used to process the web requests. You can share an auto scaling configuration across multiple services.
Create multiple revisions of a configuration by calling this action multiple times using the same AutoScalingConfigurationName . The call returns incremental AutoScalingConfigurationRevision values. When you create a service and configure an auto scaling configuration resource, the service uses the latest active revision of the auto scaling configuration by default. You can optionally configure the service to use a specific revision.
Configure a higher MinSize to increase the spread of your App Runner service over more Availability Zones in the AWS Region . The tradeoff is a higher minimal cost.
Configure a lower MaxSize to control your cost. The tradeoff is lower responsiveness during peak demand.
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.apprunner.*;
CfnAutoScalingConfiguration cfnAutoScalingConfiguration = CfnAutoScalingConfiguration.Builder.create(this, "MyCfnAutoScalingConfiguration")
.autoScalingConfigurationName("autoScalingConfigurationName")
.maxConcurrency(123)
.maxSize(123)
.minSize(123)
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnAutoScalingConfiguration.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.apprunner.IAutoScalingConfigurationRef
IAutoScalingConfigurationRef.Jsii$Default, IAutoScalingConfigurationRef.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
ConstructorsModifierConstructorDescriptionprotectedCfnAutoScalingConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnAutoScalingConfiguration(software.amazon.jsii.JsiiObjectRef objRef) CfnAutoScalingConfiguration(software.constructs.Construct scope, String id) Create a newAWS::AppRunner::AutoScalingConfiguration.CfnAutoScalingConfiguration(software.constructs.Construct scope, String id, CfnAutoScalingConfigurationProps props) Create a newAWS::AppRunner::AutoScalingConfiguration. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringThe Amazon Resource Name (ARN) of this auto scaling configuration.The revision of this auto scaling configuration.It's set to true for the configuration with the highestRevisionamong all configurations that share the sameAutoScalingConfigurationName.The customer-provided auto scaling configuration name.A reference to a AutoScalingConfiguration resource.Tag Manager which manages the tags for this resource.The maximum number of concurrent requests that an instance processes.The maximum number of instances that a service scales up to.The minimum number of instances that App Runner provisions for a service.getTags()A list of metadata items that you can associate with your auto scaling configuration resource.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidThe customer-provided auto scaling configuration name.voidsetMaxConcurrency(Number value) The maximum number of concurrent requests that an instance processes.voidsetMaxSize(Number value) The maximum number of instances that a service scales up to.voidsetMinSize(Number value) The minimum number of instances that App Runner provisions for a service.voidA list of metadata items that you can associate with your auto scaling configuration resource.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
-
CfnAutoScalingConfiguration
protected CfnAutoScalingConfiguration(software.amazon.jsii.JsiiObjectRef objRef) -
CfnAutoScalingConfiguration
protected CfnAutoScalingConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnAutoScalingConfiguration
@Stability(Stable) public CfnAutoScalingConfiguration(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable CfnAutoScalingConfigurationProps props) Create a newAWS::AppRunner::AutoScalingConfiguration.- 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.
-
CfnAutoScalingConfiguration
@Stability(Stable) public CfnAutoScalingConfiguration(@NotNull software.constructs.Construct scope, @NotNull String id) Create a newAWS::AppRunner::AutoScalingConfiguration.- 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
-
arnForAutoScalingConfiguration
@Stability(Stable) @NotNull public static String arnForAutoScalingConfiguration(@NotNull IAutoScalingConfigurationRef resource) - Parameters:
resource- 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.
-
getAttrAutoScalingConfigurationArn
The Amazon Resource Name (ARN) of this auto scaling configuration. -
getAttrAutoScalingConfigurationRevision
The revision of this auto scaling configuration.It's unique among all the active configurations that share the same
AutoScalingConfigurationName. -
getAttrLatest
It's set to true for the configuration with the highestRevisionamong all configurations that share the sameAutoScalingConfigurationName.It's set to false otherwise. App Runner temporarily doubles the number of provisioned instances during deployments, to maintain the same capacity for both old and new code.
-
getAutoScalingConfigurationRef
@Stability(Stable) @NotNull public AutoScalingConfigurationReference getAutoScalingConfigurationRef()A reference to a AutoScalingConfiguration resource.- Specified by:
getAutoScalingConfigurationRefin interfaceIAutoScalingConfigurationRef
-
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManagerin interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getAutoScalingConfigurationName
The customer-provided auto scaling configuration name. -
setAutoScalingConfigurationName
The customer-provided auto scaling configuration name. -
getMaxConcurrency
The maximum number of concurrent requests that an instance processes. -
setMaxConcurrency
The maximum number of concurrent requests that an instance processes. -
getMaxSize
The maximum number of instances that a service scales up to. -
setMaxSize
The maximum number of instances that a service scales up to. -
getMinSize
The minimum number of instances that App Runner provisions for a service. -
setMinSize
The minimum number of instances that App Runner provisions for a service. -
getTags
A list of metadata items that you can associate with your auto scaling configuration resource. -
setTags
A list of metadata items that you can associate with your auto scaling configuration resource.
-