Repository navigation
Many: adjust code to unified rpmmd.Package struct (HMS-9504) - #4889
Merged
Merged
Conversation
thozza
requested review from
bcl,
croissanne and
lzap
and removed request for
a team
October 8, 2025 08:58
thozza
marked this pull request as draft
October 8, 2025 09:10
thozza
force-pushed
the
port-rpmmd-package-consolidation
branch
3 times, most recently
from
October 8, 2025 12:47
91d424d to
6a77800
Compare
This is needed for Weldr API blueprints freeze endpoint. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Weldr API endpoints depsolving and freezing blueprints were using the rpmmd.PackageSpec struct for serialization. Replace its use with weldrtypes.DepsolvedPackageInfo struct. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Don't use the rpmmd.PackageSpec type for worker server public API, specifically in the DepsolveJobResult. This will enable the unification of RPM data structures for RPM in osbuild/images and implementing a compatibility layer on osbuild-composer's side. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Add unit tests for the DepsolvedPackag type JSON (un)marshal. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Packages need to have remote location URL specified for the curl osbuild source,when generating the manifest. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Changes with 0.203.0 ---------------- - bootc: actually use `BootMode` (osbuild#1937) - Author: Simon de Vlieger, Reviewers: Achilleas Koutsou, Michael Vogt - disk: drop static UUIDs in defs (osbuild#1922) - Author: Simon de Vlieger, Reviewers: Achilleas Koutsou, Brian C. Lane - distro: add support for `default_size` to be a string (osbuild#1929) - Author: Michael Vogt, Reviewers: Achilleas Koutsou, Simon de Vlieger - fedora/minimal: riscv comps groups (osbuild#1933) - Author: Simon de Vlieger, Reviewers: Michael Vogt, Tomáš Hozza - many: make `required_partition_sizes` take datasize.Size (osbuild#1931) - Author: Michael Vogt, Reviewers: Simon de Vlieger, Tomáš Hozza — Somewhere on the Internet, 2025-10-07 --- Changes with 0.204.0 ---------------- - Catch invalid root user kickstart options early [HMS-9378] (osbuild#1879) - Author: Achilleas Koutsou, Reviewers: Simon de Vlieger, Tomáš Hozza - Support setting the `releasever` dnf variable through the Blueprint customization [HMS-9368] (osbuild#1896) - Author: Achilleas Koutsou, Reviewers: Simon de Vlieger, Tomáš Hozza - fedora/minimal: disk start offset for x86 (osbuild#1934) - Author: Simon de Vlieger, Reviewers: Michael Vogt, Tomáš Hozza - many: use datasizes.Size/disk.Offset types in disk package (osbuild#1935) - Author: Michael Vogt, Reviewers: Simon de Vlieger, Tomáš Hozza - pkg/awscloud: custom AWSTag sctruct instead of slices (osbuild#1939) - Author: Jakub Kadlčík, Reviewers: Michael Vogt, Simon de Vlieger - pkg/rpmmd: unify RPM package structure implementations (HMS-8911) (osbuild#1907) - Author: Tomáš Hozza, Reviewers: Achilleas Koutsou, Simon de Vlieger - potential kernel arguments options support for all installers (HMS-8999) (osbuild#1786) - Author: Michael Vogt, Reviewers: Achilleas Koutsou, Simon de Vlieger — Somewhere on the Internet, 2025-10-09 Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Adjust the code to the consolidated rpmmd.Package and removed rpmmd.PackageSpec in the latest version of osbuild/images. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
thozza
force-pushed
the
port-rpmmd-package-consolidation
branch
from
October 10, 2025 08:23
6a77800 to
f16c8d6
Compare
thozza
marked this pull request as ready for review
October 10, 2025 08:24
thozza
marked this pull request as draft
October 10, 2025 08:32
Modify the worker.DepsolvedPackage DTO properties and types to match the rpmmd.Package implementation. The backward compatibility between old composer-worker and new composer-worker-server is achieved on the JSON Unmarshaller level. This means that the server will be able to process DepsolveJobResults from the old worker that uses DTO that matches the old rpmmd.PackageSpec. We explicitly test for this scenario in the CI where the new osbuild-composer is ran with old composer-worker. The checksum is now represented as a struct, instead of a string value. The DepsolvedPackageChecksum supports Unmarshalling from JSON string and object representation. For backward compatibility reason, the struct is still Marshalled as a string value, which is consistent with the old implementation. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
Modify the worker.DepsolvedPackage DTO to fully match rpmmd.Package. This will be useful in the future once the depsolvednf and osbuild-depsolve-dnf will be able to fill all the additional metadata, which were previously not included in the rpmmd.PackageSpec. Introduce new DTOs for rpmmd.RelDep. Signed-off-by: Tomáš Hozza <thozza@redhat.com>
thozza
force-pushed
the
port-rpmmd-package-consolidation
branch
from
October 10, 2025 09:33
f16c8d6 to
5f36da3
Compare
thozza
marked this pull request as ready for review
October 10, 2025 09:35
thozza
requested review from
a team,
achilleas-k,
bcl,
croissanne,
lzap,
mvo5 and
supakeen
and removed request for
a team and
lzap
October 10, 2025 11:30
achilleas-k
approved these changes
Oct 13, 2025
achilleas-k
left a comment
Member
There was a problem hiding this comment.
This was a tonne of work but it all looks so nice now.
Thank you. LGTM!
supakeen
approved these changes
Oct 14, 2025
supakeen
left a comment
Member
There was a problem hiding this comment.
Thank you for taking care of all of this; it isn't the flashiest thing to work on but it's a great improvement!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Port of osbuild/image-builder#1907
Among other things, the worker depsolve job wire format for depsolved packages is decoupled from
rpmmddata structures. A backward compatibility layer is added in the worker code, ensuring that the new composer-worker-server can still successfully accept depsolve job results from the old composer-worker.osbuild/imagesis updated tov0.204.0as part of this PR:Changes with 0.203.0
BootMode(bootc: actually useBootModeimage-builder#1937)default_sizeto be a string (distro: add support fordefault_sizeto be a string image-builder#1929)required_partition_sizestake datasize.Size (many: makerequired_partition_sizestake datasize.Size image-builder#1931)— Somewhere on the Internet, 2025-10-07
Changes with 0.204.0
releaseverdnf variable through the Blueprint customization [HMS-9368] (Support setting thereleaseverdnf variable through the Blueprint customization [HMS-9368] image-builder#1896)— Somewhere on the Internet, 2025-10-09
/jira-epic HMS-8910
JIRA: HMS-9504