Skip to content
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

Do not discover properties resource in the classpath to avoid missing resources registration in native mode #44910

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

radcortez
Copy link
Member

@radcortez radcortez commented Dec 3, 2024

Disable automatic discovery of configuration resources in native mode.

While it has always been enabled, it didn't have any effect because we never registered the resources in the native image. The configuration still worked, because we recorded the configuration during build time.

I did try to disable it as well for JVM mode, but it is a bit more tricky:

  • Our testing API can add additional classpath resources after we build Quarkus, which wouldn't be caught with this.
  • Debugging would be harder, because it would lose the the origin source from where the configuration is coming from.
  • Flattening has a corner case issue described in Register default configuration smallrye configuration files as resources #44652 (comment). This was never really an issue, but there is a test in the TCK that fails because of this.

Ideally, both JVM and native mode should be the same, but at the moment they're not. While this doesn't solve that particular issue, it should at least fix the missing registration warnings / errors without changing the current behaviour.

Alternate proposal to #42140.

This comment has been minimized.

@geoand
Copy link
Contributor

geoand commented Dec 4, 2024

CI failures seem related

@radcortez
Copy link
Member Author

CI failures seem related

Yes

@radcortez
Copy link
Member Author

I was expecting more actually :)

@radcortez radcortez force-pushed the disable-config-properties-scan branch from 74e2236 to 8cbb860 Compare December 4, 2024 13:33
@radcortez radcortez changed the title Do not discover properties resource in the classpath since they are already recorded during build time Do not discover properties resource in the classpath to avoid missing resources registration in native mode Dec 4, 2024
Copy link

quarkus-bot bot commented Dec 4, 2024

Status for workflow Quarkus Documentation CI

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

✅ 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

github-actions bot commented Dec 4, 2024

🎊 PR Preview eab567b has been successfully built and deployed to https://quarkus-pr-main-44910-preview.surge.sh/version/main/guides/

  • Images of blog posts older than 3 months are not available.
  • Newsletters older than 3 months are not available.

Copy link

quarkus-bot bot commented Dec 4, 2024

Status for workflow Quarkus CI

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

✅ 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.

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.

Enhance SmallRyeConfig handling
2 participants