-
Notifications
You must be signed in to change notification settings - Fork 17
/
CfnBucket_NotificationConfigurationProperty.go
99 lines (96 loc) · 4.71 KB
/
CfnBucket_NotificationConfigurationProperty.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
package awss3
// Describes the notification configuration for an Amazon S3 bucket.
//
// > 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](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-permission.html) and [Granting Permissions to Publish Event Notification Messages to a Destination](https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html#grant-destinations-permissions-to-s3) .
//
// Example:
// // 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"
//
// notificationConfigurationProperty := &NotificationConfigurationProperty{
// EventBridgeConfiguration: &EventBridgeConfigurationProperty{
// EventBridgeEnabled: jsii.Boolean(false),
// },
// LambdaConfigurations: []interface{}{
// &LambdaConfigurationProperty{
// Event: jsii.String("event"),
// Function: jsii.String("function"),
//
// // the properties below are optional
// Filter: &NotificationFilterProperty{
// S3Key: &S3KeyFilterProperty{
// Rules: []interface{}{
// &FilterRuleProperty{
// Name: jsii.String("name"),
// Value: jsii.String("value"),
// },
// },
// },
// },
// },
// },
// QueueConfigurations: []interface{}{
// &QueueConfigurationProperty{
// Event: jsii.String("event"),
// Queue: jsii.String("queue"),
//
// // the properties below are optional
// Filter: &NotificationFilterProperty{
// S3Key: &S3KeyFilterProperty{
// Rules: []interface{}{
// &FilterRuleProperty{
// Name: jsii.String("name"),
// Value: jsii.String("value"),
// },
// },
// },
// },
// },
// },
// TopicConfigurations: []interface{}{
// &TopicConfigurationProperty{
// Event: jsii.String("event"),
// Topic: jsii.String("topic"),
//
// // the properties below are optional
// Filter: &NotificationFilterProperty{
// S3Key: &S3KeyFilterProperty{
// Rules: []interface{}{
// &FilterRuleProperty{
// Name: jsii.String("name"),
// Value: jsii.String("value"),
// },
// },
// },
// },
// },
// },
// }
//
// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfiguration.html
//
type CfnBucket_NotificationConfigurationProperty struct {
// Enables delivery of events to Amazon EventBridge.
// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfiguration.html#cfn-s3-bucket-notificationconfiguration-eventbridgeconfiguration
//
EventBridgeConfiguration interface{} `field:"optional" json:"eventBridgeConfiguration" yaml:"eventBridgeConfiguration"`
// Describes the AWS Lambda functions to invoke and the events for which to invoke them.
// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfiguration.html#cfn-s3-bucket-notificationconfiguration-lambdaconfigurations
//
LambdaConfigurations interface{} `field:"optional" json:"lambdaConfigurations" yaml:"lambdaConfigurations"`
// The Amazon Simple Queue Service queues to publish messages to and the events for which to publish messages.
// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfiguration.html#cfn-s3-bucket-notificationconfiguration-queueconfigurations
//
QueueConfigurations interface{} `field:"optional" json:"queueConfigurations" yaml:"queueConfigurations"`
// The topic to which notifications are sent and the events for which notifications are generated.
// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-notificationconfiguration.html#cfn-s3-bucket-notificationconfiguration-topicconfigurations
//
TopicConfigurations interface{} `field:"optional" json:"topicConfigurations" yaml:"topicConfigurations"`
}