CfnConnectionFunctionProps Struct
Properties for defining a CfnConnectionFunction.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cloudfront as cloudfront } from 'aws-cdk-lib';
const cfnConnectionFunctionProps: cloudfront.CfnConnectionFunctionProps = {
connectionFunctionCode: 'connectionFunctionCode',
connectionFunctionConfig: {
comment: 'comment',
runtime: 'runtime',
// the properties below are optional
keyValueStoreAssociations: [{
keyValueStoreArn: 'keyValueStoreArn',
}],
},
name: 'name',
// the properties below are optional
autoPublish: false,
tags: [{
key: 'key',
value: 'value',
}],
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_cloudfront as cloudfront
cfn_connection_function_props = cloudfront.CfnConnectionFunctionProps(
connection_function_code="connectionFunctionCode",
connection_function_config=cloudfront.CfnConnectionFunction.ConnectionFunctionConfigProperty(
comment="comment",
runtime="runtime",
# the properties below are optional
key_value_store_associations=[cloudfront.CfnConnectionFunction.KeyValueStoreAssociationProperty(
key_value_store_arn="keyValueStoreArn"
)]
),
name="name",
# the properties below are optional
auto_publish=False,
tags=[CfnTag(
key="key",
value="value"
)]
)
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.cloudfront.*;
CfnConnectionFunctionProps cfnConnectionFunctionProps = CfnConnectionFunctionProps.builder()
.connectionFunctionCode("connectionFunctionCode")
.connectionFunctionConfig(ConnectionFunctionConfigProperty.builder()
.comment("comment")
.runtime("runtime")
// the properties below are optional
.keyValueStoreAssociations(List.of(KeyValueStoreAssociationProperty.builder()
.keyValueStoreArn("keyValueStoreArn")
.build()))
.build())
.name("name")
// the properties below are optional
.autoPublish(false)
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.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.CloudFront;
var cfnConnectionFunctionProps = new CfnConnectionFunctionProps {
ConnectionFunctionCode = "connectionFunctionCode",
ConnectionFunctionConfig = new ConnectionFunctionConfigProperty {
Comment = "comment",
Runtime = "runtime",
// the properties below are optional
KeyValueStoreAssociations = new [] { new KeyValueStoreAssociationProperty {
KeyValueStoreArn = "keyValueStoreArn"
} }
},
Name = "name",
// the properties below are optional
AutoPublish = false,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
};
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"
cfnConnectionFunctionProps := &CfnConnectionFunctionProps{
ConnectionFunctionCode: jsii.String("connectionFunctionCode"),
ConnectionFunctionConfig: &ConnectionFunctionConfigProperty{
Comment: jsii.String("comment"),
Runtime: jsii.String("runtime"),
// the properties below are optional
KeyValueStoreAssociations: []interface{}{
&KeyValueStoreAssociationProperty{
KeyValueStoreArn: jsii.String("keyValueStoreArn"),
},
},
},
Name: jsii.String("name"),
// the properties below are optional
AutoPublish: jsii.Boolean(false),
Tags: []CfnTag{
&CfnTag{
Key: jsii.String("key"),
Value: jsii.String("value"),
},
},
}
Properties
autoPublishoptionalboolean | IResolvableauto_publishoptionaltyping.Union[bool, IResolvable]autoPublishoptionalBooleanAutoPublishoptionalboolAutoPublishoptionalinterface{}= false#A flag that determines whether to automatically publish the function to the `LIVE` stage when it’s created.
To automatically publish to the LIVE stage, set this property to true .
connectionFunctionCodestringconnection_function_codestrconnectionFunctionCodeStringConnectionFunctionCodestringConnectionFunctionCode*stringrequired#The code for the connection function.
connectionFunctionConfigIResolvable | CfnConnectionFunction.ConnectionFunctionConfigPropertyconnection_function_configtyping.Union[IResolvable, ConnectionFunctionConfigProperty]connectionFunctionConfigIResolvableConnectionFunctionConfigIResolvableConnectionFunctionConfiginterface{}required#Contains configuration information about a CloudFront function.
The connection function name.