
Originally Posted by
Rod Johnson
There's no out of the box support for this yet, although we're considering it for 1.2. (It's arguably a bit of an antipattern, as you are normally better to refactor your business logic wholly out of EJBs into POJOs behind them.)
It shouldn't be hard to do. You can customize your onEjbCreate() method to get the BF, cast it to AutowireCapableBeanFactory, and "autowire" your EJB instance (this) by type.
Look at DependencyInjectionAspectSupport in the sandbox if you need an example of this approach.
Rgds
Rod