Call Lamda function from AWS iot

0

I am trying to call Lamda function from iot. I can see the subscribed message on MQTT Test Client sent from iot device. But not able to call Lamda function. I followed the tutorial https://docs.aws.amazon.com/iot/latest/developerguide/iot-lambda-rule.html#iot-lambda-rule-test-rule I have also attached cloudwatch logs under error action to the AWS IoT rule. Still, nothing was logged. I am not sure if the connection is being established between AWS IoT and Lamda. However, I am able to call Lamda function successfully from API Gateway.

  • can you try put '#' as topic in the rule and SELECT * FROM "#" and see if the lambda will run. '#' covers all topics. This will tell if rule is being executed.

質問済み 1年前208ビュー
1回答
1
承認された回答

Hi. I recommend you enable IoT logging and look for the RuleExecution event type: https://docs.aws.amazon.com/iot/latest/developerguide/diagnosing-rules.html

This will confirm or deny whether your rule is running, and tell if you if it's suffering any errors when executing the Lambda action.

profile pictureAWS
エキスパート
Greg_B
回答済み 1年前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン