Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

need help with javaidl on jdk1.2

0 views
Skip to first unread message

Saugato Mukerji

unread,
Dec 18, 1998, 3:00:00 AM12/18/98
to
Hi

I have a client and a server program which run happily when run on the
same NT4.0 pc using the
following commands ( the code is quite similar to the helloWorld demo
from sun.)

java -classpath m:\jdk1.2\jre\lib\rt.jar;. MessageServer
-ORBInitialPort 1050

java -classpath m:\jdk1.2\jre\lib\rt.jar;. MessageClient
-ORBInitialPort 1050 > log

tnameserv -classpath m:\jdk1.2\jre\lib\rt.jar;. -ORBInitialPort 1050

======= this worked fine ========


To run the message client and server on different machines

i ran on PC "1"

java -classpath m:\jdk1.2\jre\lib\rt.jar;. MessageClient
-ORBInitialPort 1050 > log

tnameserv -classpath m:\jdk1.2\jre\lib\rt.jar;. -ORBInitialPort 1050

and on PC "2"

java -classpath m:\jdk1.2\jre\lib\rt.jar;. MessageServer
-ORBInitialPort 1050

tnameserv -classpath m:\jdk1.2\jre\lib\rt.jar;. -ORBInitialPort 1050


The log file had the following error trace

ERROR : org.omg.CosNaming.NamingContextPackage.NotFound
org.omg.CosNaming.NamingContextPackage.NotFound
at org.omg.CosNaming.NamingContextPackage.NotFoundHelper.read(Compiled
Code)
at
org.omg.CosNaming.NamingContextPackage.NotFoundHelper.extract(NotFoundHelper.java:54)

at
org.omg.CosNaming._NamingContextStub.resolve(_NamingContextStub.java:165)

at MessageClient.main(Compiled Code)

It seems to me that the client does not know where the server is, but i
cant see where to specify it.

However the error trace does not reflect this reasoning. I have checked
using " tar -tvf m:\jdk1.2\jre\lib\rt.jar"
the org.omg.CosNaming.NamingContextPackage is actually present.

The javasoft documentation as well as the on line tutorial, run the
client n server on the same PC. This is not too
useful in real applications.

Can somebody explain how to make javaidl work between different machines
.

thanks

Saugato


0 new messages