I write a interface DBAccess which extends Remote
and a class DBAccessImpl which implements DBAccess
At last I write a
test class Named Server
String hostName ;
try{
LocateRegistry.createRegistry(1099);
DBAccessImpl DBAccess = new DBAccessImpl();
hostName = "localhost";
Naming.rebind("//localhost:1099/DBAccess",DBAccess);
System.out.println("DBAccess rebind");
}
....
when i run . i get these error message like:
java.rmi.StubNotFoundException: Stub class not found: DBAccessImpl_Stub; nested
exception is:
java.lang.ClassNotFoundException: DBAccessImpl_Stub
at sun.rmi.server.RemoteProxy.getStub(RemoteProxy.java:98)
at sun.rmi.server.RemoteProxy.getStub(RemoteProxy.java:55).....