spring-projects / spring-projects/spring-framework
Capture information about component scanning for subsequent use in diagnostic messages
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 60.2k
- Forks
- 38.8k
- Avg merge
- 5d 2h
- Merged PRs (30d)
- 27
Description
Overview
We'd like to improve Spring Boot's failure analysis when refresh fails due to a NoSuchBeanDefinitionException by showing the user some information about component scanning. For example, it could be useful for them to know that com.example.alpha has been scanned when the bean that was not found was in com.example.bravo as it may point towards a misconfiguration of component scanning.
Could Framework record information about the component scanning that's been performed and somehow make it accessible? At the moment, it appears to be an implementation detail of configuration class parsing and there's no way for Boot to get at the information or to intercept the scanning.
Related Issues
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the component-scanning flow within configuration class parsing and the related Spring Boot failure-analysis issue #28841. Determine where information about scanned packages could be exposed for later diagnostic use; done means the relevant scanning information is accessible to failure analysis without relying on an implementation detail.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, spring, spring-boot
- Domain
- backend, devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 32/100