Hi Michael,
On Mon, 26 Mar 2001, Michael Bauschert (web.de) wrote:
> Hi there,
>
> Getting a reference of the InterestBean fails:
>
> i am doing the
> Object ref = jndiContext.lookup("Interest");
>
> and get the exception:
>
> javax.naming.CommunicationException [Root exception is
> java.rmi.ConnectIOException: Exception creating connection to:
> 149.225.117.146; nested exception is:
> java.net.NoRouteToHostException: Host unreachable: no further information]
>
>
> My Naming-Properties:
> System.setProperty("java.naming.factory.initial",
> "org.jnp.interfaces.NamingContextFactory");
> System.setProperty("java.naming.provider.url",
> "127.0.0.1:1099");
>
> Why ist JBoss trying to connect to 149.225.117.146 and not to my localHost ?
because the stub of the remote object that you became as a result of
lookup() contains it's 'home' address (adress and port where JVM of remote
object is accepting connections from stubs). that adress is determined
by JVM that is hosting remote object and is not the one that you were
using to lookup() the object because naming service must not be located on
a same host/jvm as remote object (for example client is on a
machine A, naming service is on B and remote objects are actually homed on
machine C but are registered on B). I hope that you were able to
understand anything i've written (sorry for my bad english ...)
Dragan
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user