Joseph D.
Joseph D.

Reputation: 12174

How to test Lambda publishing a message via AWS cloud console?

I have a problem with testing the Lambda destination - SNS.

Message is not published after Lambda has successfully run. I invoked the lambda in AWS cloud console using a test event.

Destination and topics are properly configured.

enter image description here

enter image description here



Side note, I can programmatically publish a message via sns.publish().


Question:
Is there a way to publish a message automatically to SNS once Lambda has successfully run via AWS console (using a test event)?

Upvotes: 0

Views: 138

Answers (1)

fedonev
fedonev

Reputation: 25669

No. The console "synchronously invokes your function with the test event". It must be invoked asynchronously to use the destinations.

Call the lambda invoke API with --invocation-type Event for asynchronous invocation.

Upvotes: 1

Related Questions