"richard.opalka(a)jboss.com" wrote :
| Also javax.ejb.EJB annotation is really confusing me. What's the difference
between name and mappedName?
|
The "name" attribute is jndiname within the java:comp/env namespace of the
component into which the bean is being injected. So if you have:
| @Stateless
| public AnotherBean...
| {
|
| @EJB(name="someName")
| private BeanOne bean;
| ..
| }
This means that the BeanOne is available at java:comp/env/someName jndiname of the
AnotherBean's java:comp/env namespace.
The mappedName is actually the global jndiname (not the java:comp/env namespace) of the
bean. The mappedName is actually not portable. Each vendor (application server) can
implement this the way they want and are even allowed to ignore it.
anonymous wrote : Where in the EJB spec I can find exhausting description of this
annotation?
I found this useful
http://java.sun.com/products/ejb/javadoc-3_0-fr/javax/ejb/EJB.html
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4227767#...
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&a...