I have an existing AWS Lambda (created via CloudFormation) that I would like to now modify to have a Dead Letter Queue. Essentially this allows me to re-configure my Lambda such that if it fails to process/consume an SQS message during execution, AWS will automagically publish the message to a "Dead Letter Queue" (DLQ) of my choosing.
For the life of me I can't figure out how to add:
"DeadLetterConfig": {
"TargetArn": "my-queues-ARN"
}
to my Lambdas CF configuration like it shows in that linked article (above). The closest I was able to do was:
- Select Manage this stack link on the Lambdas main page:
- This opened up the CF Stack configuration, and if you scroll all the way down to the bottom it allows you to Create a new Change Set:
- From inside the Create Change Set screen, you can edit the stack template (inserting the
DeadLetterConfig
JSON above). However when I try to create the Change Set it complains about the IAM role I'm using:
Any ideas if I'm on the right path here, or where I'm going awry? Thanks in advance!