users@glassfish.java.net

Re: JNDI lookup of a specific SLSB / multiple Instances of a single App

From: <glassfish_at_javadesktop.org>
Date: Thu, 18 Jun 2009 10:31:33 PDT

I assume from your example that the bean in question exposes a Remote interface. In that case, it's easy to do this by configuring a unique global <jndi-name> for each ejb in a META-INF/sun-ejb-jar.xml file. E.g. :

<sun-ejb-jar>
  <enterprise-beans>
     <ejb>
        <ejb-name>mySLSB</ejb-name>
        <jndi-name>mySLSB/1</jndi-name>
     </ejb>
  </enterprise-beans>
</sun-ejb-jar>

You can find more about JNDI names in our EJB FAQ : https://glassfish.dev.java.net/javaee5/ejb/EJB_FAQ.html
[Message sent by forum member 'ksak' (ksak)]

http://forums.java.net/jive/thread.jspa?messageID=351888