geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sai Arunachalam <sai.arunacha...@gmail.com>
Subject Geronimo JNDI properties
Date Wed, 18 Aug 2004 14:02:59 GMT
Hi,
     I am trying to run a stateless session HelloWorld example that
comes with MasteringEJB2 (it is meant for WebLogic 6.1) on Geronimo.
The HelloWorld.jar gets deployed on the server and I am able to start
the server with the appropriate configId but ain't able to run the
client. I am getting the following exception:

Exception in thread "main" javax.naming.NameNotFoundException: HelloHome
        at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:90)
        at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:98)
        at javax.naming.InitialContext.lookup(InitialContext.java:347)
        at examples.HelloClient.main(HelloClient.java:36)

My openejb-jar.xml is as follows:
------------------------------------------------

<?xml version="1.0"?>

<openejb-jar xmlns="http://www.openejb.org/xml/ns/openejb-jar"
configId="your/domain/name/HelloWorld3"
parentId="org/apache/geronimo/Server">

<enterprise-beans>
        <session>
        <ejb-name>Hello</ejb-name>
        <jndi-name>HelloHome</jndi-name>
        <local-jndi-name>HelloLocalHome</local-jndi-name>
        </session>
</enterprise-beans>

</openejb-jar>

The original command given in the example to run the client was as follows:

java -Djava.security.policy=../java.policy
-Djava.naming.factory.initial=weblogic.jndi.WLInitialContextFactory
-Djava.naming.provider.url=t3://localhost:7001 examples.HelloClient


java.policy is the following two lines:
grant {^M
        permission java.security.AllPermission;^M
        permission java.net.SocketPermission "*","listen,accept,connect";^M
};

I give the following command:

java -classpath ./Hello.jar:/home/TU1/j2ee/j2sdkee1.3.1/lib/j2ee.jar
-Djava.naming.factory.initial=com.sun.jndi.rmi.registry.RegistryContextFactory
-Djava.naming.factory.url.pkgs=org.apache.geronimo.naming
-Djava.naming.provider.url=rmi://localhost examples.HelloClient

Am I wrong with JNDI properties for Geronimo or is it something else?

Thanks in help,
Sai

Mime
View raw message