Skip to content

Remove compiler warnings for spring-security-access#18738

Open
dasog94 wants to merge 5 commits intospring-projects:mainfrom
dasog94:gh-18412
Open

Remove compiler warnings for spring-security-access#18738
dasog94 wants to merge 5 commits intospring-projects:mainfrom
dasog94:gh-18412

Conversation

@dasog94
Copy link

@dasog94 dasog94 commented Feb 15, 2026

While working this issue, I found that this issue is not in #18405.
But warning logs still exist, so I proceed this issue.

What I did is below.

  • added @SuppressWarnings
  • refactor codes causing compile warnings
  • add test for setAuthorizationManagerFactory that is a alternative to setTrustResolver and setDefaultRolePrefix

About the third, some tests using deprecated functions(setTrustResolver and setDefaultRolePrefix) have to be replaced with setAuthorizationManagerFactory, but there isn't setAuthorizationManagerFactory test.
Because of that, I added new tests even if it is located in core package.
I didn't still replace all the setTrustResolver and setDefaultRolePrefix because it might be used somewhere.

@dasog94 dasog94 changed the title Gh 18412 Remove compiler warnings for spring-security-access Feb 15, 2026
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Feb 15, 2026
@dasog94 dasog94 marked this pull request as ready for review February 15, 2026 14:24
@rwinch
Copy link
Member

rwinch commented Feb 23, 2026

Thanks for the PR. Unfortunately the build fails with the submitted changes.

It isn't listed because it is a deprecated module and I'm not too concerned with it as long as it isn't adding to the logs (we can probably just suppress the warnings).

In order for us to merge this the build needs fixed and we'd also need to add the compile-warnings-error plugin. Alternatively, we could suppress the warnings/output since this module is deprecated.

Can you please let me know if you intend to make those changes? If not, I will be closing this PR.

@rwinch rwinch assigned rwinch and unassigned rwinch Feb 23, 2026
@rwinch rwinch added status: waiting-for-feedback We need additional information before we can continue in: build An issue in the build in: access An issue in spring-security-access and removed status: waiting-for-triage An issue we've not yet triaged labels Feb 23, 2026
Bae Jihong added 5 commits February 23, 2026 12:02
- add on tests for deprecated class
- add on tests for specific deprecated function

Closes spring-projectsgh-18412

Signed-off-by: Bae Jihong <dasog@naver.com>
… class

Closes spring-projectsgh-18412

Signed-off-by: Bae Jihong <dasog@naver.com>
- add @SupressWarnings(deprecation) because of deprecated part in logic

Closes spring-projectsgh-18412

Signed-off-by: Bae Jihong <dasog@naver.com>
- replace setTrustResolver with setAuthorizationManagerFactory in MethodSecurityExpressionRootTests
- resolve raw type warning in ExpressionBasedMessageSecurityMetadataSourceFactoryTests

Closes spring-projectsgh-18412

Signed-off-by: Bae Jihong <dasog@naver.com>
- add test for setAuthorizationManagerFactory that is a alternative to setTrustResolver and setDefaultRolePrefix

Closes spring-projectsgh-18412

Signed-off-by: Bae Jihong <dasog@naver.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in: access An issue in spring-security-access in: build An issue in the build status: waiting-for-feedback We need additional information before we can continue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants