Hi all,
I would like to share some thoughts and start a discussion about command and control, since it is a big topic for Hono after we created the first release, now. We have a draft API spec. at
https://www.eclipse.org/hono/api/command-and-control-api/.
From the API level this is a very good starting point, but we should discuss the implementation options and what expectations are behind it. Also what should and could be the targets (and limitations) for a first implementation.
I see the following main use cases for command and control (to be discussed).
send a direct command to a device
send a new/changed configuration to a device
For 1) I would expect the device to be connected while the command is send - if not, the command will fail. The response is send back synchronously.
For 2) it is not needed, that the device is connected all the time. The device can connect in time intervals. The command could be long running. Commands need to be buffered and the response is complicated - a lifecycle with states for Hono and the sender of the command need to be handled.
It seems to be easier to start with 1), since we do not need to care about lifecycle/state and the persistence. But maybe we have some other problems - if we do this straight with AMQP, we could get in trouble with the number of links needed and also I am not sure about guaranteed ordering.
I have created overview graphics for both scenarios: Direct and brokered.
I would be very interested in your opinions about the scenarios as well as the potential problems and implementation options. Especially in regards to the AMQP components - the Dispatch Router and the Artemis broker - what are your expectations?
Best regards, Marc