Spring, abstract class and annotations
Solution 1
Your setup seems fine. The reason perhaps lies elsewhere. Maybe you are instantiating the class with new CreateDatabaseAction(), rather than letting spring do this.
Solution 2
Use @Autowired and not @Inject from javax.inject.
Dependency injection in abstract class only works for spring's @Autowired.
FYI, I'm using Spring 4.0; Java 6
Author by
Admin
Updated on June 15, 2020Comments
-
Admin about 2 years