Here is an update:
I was able to inject the PersistenceContext into my session bean by retrieving
the LocalInterface class from the InitialContext within my web service java
class.
| SampleClass sc = null;
| InitialContext ic = new InitialContext();
| sc = (ISampleClass)ic.lookup("MyEar/SampleClass/local");
|
I tried injecting the EJB at the class level - but that was always null.
| @EJB (mappedName="MyEar/SampleClass/local")
| SampleClass sc;
|
I also tried just setting the mapped name to: SampleClass, MyEar/SampleClass
and a bunch of other things - but none of them worked.
Is this the optimal solution to get my web service an instance of my stateless
session bean from the container?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4040715#4040715
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4040715
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user