CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2000
    Location
    India
    Posts
    64

    RMI: "UnmarshallException"...stub class not found

    I have both the client and the server on the same machine and the same directories.(including the stub and skeleton.Even then when i run the server program ,i get the error "java.rmi.UnMarshallException :stub class not found.(something like that)".Pl help me with this.

    return null;

  2. #2
    Join Date
    Dec 1999
    Location
    Chonghe, Taipei County, Taiwan, R.O.C.
    Posts
    231

    Re: RMI: "UnmarshallException"...stub class not found

    You may consider the path that reference to the stub class. For example, suppose that you have the
    implementation class file Test.ImplRMI.class . Your root directory is c:\RMI. In this directory, you may
    see the subdirectory Test, that is, c:\RMI\Test. In the subdirectory c:\RMI\Test, you need put the your
    implementation class and stub, and skeleton class files You may also have the interface class file, say
    IntfRMI.class and register RMI class file , say, RegRMI.class which is used to register the RMI server
    with the rmiregistry. You may have them with the same package name , say, Test. The simple case is
    to put Test.ImplRMI.class, stub and skeleton class of Test.ImplRMI.class, Test.IntfRMI.class,
    Test.RegRMI.class in the directory c:\RMI\Test. After ready, you may run the rmiregistry program
    in the root directory c:\RMI, and run the Test.RegRMI.class like this
    java -Djava.security.policy=test.polcyfile Test.RegRMI
    test.policyfile is the security policy file which is put in the root directory c:\RMI in this case. You may
    also try java Test.RegRMI directly. I've forgotten what may happen. It might work or fail.
    good luck,
    Alfred Wu


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured