Skip to content

OTA upload: rework into a single command execution with partial results

In it's current state, it is impossible to perform OTA upload without a fully compatible network, meaning that if one device is not compatible with uploaded handler or plugin, the entire process will not start. The same happens if even a single device is offline.

Compound the OTA update steps into a single request that executes all three steps.

  • I think this is a better approach, given that Daemon does not retain state of the update process between requests, it only makes sense that we would perform OTA update in one request. The idea is that we still extend the API and add selectedNodes, but we only use it for the initial selection of nodes. If no nodes are specified, we start with the entire network as a set and remove nodes in each stage (online nodes => compatible online nodes => verified compatible online nodes => result). In the response, we provide a report for each node and why the process failed for that particular device (it was offline, it is not compatible, verification failed, loading the code failed). If the request is sent with selected nodes, the subset logic will stay the same for the most part, but we also add "selected" qualifier.
Edited by Karel Hanák