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

This comment has been minimized.

Copy link

github-actions bot commented Dec 4, 2024

🎊 PR Preview 3554bbc 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.

This comment has been minimized.

@radcortez radcortez force-pushed the disable-config-properties-scan branch from 8cbb860 to 784a1fe Compare December 11, 2024 18:47
Copy link

quarkus-bot bot commented Dec 11, 2024

Status for workflow Quarkus Documentation CI

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

✅ 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 Dec 12, 2024

Status for workflow Quarkus CI

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

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


Flaky tests - Develocity

⚙️ JVM Tests - JDK 21

📦 integration-tests/kotlin-maven-invoker

io.quarkus.kotlin.maven.it.KotlinRemoteDevModeIT.testThatTheApplicationIsReloadedOnKotlinChange - History

  • org.awaitility.core.ConditionTimeoutException: Condition with Lambda expression in io.quarkus.maven.it.RunAndCheckWithAgentMojoTestBase was not fulfilled within 1 minutes. - java.lang.RuntimeException
java.lang.RuntimeException: org.awaitility.core.ConditionTimeoutException: Condition with Lambda expression in io.quarkus.maven.it.RunAndCheckWithAgentMojoTestBase was not fulfilled within 1 minutes.
	at io.quarkus.maven.it.RunAndCheckWithAgentMojoTestBase.runAndCheck(RunAndCheckWithAgentMojoTestBase.java:86)
	at io.quarkus.kotlin.maven.it.KotlinRemoteDevModeIT.testThatTheApplicationIsReloadedOnKotlinChange(KotlinRemoteDevModeIT.java:23)
	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
Caused by: org.awaitility.core.ConditionTimeoutException: Condition with Lambda expression in io.quarkus.maven.it.RunAndCheckWithAgentMojoTestBase was not fulfilled within 1 minutes.
	at org.awaitility.core.ConditionAwaiter.await(ConditionAwaiter.java:167)

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