So you want to override the @EJB mappedName via a xml? You can do that via a ejb-ref element in the jboss.xml.
Many thanks for your help !
Since I already tried this, that's I was doing something wrong... So I double check according to your response, and it's working fine ( in jboss.xml, the <ejb-name> was mapped on the Interface... arg !)
The 'problem' with this solution (override annotation with xml) is I have to write a jboss.xml conf for each local bean, even if I am injecting the same remote EJB
Is there any way to get the remote ejb referenced in the local JNDI tree with some kind of XML conf ? So I could inject this local ref without having to override annotation
In each local ejb (without having to write an '<session><ejb-ref>...' per local bean) :
And a JNDIView with something like this :
(If this is not possible, i'll code my own local proxy to do this...)