Show / Hide Table of Contents

Interface CfnBucket.INotificationConfigurationProperty

Describes the notification configuration for an Amazon S3 bucket.

Namespace: Amazon.CDK.AWS.S3
Assembly: Amazon.CDK.AWS.S3.dll
Syntax (csharp)
public interface INotificationConfigurationProperty
Syntax (vb)
Public Interface INotificationConfigurationProperty
Remarks

If you create the target resource and related permissions in the same template, you might have a circular dependency.

For example, you might use the AWS::Lambda::Permission resource to grant the bucket permission to invoke an AWS Lambda function. However, AWS CloudFormation can't create the bucket until the bucket has permission to invoke the function ( AWS CloudFormation checks whether the bucket can invoke the function). If you're using Refs to pass the bucket name, this leads to a circular dependency.

To avoid this dependency, you can create all resources without specifying the notification configuration. Then, update the stack with a notification configuration.

For more information on permissions, see AWS::Lambda::Permission and Granting Permissions to Publish Event Notification Messages to a Destination .

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfig.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3;

NotificationConfigurationProperty notificationConfigurationProperty = new NotificationConfigurationProperty {
    EventBridgeConfiguration = new EventBridgeConfigurationProperty {
        EventBridgeEnabled = false
    },
    LambdaConfigurations = new [] { new LambdaConfigurationProperty {
        Event = "event",
        Function = "function",

        // the properties below are optional
        Filter = new NotificationFilterProperty {
            S3Key = new S3KeyFilterProperty {
                Rules = new [] { new FilterRuleProperty {
                    Name = "name",
                    Value = "value"
                } }
            }
        }
    } },
    QueueConfigurations = new [] { new QueueConfigurationProperty {
        Event = "event",
        Queue = "queue",

        // the properties below are optional
        Filter = new NotificationFilterProperty {
            S3Key = new S3KeyFilterProperty {
                Rules = new [] { new FilterRuleProperty {
                    Name = "name",
                    Value = "value"
                } }
            }
        }
    } },
    TopicConfigurations = new [] { new TopicConfigurationProperty {
        Event = "event",
        Topic = "topic",

        // the properties below are optional
        Filter = new NotificationFilterProperty {
            S3Key = new S3KeyFilterProperty {
                Rules = new [] { new FilterRuleProperty {
                    Name = "name",
                    Value = "value"
                } }
            }
        }
    } }
};

Synopsis

Properties

EventBridgeConfiguration

Enables delivery of events to Amazon EventBridge.

LambdaConfigurations

Describes the AWS Lambda functions to invoke and the events for which to invoke them.

QueueConfigurations

The Amazon Simple Queue Service queues to publish messages to and the events for which to publish messages.

TopicConfigurations

The topic to which notifications are sent and the events for which notifications are generated.

Properties

EventBridgeConfiguration

Enables delivery of events to Amazon EventBridge.

virtual object EventBridgeConfiguration { get; }
Property Value

System.Object

Remarks

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfig.html#cfn-s3-bucket-notificationconfig-eventbridgeconfig

LambdaConfigurations

Describes the AWS Lambda functions to invoke and the events for which to invoke them.

virtual object LambdaConfigurations { get; }
Property Value

System.Object

Remarks

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfig.html#cfn-s3-bucket-notificationconfig-lambdaconfig

QueueConfigurations

The Amazon Simple Queue Service queues to publish messages to and the events for which to publish messages.

virtual object QueueConfigurations { get; }
Property Value

System.Object

Remarks

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfig.html#cfn-s3-bucket-notificationconfig-queueconfig

TopicConfigurations

The topic to which notifications are sent and the events for which notifications are generated.

virtual object TopicConfigurations { get; }
Property Value

System.Object

Remarks

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfig.html#cfn-s3-bucket-notificationconfig-topicconfig

Back to top Generated by DocFX