Kenneth Sizer wrote:

This didn't seem like it would be a problem, but apparently I'm not quite as clever as 
I thought...

I have a client and a server, connected via RMI. The client wishes to
> pass a "filter" to the server
> (see example below).
> Now, I was thinking/hoping that through the magic of RMI, my
> serializable implementation of the server's > WidgetFilter interface would be sent over the
> wire and used by the server without issue. It seems I was wrong.


The marshalling/classNotFound exceptions I get seem to indicate
that the MyWidgetFilter class definition needs to exist in the server's VM a priori, but I could have sworn that dynamic class transport was one of RMI's big "cool feature"
bullet points.

Kenneth:

I'm no RMI expert, so I can't tell you exactly
what's going on.. but I can tell you that you
are correct in that RMI has a mechanism for
dynamically transporting needed class definitions
over the wire.  If you have access to O'Reilly's
"Java RMI" book, all of chapter 19 is dedicated
to dynamic classloading.  You might give that
a look...  failing that, I'm sure there is
some documentation on the net somewhere
explaining how it all works... Sun puts a lot
of documentation up on their site, so you might
want to search over there a bit.

Good luck!

TTYL,

Phil



_______________________________________________
Juglist mailing list
[EMAIL PROTECTED]
http://trijug.org/mailman/listinfo/juglist_trijug.org

Reply via email to