Announcement Announcement Module
Collapse
No announcement yet.
Inject dependencies into subclasses of @Configurable Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Inject dependencies into subclasses of @Configurable

    Hi out there,

    I'm trying to do the following: I have a quite large project that is made up of a few eclipse projects. I have an abstract base class in the core eclipse projects (which is AspectJ enabled), that is annotated with @Configurable and equiped with two setters with @Autowired. For testing purposes I have a dummy implementation that extends this class. Around that there are a lot of other classes in different (non AspectJ) eclipse projects that extend this base class.

    As I can see in package explorer, the abstract base class and the dummy implementation get woven correctly, other implementations of course do not.

    Additionally I've configured Spring as follows:
    Code:
    <context:spring-configured />
    <context:component-scan base-package="foo.bar" />
    My naive expectation now is that also all the unwoven subclasses get dependency injected as well, as the common superclass is woven with the aspect. In fact, it does not. Do I really have to apply AspectJ compiling to all the other eclipse projects, that use subclasses as well?

    Regards, Ollie
Working...
X