2 Replies Latest reply on Jul 10, 2006 3:32 AM by schulz

    Passing Object in RemoteCall, wich is unknown for AppServer

    schulz

      Hi,

      i'm desperated.

      I'm doing a remote call from a client to a JBoss 3.0.6. Client and JBoss run on different JVM's. One of the parameters of the call is an object, whose class is unknown for the JBoss (JBoss does only know the interface but not the implementation). Actually I expected, that the JBoss loads the unknown class from the VM of the client. But it doesn't.

      I know, that it should work actually (I tried the example on http://java.sun.com/docs/books/tutorial/rmi/ and it works).

      Can anybody tell me, whether that works with JBoss at all? And if so, where I go wrong?

        • 1. Re: Passing Object in RemoteCall, wich is unknown for AppSer

          I'm going to guess you are talking about making an ejb call? For this, will need to make sure all classes that need to be loaded (e.g. the implementation class being passed), are contained on the classpath for the jboss server. Easiest way to do this is to include it within the deployment on jboss (e.g. if have a ejb deployment foo.jar, it includes the implementation class being passed).

          • 2. Re: Passing Object in RemoteCall, wich is unknown for AppSer
            schulz

            Recently I found out, that the implementation of ObjectInputStream in JBoss (MarshalledValueInputStream) avoids a remote-loading of client classes, because it ignores the information, added by sun.rmi.server.MarshalOutputStream.annotateClass(). I guess, that is not a bug but has been made by full intention (security reasons?), so finally my stuff will not work.

            Thank you anyway for your efforts.