Conversation
Contributor
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
Only a documentation nit remains; no blocking issues were identified.
Review effort: Lite
Findings: None
What changed in this PR
Restores Spring configuration binding for oauth.client.allowpublic and adds regression coverage for missing nested configuration.
Changes:
- Restores null-safe
@ValueSpEL injection. - Adds wiring tests for configured and absent YAML paths.
| File | Summary |
|---|---|
server/src/main/java/org/cloudfoundry/identity/uaa/client/ClientAdminBootstrap.java |
Restores configuration-based public client injection. Minor nit: document the property in the configuration reference. |
server/src/test/java/org/cloudfoundry/identity/uaa/client/ClientAdminBootstrapWiringTest.java |
Verifies configured, missing oauth, and missing oauth.client scenarios. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Member
|
please. check unit tests |
strehle
force-pushed
the
allowpublicprovider-wiring-fix
branch
from
September 22, 2026 19:24
c38ada4 to
5808de4
Compare
strehle
approved these changes
Sep 22, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Problem
When ClientAdminBootstrap was converted to a @component (commit a1459a3), the @value SpEL annotation was accidentally dropped from the allowPublicClients constructor parameter. Without it, Spring performs type-based injection and injects all String-typed beans from the context into that Set instead of reading oauth.client.allowpublic from the YAML config.
Fix
Restore the @value expression on the allowPublicClients parameter with null-guards for the case where oauth or oauth.client are absent from the config:
@value("#{@config['oauth']==null ? null : @config['oauth']['client']==null ? null : @config['oauth']['client']['allowpublic']}")
Tests
Added ClientAdminBootstrapWiringTest — a minimal Spring context wiring test that covers three scenarios: