Skip to content

Add an ArchRule to ensure that the return type of a @Bean method is not private #46753

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

Open
wants to merge 1 commit into
base: 3.4.x
Choose a base branch
from

Conversation

nosan
Copy link
Contributor

@nosan nosan commented Aug 9, 2025

See #46688

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Aug 9, 2025
@nosan nosan changed the title Add an ArchRule to ensure that the return type does not have the private modifier Add an ArchRule to ensure that the return type of a @Bean method is not private Aug 9, 2025
@snicoll
Copy link
Member

snicoll commented Aug 10, 2025

@nosan I wonder if that would be possible to restrict this to production code. This would reduce the knock-off effect as we have no intention to invoke AOT processing on our own tests at this time.

@snicoll snicoll added the status: waiting-for-feedback We need additional information before we can continue label Aug 10, 2025
@nosan
Copy link
Contributor Author

nosan commented Aug 10, 2025

@snicoll Agreed, added rules only for main sources.

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Aug 10, 2025
Signed-off-by: Dmytro Nosan <dimanosan@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: feedback-provided Feedback has been provided status: waiting-for-triage An issue we've not yet triaged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants