@@ -237,24 +237,6 @@ and the following trust relationship
237237 " arn:aws:sns:{aws-region}:{aws-account-number}:spring-native-aws-lambda-function-dead-letter-topic"
238238 ]
239239 },
240- {
241- " Sid" : " SQSPermissions" ,
242- " Effect" : " Allow" ,
243- " Action" : [
244- " sqs:GetQueueAttributes" ,
245- " sqs:CreateQueue" ,
246- " sqs:DeleteQueue" ,
247- " sqs:GetQueueUrl" ,
248- " sqs:SetQueueAttributes" ,
249- " sqs:ListQueues"
250- ],
251- " Resource" : [
252- " arn:aws:sqs:{aws-region}:{aws-account-number}:spring-native-aws-lambda-function-failure-queue-dlq" ,
253- " arn:aws:sqs:{aws-region}:{aws-account-number}:spring-native-aws-lambda-function-success-queue-dlq" ,
254- " arn:aws:sqs:{aws-region}:{aws-account-number}:spring-native-aws-lambda-function-failure-queue" ,
255- " arn:aws:sqs:{aws-region}:{aws-account-number}:spring-native-aws-lambda-function-success-queue"
256- ]
257- },
258240 {
259241 " Sid" : " LambdaPermissions" ,
260242 " Effect" : " Allow" ,
@@ -333,13 +315,6 @@ cdk bootstrap aws://{aws-account-number}/{aws-region} --profile cdk \
333315we created
334316in step 4
335317
336- ** NOTE 2** : I added queues to receive messages from the functions ` onSuccess` and ` onFailure`
337- topics, so I had to add the SQS permissions to the policy. However, in production scenario I would
338- stop at the topics and let the processor applications create and subscribe the queues to the topics.
339- This way, the processor applications can be deployed independently from the function and the
340- function can be deployed independently from the processor applications. This is a good practice to
341- follow in order to have a loosely coupled architecture.
342-
343318# ### Building AWS Lambda Function from Zip
344319
345320Now that the setup is done you can deploy to AWS.
0 commit comments