users@glassfish.java.net

How to verify JNDI names are correct?

From: <forums_at_java.net>
Date: Thu, 25 Aug 2011 09:11:24 -0500 (CDT)

 I am working on moving my apps to GlassFish.  I am working on the JNDI
binding of my EJBs.  In my glassfish-ejb.jar I have the following values to
set the jndi-name I want GlassFish to bind them to.

<code>
<!DOCTYPE glassfish-ejb-jar PUBLIC "-//GlassFish.org//
DTD GlassFish Application Server 3.1 EJB 3.1//EN"
"http://glassfish.org/dtds/glassfish-ejb-jar_3_1-1.dtd">
<glassfish-ejb-jar>
<enterprise-beans>
        <ejb>
            <ejb-name>AccountLocal</ejb-name>
                <jndi-name>journal-ejb/AccountLocal</jndi-name>
        </ejb>        
<ejb>
         <ejb-name>JournalLocal</ejb-name>
                     
 <jndi-name>journal-ejb/JournalLocal</jndi-name>
</ejb>
<ejb>
<ejb-name>JournalEntryLocal</ejb-name>
                       
<jndi-name>journal-ejb/JournalEntryLocal</jndi-name>
</ejb>
</enterprise-beans>
</glassfish-ejb-jar>
</code>

When I deply the EAR though, the only thing I see in server.log are
statements like this:

<code>
Portable JNDI names for EJB AccountLocal :
[java:global/ferris-journal-ear-0.0.1/ferris-journal-ejb-0.0.1/AccountLocal!org.ferris.journal.ejb.account.AccountLocal,
java:global/ferris-journal-ear-0.0.1/ferris-journal-ejb-0.0.1/AccountLocal]|#]
</code>

I know this is the default lookup name which is fine, but I don't see any
logs which indicate my EJBs got bound in JNDI according to what I configured
in glassfish-ejb.jar.

Is there any way to verify the EJBs are bound correctly or can anyone see
anything wrong with my configuration?


--
[Message sent by forum member 'mjremijan']
View Post: http://forums.java.net/node/837076