I am not sure weather this question is already answered, but still it goes like:
I have two servers running in WSAD4.0 (say localhost:8080 ORB port 900 and localhost:8085 ORB port 905). I want to access a bean from one server to another using JNDI (from 8080 to 8085).
To
test that I have created two clients, one in the same server (8080) where
EJB lies and the other on a different server (8085).
The client code works great in the same server space (8080), but as soon as I invoke the client from another server the reference returned is null.
Code that works on localhost:8080 is :
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY, "com.ibm.websphere.naming.WsnInitialContextFactory");
env.put(Context.PROVIDER_URL, "iiop://localhost:900/");
Context initialContext = new InitialContext(env);
Object objref = initialContext.lookup(ejb/com/test/common/model/SomeServiceHome");
out.println("<P>Address of JNDI " + objref.toString() );
Same code dosen’t work on localhost:8085
Do I have to do any settings while running the server?
SCJP, SCJD, SCWCD1.4, IBM486, IBM484, IBM 483, IBM 287, IBM141, IBM Certified Enterprise Developer - WebSphere Studio, V5.0
Author of IBM 287 Simulator Exam