users@glassfish.java.net

Re: Glassfish V3 + Standalone client lookup session bean JNDI

From: <glassfish_at_javadesktop.org>
Date: Thu, 20 May 2010 11:06:40 PDT

Hello
I had the same problem and did a lot of research finally I resolved it by adding the following jar's. If I remove one of the package I had a lookup failure. Try to ad it in a folder and add it to the classpath

auto-depends.jar
common-util.jar
config.jar
config-api.jar
config-types.jar
connectors-internal-api.jar
deployment-common.jar
dol.jar
ejb.security.jar
ejb1.jar
ejb-container.jar
ejb-internal-api.jar
gf-client-module.jar
glassfish-api.jar
glassfish-corba-asm.jar
glassfish-corba-codegen.jar
glassfish-corba-csiv2-idl.jar
glassfish-corba-newtimer.jar
glassfish-corba-omgapi.jar
glassfish-corba-orb.jar
glassfish-corba-orbgeneric.jar
glassfish-naming.jar
gmbal.jar
hibernate3.jar
hk2-core.jar
internal-api.jar
javax.ejb.jar
kernel.jar
management-api.jar
orb-connector.jar
orb-iiop.jar
security.jar
tiger-types-osgi.jar

than try this code per default it search on localhost server

                        try {
                                System.out.println("lookup");
                                ejb = (RemoteCustomer) new InitialContext()
                                                .lookup("java:global/jeprEJBCustomer/EJBCustomer");
                                System.out.println("context intizialisated");
                        } catch (NamingException e) {
                                // TODO Auto-generated catch block
                                e.printStackTrace();
                        }
[Message sent by forum member 'ritzjp']

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