Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AWS Lambda to SNS response after invocation

Lambda L1 is subscribed to SNS S1.

L1 returns the status code and a message every time it is invoked

I can check L1 response every time it is invoked independently but when I invoke L1 by publishing a message to S1, how can I verify the message returned from L1?

I need to do this programmatically in java.. Any pointers are appreciated

like image 254
lakshay Avatar asked Feb 07 '26 19:02

lakshay


1 Answers

Amazon SNS publishes messages to subscribers. Once a message is successfully sent to a subscriber (eg to AWS Lambda to trigger a Lambda function), it does not wait for a response.

Therefore, it is not possible to view the response code of a Lambda function triggered by SNS.

You could look in the CloudWatch Log that is generated by the Lambda function, but you might need to insert code to push the response to the log (eg via a Print statement).

like image 127
John Rotenstein Avatar answered Feb 09 '26 11:02

John Rotenstein



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!