2 Replies Latest reply on Jan 20, 2004 11:33 AM by thelemmings

    Different JNDI names for remote and local interfaces

    thelemmings Newbie

      Hi,
      I have a session bean with two sets of interfaces. Is it possible to name the same EJB differently for each interface used?

      In JNDIView I get:

      +- PageFlowEJB (proxy: $Proxy109 implements interface web.PageFlowHome,interface javax.ejb.Handle)

      and

      +- local (class: org.jnp.interfaces.NamingContext)
      | +- PageFlowEJB (proxy: $Proxy104 implements interface web.PageFlowLocalHome)

      I'd like to rename PageFlowEJB (the first, local one) because I store all the remote interface sets in a specific jndi "directory" (like 'ejb/MyRemoteBean') and I don't want it to be at the root of the global JNDI namespace.

      Thanks in advance,
      Luc
      --

      The local and remote interfaces are defined as follows in my ejb-jar.xml:

      <ejb-name>LogEntryEJB</ejb-name>
      web.LogEntryHome
      web.LogEntry
      <local-home>web.LogEntryLocalHome</local-home>
      web.LogEntryLocal

      In the jboss.xml file I have the following corresponding lines:

      <ejb-name>PageFlowEJB</ejb-name>
      <jndi-name>ejb/PageFlowEJB</jndi-name>