Java EE 7 - Injection into Runnable/Callable object
问题 Concurrency Utilities(JSR 236) has been introduced in Java EE 7. Is there any way how to inject my EJBs into Runnable/Callable object? Specifically I want something like this: ejb with business logic @LocalBean public class MyEjb { public void doSomeStuff() { ... do some stuff ... } } runnable/callable class where I want to inject instance of MyEjb public class MyTask implements Runnable { @EJB MyEjb myEjb; @Override public void run() { ... myEjb.doSomeStuff(); ... } } Object which starts the