Hi people,
I'm practicing some RMI concepts on a pc (lets call it pc A) a simple Hello World
test for my
SCJD. It works fine. The problem is when i try to start the client from another pc (pc B).
Steps on pc A (server):
-----------------------
I compile the server object, client object and interface.
I create the stub file using >rmic ServerImpl
I start the registry with >start rmiregistry.
I start the server.
note: in the client object i have the following:
HelloInterface server = (HelloInterface)Naming.lookup("rmi://192.168.0.3:1099/Server");
the ip address is the LAN ip of the server.
Steps on pc B (client):
-----------------------
Copy the generated client.class file from the server to the client (pc B).
I run the client and it says it cannot find HelloInterface (which is on the server (pc A).
note: the server is run with JRE 1.4 and the client runs with JRE 1.5.
Where am i going wrong?
Thanks in advance and regards,
Marzo.
SCJP 1.4, SCWCD 1.4, SCBCD 1.3, SCJD, SCEA/OCMJEA
Live life to an interface, not an implementation!