Skip to content

Conversation

@radcortez
Copy link
Member

@radcortez radcortez commented Dec 3, 2025

Calling ArtifactLauncher.start to start Quarkus now returns an Optional<ListeningAddress>, which was already available when starting the process internally. The ListeningAddress is then registered with the test Context, which allows us to avoid using System properties to propagate the running port.

This also means that it removes the ability to query quarkus.http.port and quarkus.http.test-port from the test itself using Config to get the real port (in case of using a random port for integration tests). From our tests, I don't see us doing that, but that doesn't mean users out there aren't. We could probably add a JUnit ParameterResolver to support injection of the ListeningAddress, but I'm not sure if this would be the final API we want to expose, since I think it would be interesting to have a unified API for both test and regular runtime. The real port is still registered with RESTAssured, so that is a way to get it if required. Again, this only applies to tests running outside Quarkus.

Also, io.quarkus.test.junit.QuarkusTestProfile#getConfigOverrides, which was being set in SystemProperties, was moved to set the properties directly into the runner arguments, and set directly into the CuratedApplication when we require DevServices. This also means that properties set by io.quarkus.test.junit.QuarkusTestProfile#getConfigOverrides can no longer be retrieved by ConfigProvider.getConfig in integration-tests. Unsure if this is something that users use, but I'm thinking that we need to ban the usage of ConfigProvider.getConfig, and offer it as a test parameter, so we can create local instances to each test.

If this becomes a big issue, we can temporarily register the ports with System properties again. Hopefully, it shouldn't be required if we can do all the related work in a single release. This relates to:

Splitting this into smaller PRs to make it easier to review and track.

@quarkus-bot

This comment has been minimized.

@quarkus-bot

This comment has been minimized.

@quarkus-bot

This comment has been minimized.

@radcortez radcortez force-pushed the artifact-launcher branch 2 times, most recently from c6b11f9 to 7922fa3 Compare December 5, 2025 14:49
@quarkus-bot

This comment has been minimized.

@quarkus-bot

This comment has been minimized.

@quarkus-bot

This comment has been minimized.

@quarkus-bot

This comment has been minimized.

Copy link
Contributor

@geoand geoand left a comment

Choose a reason for hiding this comment

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

Very nice cleanup!

@radcortez
Copy link
Member Author

Pushed an update to extract https://github.com/quarkusio/quarkus/pull/51367/files#diff-0976161629e37650ede7638425bb54845838f7aeb4fc3fae3e30a66153411784R36-R57 and apply it to all launchers (was only being applied to the native launcher).

@Karm
Copy link
Member

Karm commented Dec 10, 2025

@radcortez

java.lang.IllegalArgumentException: baseURI cannot be null

for awt-packaging test: I need to deal with the AWS Lambda thing in there... I appreciate ideas.

@radcortez
Copy link
Member Author

for awt-packaging test: I need to deal with the AWS Lambda thing in there... I appreciate ideas.

Can you please clarify? Are you already using this PR?

@quarkus-bot

This comment has been minimized.

@radcortez
Copy link
Member Author

@Karm are we ok to merge this? or are you having issues?

@radcortez radcortez merged commit 44a67d1 into quarkusio:main Dec 15, 2025
62 of 63 checks passed
@quarkus-bot quarkus-bot bot added this to the 3.31 - main milestone Dec 15, 2025
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