Skip to content

Commit 36bb696

Browse files
authored
feat(sns): delivery status logging configuration (#28433)
Recently Amazon SNS supports configuring delivery status logging with AWS CloudFormation. https://aws.amazon.com/about-aws/whats-new/2023/12/amazon-sns-configuring-delivery-status-logging-aws-cloudformation/?nc1=h_ls This is also configurable via L1 CfnTopic construct. https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_sns.CfnTopic.html This PR introduces the feature to add delivery status logging configuration via L2 Topic construct. Closes #21971 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent 4f88db6 commit 36bb696

File tree

10 files changed

+523
-34
lines changed

10 files changed

+523
-34
lines changed

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/SNSInteg.assets.json

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/SNSInteg.template.json

+63
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,24 @@
3838
"MyTopic86869434": {
3939
"Type": "AWS::SNS::Topic",
4040
"Properties": {
41+
"DeliveryStatusLogging": [
42+
{
43+
"FailureFeedbackRoleArn": {
44+
"Fn::GetAtt": [
45+
"FeedbackRoleCAF84E5C",
46+
"Arn"
47+
]
48+
},
49+
"Protocol": "http/s",
50+
"SuccessFeedbackRoleArn": {
51+
"Fn::GetAtt": [
52+
"FeedbackRoleCAF84E5C",
53+
"Arn"
54+
]
55+
},
56+
"SuccessFeedbackSampleRate": "50"
57+
}
58+
],
4159
"DisplayName": "fooDisplayName",
4260
"KmsMasterKeyId": {
4361
"Fn::GetAtt": [
@@ -47,6 +65,51 @@
4765
},
4866
"TopicName": "fooTopic"
4967
}
68+
},
69+
"FeedbackRoleCAF84E5C": {
70+
"Type": "AWS::IAM::Role",
71+
"Properties": {
72+
"AssumeRolePolicyDocument": {
73+
"Statement": [
74+
{
75+
"Action": "sts:AssumeRole",
76+
"Effect": "Allow",
77+
"Principal": {
78+
"Service": "sns.amazonaws.com"
79+
}
80+
}
81+
],
82+
"Version": "2012-10-17"
83+
}
84+
}
85+
},
86+
"Policy23B91518": {
87+
"Type": "AWS::IAM::ManagedPolicy",
88+
"Properties": {
89+
"Description": "",
90+
"Path": "/",
91+
"PolicyDocument": {
92+
"Statement": [
93+
{
94+
"Action": [
95+
"logs:CreateLogGroup",
96+
"logs:CreateLogStream",
97+
"logs:PutLogEvents",
98+
"logs:PutMetricFilter",
99+
"logs:PutRetentionPolicy"
100+
],
101+
"Effect": "Allow",
102+
"Resource": "*"
103+
}
104+
],
105+
"Version": "2012-10-17"
106+
},
107+
"Roles": [
108+
{
109+
"Ref": "FeedbackRoleCAF84E5C"
110+
}
111+
]
112+
}
50113
}
51114
},
52115
"Parameters": {

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/cdk.out

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/integ.json

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/manifest.json

+21-8
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-sns/test/integ.sns.js.snapshot/tree.json

+149-18
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)