MQTT Communication # Greengrass V2

0

Hi Team,

Is it possible to respond to same device who has send message to IoT Core in Greengrass v2 ??

My scenario is I am sending one message on AWS IoT Core and that message has been routed via rules to make a call to Lambda. I have some logical implementation in lambda which would return pre-signed URL which I want to send back to same thing/device who has sent message to IoT Core. Since, I have multiple devices/things, I don't want that message should be accept by other devices.

Is there any provision to handle such scenario ??

已提问 1 年前230 查看次数
1 回答
0
已接受的回答

You should be able to get a thing name from an env variable AWS_IOT_THING_NAME inside a GGv2 component and construct a topic which looks something like this AWS_IOT_THING_NAME/message/response where you can send the back the info to. You will also have the info from which topic the message got received into in a lambda function payload, thus you can know where to send it back.

已回答 1 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则