aws-cdk-lib.aws_lambda.CfnVersionProps

interface CfnVersionProps

LanguageType name
.NETAmazon.CDK.AWS.Lambda.CfnVersionProps
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awslambda#CfnVersionProps
Javasoftware.amazon.awscdk.services.lambda.CfnVersionProps
Pythonaws_cdk.aws_lambda.CfnVersionProps
TypeScript aws-cdk-lib » aws_lambda » CfnVersionProps

Properties for defining a CfnVersion.

Example

// 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 cfnVersionProps: lambda.CfnVersionProps = {
  functionName: 'functionName',

  // the properties below are optional
  codeSha256: 'codeSha256',
  description: 'description',
  provisionedConcurrencyConfig: {
    provisionedConcurrentExecutions: 123,
  },
};

Properties

NameTypeDescription
functionNamestringThe name of the Lambda function.
codeSha256?stringOnly publish a version if the hash value matches the value that's specified.
description?stringA description for the version to override the description in the function configuration.
provisionedConcurrencyConfig?IResolvable | ProvisionedConcurrencyConfigurationPropertySpecifies a provisioned concurrency configuration for a function's version.

functionName

Type: string

The name of the Lambda function.

Name formats - Function name - MyFunction .

  • Function ARN - arn:aws:lambda:us-west-2:123456789012:function:MyFunction .
  • Partial ARN - 123456789012:function:MyFunction .

The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length.


codeSha256?

Type: string (optional)

Only publish a version if the hash value matches the value that's specified.

Use this option to avoid publishing a version if the function code has changed since you last updated it. Updates are not supported for this property.


description?

Type: string (optional)

A description for the version to override the description in the function configuration.

Updates are not supported for this property.


provisionedConcurrencyConfig?

Type: IResolvable | ProvisionedConcurrencyConfigurationProperty (optional)

Specifies a provisioned concurrency configuration for a function's version.

Updates are not supported for this property.