Skip to content

Annotation templates should pick up deep non-aliased attributes #16312

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 1 commit into from
Mar 18, 2025

Conversation

kse-music
Copy link
Contributor

@kse-music kse-music commented Dec 20, 2024

When searching for parameter annotations, I overlooked a scenario as below:

interface RemoteUserService {

    void batch(@CustomParameterAnnotation("six") String... user);

}

class UserServiceImpl implements RemoteUserService {

    @Override
    public void batch(@CustomParameterAnnotation("seven") String... user) {
      
    }

}

class DefaultUserService extends UserServiceImpl implements RemoteUserService {

    @Override
    public void batch(String... user) {
      
    }

}

When I run test should be throw exception :

Parameter parameter = DefaultUserService.class.getDeclaredMethod("batch", String[].class).getParameters()[0];
this.parameterScanner.scan(parameter);

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Dec 20, 2024
@kse-music
Copy link
Contributor Author

@jzheaux Can you help with the review?

@jzheaux jzheaux self-assigned this Mar 18, 2025
@jzheaux jzheaux added in: core An issue in spring-security-core type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged labels Mar 18, 2025
@jzheaux jzheaux added this to the 6.5.0-RC1 milestone Mar 18, 2025
@jzheaux jzheaux merged commit 96b9820 into spring-projects:main Mar 18, 2025
6 checks passed
@jzheaux
Copy link
Contributor

jzheaux commented Mar 18, 2025

Thanks, @kse-music, this is now merged into main

@jzheaux jzheaux changed the title Fixed the issue where the annotation parameter scan skipped first-level conflicts Annotation templates should pick up deep non-aliased attributes Mar 25, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
in: core An issue in spring-security-core type: bug A general bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants