Build your own @MiniService
summary
Builds a tiny @MiniService annotation and an Inject field annotation, then uses reflection to scan, instantiate, inject, store a handful of classes listed by hand rather than scanning the whole classpath. Code calls setAccessible and uses Field.set to inject dependencies, creates instances for two components in the demo and three after annotating the extra class, and keeps them in a simple map container — the mini container runs and prints the results.
AI-written summary · about
chapters (8)
- 0:00Spring magic and DI intro
- 1:41Why build a mini Spring
- 2:47DI container core steps
- 4:14Custom annotations for scan/inject
- 6:02Live demo scanning/instantiation
- 8:26Demo dependency injection
- 9:53Spring vs mini framework steps
- 10:13Learning by rebuilding
related talks
18mwith Inversion Control
31mBuild your own Dependency Injection framework!
49mOn @annotations - liberate yourselves from demons
32mLet's Build a Dependency Injection Framework
05h 30mDay 2
05mDependency Injection
21mMinimalist Dependency Injection in Kotlin
47mIntroduction to Micronaut Lightweight Microservices with Ahead of Time Compilation
