Skip to content

Conversation

LarsSven
Copy link
Contributor

@LarsSven LarsSven commented Jul 18, 2025

This PR is a follow-up of #48536 to include a few improvements I've noticed since experimenting with this new feature in Quarkus 3.25.0.CR1

The first is the ability to apply a manifest from a URL.. Often, one of the installation options for applications on Kubernetes is a single manifest that installs all related resources, e.g. https://kueue.sigs.k8s.io/docs/installation/#install-by-kubectl. You then don't want to add a 1MB YAML file to your resources folder and commit it to git, so it makes sense to apply directly from the URL.

Secondly is for startup to await resources that have readiness statuses (e.g. deployments). If you deploy, for example, a CRD controller (or any application for that fact), you often want it to be fully running before you start running tests or interact with it in dev mode. So it makes sense to delay startup until all manifests are ready. Besides that, there is another reason we want to do this that cannot be replaced by the user writing code themselves to await the deployments: Sometimes, manifests being deployed depend on it.

We, for example, have a setup where one of the manifests we deploy is a full CRD controller, and we then follow it up with a custom resource. This custom resource will, however, fail to apply until the deployment for the CRD controller is ready, and since both the CRD controller and custom resource are part of the Quarkus startup, you have no way to control this startup process as a user without Quarkus awaiting the CRD deployment.

The strategy for awaiting resources is as follows: We always deploy all resources within a single manifest without any await in between. We then await between manifest deployments for the resources of the manifest. This makes most sense as manifests may depend on each other, but the internal resources of a single manifest will never depend on a readiness await (since then kubectl apply -f manifest.yaml would naturally fail, which means the manifest itself is just broken).

@LarsSven
Copy link
Contributor Author

cc @geoand @metacosm since you also reviewed the previous PR.

This comment has been minimized.

Copy link

github-actions bot commented Jul 18, 2025

🙈 The PR is closed and the preview is expired.

This comment has been minimized.

@geoand
Copy link
Contributor

geoand commented Jul 21, 2025

Thanks!

Seems reasonable to me, but I'll defer to @metacosm for a proper review

@LarsSven
Copy link
Contributor Author

@geoand I updated the documentation and added an integration test for the URL manifest application.

My team are already building some things that absolutely need this improvement. I completely understand that people are on holiday and we need to be patient, but we would love to have this in the next Quarkus LTS release. Is there anything I can do to increase the chances that this makes it into the next LTS release?

@geoand
Copy link
Contributor

geoand commented Jul 31, 2025

The next LTS will be 3.27, which will be a continuation of 3.26, so as long as it gets in by then, everything lines up

This comment has been minimized.

This comment has been minimized.

}
}

private boolean isReadinessApplicable(HasMetadata item) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've created a PR: fabric8io/kubernetes-client#7206, we should use the implementation from the client's Readiness (accessible from the Config) instead, if / when the PR is merged and available.

Copy link
Contributor Author

@LarsSven LarsSven Aug 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah perfect! That is indeed exactly why I copied the function over, because it wasn't available publicly

Copy link
Contributor Author

@LarsSven LarsSven Aug 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably has to go through the whole cycle though of merge -> release -> upgrade in Quarkus, then we can change this?

Would it be possible to merge this PR with the copied over function for now and I'll make sure I'll make a followup PR once the function is available? So we can make the next LTS Quarkus release with these changes?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new version of fabric8 has been released and merged in, however I'm still not happy with the public API as it's non-static, I made a followup PR before we remove the copied method: fabric8io/kubernetes-client#7280

Copy link
Contributor

@metacosm metacosm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM apart from minor nitpicks.

@LarsSven
Copy link
Contributor Author

LarsSven commented Aug 5, 2025

@metacosm I worked through all the comments

Copy link

quarkus-bot bot commented Aug 5, 2025

Status for workflow Quarkus Documentation CI

This is the status report for running Quarkus Documentation CI on commit a89bef3.

✅ The latest workflow run for the pull request has completed successfully.

It should be safe to merge provided you have a look at the other checks in the summary.

Warning

There are other workflow runs running, you probably need to wait for their status before merging.

Copy link

quarkus-bot bot commented Aug 5, 2025

Status for workflow Quarkus CI

This is the status report for running Quarkus CI on commit a89bef3.

✅ The latest workflow run for the pull request has completed successfully.

It should be safe to merge provided you have a look at the other checks in the summary.

You can consult the Develocity build scans.

@LarsSven
Copy link
Contributor Author

LarsSven commented Aug 8, 2025

Given this comment (#49415 (comment)), is there still anything that is blocking this PR? Anything I need to do or that still needs to happen?

@metacosm
Copy link
Contributor

metacosm commented Aug 8, 2025

Given this comment (#49415 (comment)), is there still anything that is blocking this PR? Anything I need to do or that still needs to happen?

Not from my side.

@geoand geoand merged commit 931e20c into quarkusio:main Aug 8, 2025
30 checks passed
@quarkus-bot quarkus-bot bot added this to the 3.26 - main milestone Aug 8, 2025
@LarsSven LarsSven deleted the ls/manifests-from-url branch August 8, 2025 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants