users@glassfish.java.net

can JNDI Browser show the name of EntityManager or EntityManagerFactory?

From: <glassfish_at_javadesktop.org>
Date: Wed, 05 Dec 2007 20:43:49 PST

hi,
i can view the session bean, datasource in my glassfish JNDI Browser,
now, i use lookup method to get the container managed entitymanager from my webapp in the same application server, and it success.

like define

<persistence-context-ref>
        <persistence-context-ref-name>my_em_ref</persistence-context-ref-name>
        <persistence-unit-name>EJBModule2PU</persistence-unit-name>
</persistence-context-ref>

then using (EntityManager) ctx.lookup("java:comp/env/my_em_ref"); to lookup the resource.

so above definition will really create the jndi instance in glassfish?
but i cant see my_em_ref or EJBModule2PU in my jndi browser?

is there any wrong in my understanding?

thx
[Message sent by forum member 'kojilin' (kojilin)]

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