clearlinux / mixer-tools

Software update mixer and related tools
Apache License 2.0
28 stars 37 forks source link

`mixer build delta-packs` can break delta creations when using `--previous-versions` #779

Open phmccarty opened 2 years ago

phmccarty commented 2 years ago

When running mixer build delta-packs --previous-versions=N, packs will be generated for the previous N versions, as expected. But the delta list and delta creations for each previous version are processed independently, and in parallel, which often leads to unexpected bsdiff delta creation/application failures when delta lists overlap (i.e. contain duplicates if the lists were combined).

Instead, I think it would be better for mixer to (a) compute the delta list for the previous N versions (de-duplicated), (b) create all deltas from the delta list in parallel, and finally (c) create the delta packs.

The entrypoint for this process is: https://github.com/clearlinux/mixer-tools/blob/8e8ba2d8e3d2eb8671c3c98a8f476266f616d4cf/builder/builder.go#L591