aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes VAJ RMI classpath Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "VAJ RMI classpath" Watch "VAJ RMI classpath" New topic
Author

VAJ RMI classpath

KH Yau
Greenhorn

Joined: May 20, 2001
Posts: 13
Hi, I follow instructions given by "Effective Use of Visual Age for Java" to create an RMI application. As said, I have to add project path to the workspace classpath so that the server program (implements rmi) can find the stub class. I did it but VAJ still throws exception, complaining xxx_Stub class not found. Does anyone out there use VAJ rmi? Thanks! KH
Bredan Tomong
Greenhorn

Joined: Dec 21, 2000
Posts: 13
You have to compute or select the projcet you need for the excutable class.
Right click the excutable class then click "classpath".
khyau
Greenhorn

Joined: May 18, 2001
Posts: 7
I have added the project into classpath. My classes are organised as follows.
----------------------------------------------
project: Effective VisualAge for Java
package: effectivevaj.adv.dist.traditionalrmi
Interface: Counter
classes: CounterClient (excutable)
CounterImpl (ex.. )
CounterImpl_Stub
-----------------------------------------------

Selecting CounterImpl -> Property -> classpath
the classpath settings are as follows.
-----------------------------------------------
"checked" project path: Effective VisualAge for Java
"unchecked" additional directory
complete classpath:
.;
c:\program files\ibm\visualage for java\ide\project_resources\Effective VisualAge for Java;
---------------------------------------------------------
Running CounterImpl results in:
----------------------------------
[deleted]
java.lang.ClassNotFoundException: effectivevaj.adv.dist.traditionalrmi.CounterImpl_Stub
[deleted]
---------------------------------------------------
Can you help? KH.
KH Yau
Greenhorn

Joined: May 20, 2001
Posts: 13
I found the answer myself. I have to invoke rmi registry by coding the following line in the main program of CounterImpl.java
LocateRegistry.createRegistry(1099);
Previously, I invoke registry from
Windows->Options->rmi registry
and then click "restart rmi registry".
Don't understand why the above procedures do not work (suggested by the book).
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: VAJ RMI classpath