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

Include requested URI config in ListenerConfig; fix config keys #8371

Merged
merged 3 commits into from
Feb 14, 2024

Conversation

tjquinno
Copy link
Member

@tjquinno tjquinno commented Feb 13, 2024

Description

Resolves #8367
Resolves #8372

The ListenerConfigBlueprint declared requestedUriDiscoveryContext but did not annotate it with @Option.Configured so Helidon never processed configuration for it.

Changes:

  1. Change declaration of requestedUriDiscoveryContext on ListenerConfigBlueprint so it is configured as requested-uri-discovery and optional.
  2. Change http1 and http2 server requests to use a default discovery context if they are asked for requested URI info but none was configured.
  3. Do some initial clean-up of key names in RequestedUriDiscoveryContext. It does not yet use the new builder approach and needs to at some point; to get this PR completed more quickly that is not part of this PR.
  4. Forward-port requested URI discovery tests from 3.x that we not brought along previously. (I had opened [4.x] Migrate requested URI tests from 3.x #8372 to track the need to do this but added the tests in this PR instead.)

Documentation

Bug fix; no doc impact.

@tjquinno tjquinno self-assigned this Feb 13, 2024
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Feb 13, 2024
@@ -154,7 +159,7 @@ public Builder trustedProxies(AllowList trustedProxies) {
* @param discoveryTypes discovery types to use
* @return updated builder
*/
@ConfiguredOption
@ConfiguredOption(key = "types")
Copy link
Member

Choose a reason for hiding this comment

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

I think a better option would be to have a new method called types, and deprecate the discoveryTypes one.
This way we align config key and method name, as should be the default in Helidon

Copy link
Member Author

Choose a reason for hiding this comment

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

Changed.

@tjquinno tjquinno added this to the 4.0.6 milestone Feb 14, 2024
@tjquinno tjquinno merged commit 18e47a9 into helidon-io:main Feb 14, 2024
12 checks passed
@tjquinno tjquinno deleted the 4.x-requested-uri-config branch February 14, 2024 15:21
hrstoyanov pushed a commit to hrstoyanov/helidon that referenced this pull request Feb 23, 2024
…don-io#8371)

* Include requested URI config in ListenerConfig; fix config keys

* Forward-port requested URI discovery tests from 3.x

* Review comments
tvallin pushed a commit to tvallin/helidon that referenced this pull request Feb 28, 2024
…don-io#8371)

* Include requested URI config in ListenerConfig; fix config keys

* Forward-port requested URI discovery tests from 3.x

* Review comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[4.x] Migrate requested URI tests from 3.x Cannot configure requested-uri-discovery in MP
2 participants