AliasRoutingConfigurationProperty Struct
The traffic-shifting configuration of a Lambda function alias.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lambda as lambda } from 'aws-cdk-lib';
const aliasRoutingConfigurationProperty: lambda.CfnAlias.AliasRoutingConfigurationProperty = {
additionalVersionWeights: [{
functionVersion: 'functionVersion',
functionWeight: 123,
}],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_lambda as lambda_
alias_routing_configuration_property = lambda.CfnAlias.AliasRoutingConfigurationProperty(
additional_version_weights=[lambda.CfnAlias.VersionWeightProperty(
function_version="functionVersion",
function_weight=123
)]
)
java
// 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.*;
AliasRoutingConfigurationProperty aliasRoutingConfigurationProperty = AliasRoutingConfigurationProperty.builder()
.additionalVersionWeights(List.of(VersionWeightProperty.builder()
.functionVersion("functionVersion")
.functionWeight(123)
.build()))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Lambda;
var aliasRoutingConfigurationProperty = new AliasRoutingConfigurationProperty {
AdditionalVersionWeights = new [] { new VersionWeightProperty {
FunctionVersion = "functionVersion",
FunctionWeight = 123
} }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
aliasRoutingConfigurationProperty := &AliasRoutingConfigurationProperty{
AdditionalVersionWeights: []interface{}{
&VersionWeightProperty{
FunctionVersion: jsii.String("functionVersion"),
FunctionWeight: jsii.Number(123),
},
},
}
Properties
additionalVersionWeightsoptionalIResolvable | IResolvable | CfnAlias.VersionWeightProperty[]additional_version_weightsoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, VersionWeightProperty]]]additionalVersionWeightsoptionalIResolvableAdditionalVersionWeightsoptionalIResolvableAdditionalVersionWeightsoptionalinterface{}#The second version, and the percentage of traffic that's routed to it.