Add delta support to orchestrator #1489
Open
+239
−58
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The primary point of this change is that it re-enables firmware delta
support.
It also tries to alleviate the need for generating a ton of unused
delta files.
It tackles this by doing something that has already been discussed
and which I think is generally agreed upon which is give the
orchestrator the job of telling a newly connected device to update.
That removes the instant update on connect. We could reintroduce a
mechanism for the orchestrator to react to new devices if we like.
When a device joins the channel it will report it's firmware version
to the orchestrator. This gives the orchestrator the chance to fire
off Oban jobs for new firmware deltas. At the same time it will store
a list of firmware versions that have been processed or are
processing. This alleviates the need for repeated lookups.
Firmware versions that are in processing are excluded from registry
lookups to distribute updates.
When deltas are done generating the orchestrator will receive an
event causing a refresh of the delta status state.