Class CfnAlias
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.CfnAlias
- All Implemented Interfaces:
IInspectable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-12-06T14:43:21.167Z")
@Stability(Stable)
public class CfnAlias
extends CfnResource
implements IInspectable
The
AWS::Lambda::Alias
resource creates an alias for a Lambda function version. Use aliases to provide clients with a function identifier that you can update to invoke a different version.
You can also map an alias to split invocation requests between two versions. Use the RoutingConfig
parameter to specify a second version and the percentage of invocation requests that it receives.
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.*; CfnAlias cfnAlias = CfnAlias.Builder.create(this, "MyCfnAlias") .functionName("functionName") .functionVersion("functionVersion") .name("name") // the properties below are optional .description("description") .provisionedConcurrencyConfig(ProvisionedConcurrencyConfigurationProperty.builder() .provisionedConcurrentExecutions(123) .build()) .routingConfig(AliasRoutingConfigurationProperty.builder() .additionalVersionWeights(List.of(VersionWeightProperty.builder() .functionVersion("functionVersion") .functionWeight(123) .build())) .build()) .build();
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
The traffic-shifting configuration of a Lambda function alias.static final class
A fluent builder forCfnAlias
.static interface
A provisioned concurrency configuration for a function's alias.static interface
The traffic-shifting configuration of a Lambda function alias.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
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionprotected
CfnAlias
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnAlias
(software.amazon.jsii.JsiiObjectRef objRef) CfnAlias
(software.constructs.Construct scope, String id, CfnAliasProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe Amazon Resource Name (ARN) of the alias.A description of the alias.The name or ARN of the Lambda function.The function version that the alias invokes.getName()
The name of the alias.Specifies a provisioned concurrency configuration for a function's alias.The routing configuration of the alias.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setDescription
(String value) A description of the alias.void
setFunctionName
(String value) The name or ARN of the Lambda function.void
setFunctionVersion
(String value) The function version that the alias invokes.void
The name of the alias.void
Specifies a provisioned concurrency configuration for a function's alias.void
Specifies a provisioned concurrency configuration for a function's alias.void
setRoutingConfig
(IResolvable value) The routing configuration of the alias.void
The routing configuration of the alias.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
-
CfnAlias
protected CfnAlias(software.amazon.jsii.JsiiObjectRef objRef) -
CfnAlias
protected CfnAlias(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnAlias
@Stability(Stable) public CfnAlias(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnAliasProps 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. 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.
-
getAttrAliasArn
The Amazon Resource Name (ARN) of the alias. -
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getFunctionName
The name or ARN of the Lambda function. -
setFunctionName
The name or ARN of the Lambda function. -
getFunctionVersion
The function version that the alias invokes. -
setFunctionVersion
The function version that the alias invokes. -
getName
The name of the alias. -
setName
The name of the alias. -
getDescription
A description of the alias. -
setDescription
A description of the alias. -
getProvisionedConcurrencyConfig
Specifies a provisioned concurrency configuration for a function's alias. -
setProvisionedConcurrencyConfig
Specifies a provisioned concurrency configuration for a function's alias. -
setProvisionedConcurrencyConfig
@Stability(Stable) public void setProvisionedConcurrencyConfig(@Nullable CfnAlias.ProvisionedConcurrencyConfigurationProperty value) Specifies a provisioned concurrency configuration for a function's alias. -
getRoutingConfig
The routing configuration of the alias. -
setRoutingConfig
The routing configuration of the alias. -
setRoutingConfig
@Stability(Stable) public void setRoutingConfig(@Nullable CfnAlias.AliasRoutingConfigurationProperty value) The routing configuration of the alias.
-