mini-spring
About
The mini-spring is a simplified version of the Spring framework that will help you quickly get familiar with the Spring source code and grasp the core principles of Spring. The core logic of Spring is extracted, the code is extremely simplified, and the core functions of Spring, such as IoC and AOP, resource loaders, event listeners, type conversion, container extension points, bean life cycle and scope, and application context, are retained.
If this project can help you, please STAR the project, thank you!!!
Contents
Basics
- IoC
- Implement a simple container
- BeanDefinition and BeanDefinitionRegistry
- Bean Instantiation Strategy
- Populate bean with property values
- Populate bean with bean
- Resource and ResourceLoader
- Define the bean in the XML file
- Container extension mechanism:BeanFactoryPostProcess and BeanPostProcessor
- ApplicationContext
- Init method and destroy method of bean
- Aware interface
- Bean scope, added prototype support
- FactoryBean
- Event and event listener
- AOP
Expanding
- PropertyPlaceholderConfigurer
- Package scan
- Value annotation
- Autowired annotation
- Type conversion(first part)
- Type conversion(second part)
Advanced
- Solve the problem of circular dependencies(first part): without proxy bean
- Solve the problem of circular dependencies(second part): with proxy bean
bug fix
Usage
Each function point corresponds to a branch. Switch to the branch corresponding to the function point to see the new function. The incremental change point is described in the changelog.md file.
Contributing
Any contributions you make are greatly appreciated.
Contact
Please feel free to ask me any questions related to mini-spring and other technologies. My email is 15521077528@163.com.