question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add explicit support for request/response communication pattern (device to application)

See original GitHub issue

This issue is about a use case where a device sends a request message and expects a corresponding response from a northbound application.

Such a scenario can already be implemented with Hono. The device can send a telemetry/event message with a correlation id property/parameter and with a ttd parameter (signaling its readiness to receive a command message). The northbound application can send a one-way command message as response, including the given correlation id. Upon receiving the command message, the device can correlate the message to its initial telemetry/event message using the correlation id.

However, such a solution is not very intuitive and requires manual correlation of the messages.

Therefore it would be good to explore the feasibility of adding explicit support for such a communication pattern, including correlation support and matching endpoint names.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:3
  • Comments:14 (12 by maintainers)

github_iconTop GitHub Comments

2reactions
avgustinmmcommented, Sep 18, 2019

I’m not sure if the Ditto shall implement push state. This could be tricky. In order to push state, Ditto shall do that via commands (the only way Hono supports).

  • What command will Ditto call? Shall there be a specified push (e.g. Vorto feature with push operation)?
  • How shall Ditto know if the device support push command?
  • Shall that be bulk command (e.g. push all changes) or one by one (order of apply may matter).
  • MOST important: Is the device always able to execute a push? If device could request push info it could apply it whenever it likes. Could try few times if needed. If Ditto pushes info and device isn’t ready, error may occur. Shall Ditto retry?
2reactions
sophokles73commented, Sep 16, 2019

This makes it impossible to implement the desired/reported pattern for configuration values, as it is possible for instance in AWS IoT.

FMPOV Ditto would need to be responsible to push the desired state to a device while the device is responsible to report its current state. However, Ditto needs to support the desired/reported states in order for that to work. I do not think that a device should need to pull the desired state from the back end. We deliberately provided means for devices to signal their intention to receive messages from the back end applications. Ditto would simply need to use it as a trigger to push the desired state to the device using a command …

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support MQTT 5 in MQTT protocol adapter #2955 - GitHub
Would be nice to support it in the MQTT adapter. ... Add explicit support for request/response communication pattern (device to application) ...
Read more >
A Communication Model to Integrate the Request-Response ...
This paper analyzes the strengths and weaknesses of both the RR and PubSub paradigms to support communications in ubiquitous systems and proposes an ......
Read more >
Command and control - request-response - Bosch IoT Device ...
Request-response commands are sent from a connected business solution through the Bosch IoT Things and Bosch IoT Hub to a connected device.
Read more >
Request-Reply | Enterprise Integration Patterns - InformIT
When two applications communicate via Messaging (53), ... SOAP 1.2 introduces an explicit Request-Response Message Exchange pattern [SOAP ...
Read more >
Motivations - RSocket
The pieces need to communicate reliably and support rapid, independent evolution. ... messaging and embrace communication patterns beyond request/response.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found