Is message queuing possible in mqtt?

0

in aws iot core mqtt It is linked as server -> aws iot broker -> device. on the server topic: test/topic1 payload : { "command": "go", "sendDt": "2024-01-23 00:55:04.458" } sending. When the server published the message, the device was not connected. Then, the device connects to the broker and subscribes to topic: test/topic1. Is there a way to receive the message sent from the server at this time?

質問済み 4ヶ月前147ビュー
1回答
0

Hi. Depending on the details of what you're trying to achieve, you have several ways you could achieve this: persistent sessions, retained messages, or shadows.

https://docs.aws.amazon.com/iot/latest/developerguide/mqtt.html#mqtt-persistent-sessions https://docs.aws.amazon.com/iot/latest/developerguide/mqtt.html#mqtt-retain https://docs.aws.amazon.com/iot/latest/developerguide/iot-device-shadows.html https://docs.aws.amazon.com/iot/latest/developerguide/mqtt.html#mqtt-retain-persist https://docs.aws.amazon.com/iot/latest/developerguide/mqtt.html#mqtt-retain-shadow

Persistent sessions (with QoS 1 for the outgoing message) would appeal as a good fit to what you described. However, retained messages or shadows may be more suitable, depending on factors such as message expiry requirements and account limits: https://docs.aws.amazon.com/general/latest/gr/iot-core.html#message-broker-limits

profile pictureAWS
エキスパート
Greg_B
回答済み 4ヶ月前
profile pictureAWS
エキスパート
レビュー済み 4ヶ月前

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

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

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

関連するコンテンツ