-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add depsolve to cloudapi #4564
Add depsolve to cloudapi #4564
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice. LGTM!
Bigger topic: Would it make the depsolve call more useful if we supported a full request as if generating a manifest? In other words, we can return the full list of packages for a supposed build by asking for the image type as well. We can keep the old functionality if needed by supporting I think both use cases are useful tbh. The existing one is useful for putting some packages in a blueprint and seeing what they'll pull in just by themselves. Being able to add an image type will tell you what to expect from a proper build using the blueprint. |
Yes, I can see cases where you'd want to see the added packages (and repos) needed for the full image. I'd like to add that later though. Next step is to write a search request which will build on this. |
015ef7c
to
257e9a1
Compare
Yeah, of course. Topic for a different time. Figured it was relevant enough to bring up here and see what you think :) |
This function only depends on the Blueprint (cloudapi request type, not the internal/blueprint) so move it to a function on that so that it can be reused by other users of the cloudapi Blueprint. Related: RHEL-60125
In order to reuse PackageMetadata with DepsolveResponse and not include unused fields this changes the sigmd5 entry to an optional field. This doesn't effect the use of PackageMetadata in the Compose response since it is always set, and it allows it to be omitted in the response for depsolving. Also adds a basic test for stagesToPackageMetadata Related: RHEL-60125
This will allow depsolving blueprints and returning package metadata for the dependencies. Related: RHEL-60125
and return the response to the client. This uses the worker to depsolve the requested packages. The result is returned to the client as a list of packages using the same PackageMetadata schema as the ComposeStatus response. It will also time out after 5 minutes and return an error, using the same timeout constant as depsolving during manifest generation. Related: RHEL-60125
This also adds an actual repository json file for the test-disro. Without this the repo.ListDistros() function doesn't return any actual distros. Related: RHEL-60125
Test the depsolve using a mocked response, test for mismatched distributions, and for unsupported architectures.
5b7981d
to
a71a8f6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
This pull request includes:
This replaces #4390 and search will be added as a followup PR.