Apache River - Jini

52 views
Skip to first unread message

Peter

unread,
Apr 9, 2010, 5:53:05 AM4/9/10
to kryo-users
In Apache River, we have a component called Jeri (Jini Extensible
Remote Invocation) Unlike Java RMI, Jeri doesn't magically create a
remote proxy. Instead Jeri has an Interface called
net.jini.export.Exporter with a method called export that expects a
parameter Object that implements java.rmi.Remote (marker interface).

Unlike Java RMI the Remote implementation, it is expected to implement
writeReplace() and return a proxy, which is serialized to the client
using whatever protocol the Exporter utilises, Exporters are
interchangeable.. This proxy can be a simple reflective proxy or a
smart proxy which may perform computations remotely at the client.
The Jeri remote object does't have to extend any other class, just
implement Remote and writeReplace().

I would like to make it feasible to use Jini over the internet,
unfortunately there are some isses that prevent it:

1. Codebases are tied to a URL location and are not interchangeable or
replaceable, if a local class is used instead, codebase annotations
are lost.
2. There is currently no way to distinguish class or package versions.
3. Different remote services have their local proxy's in separate
Classloaders even if their bytecodes and class names are identical,
their runtime types are different.
4. Serialized object Classloaders are never unlinked by
ObjectStreamClass so can never be garbage collected even after all
their classes have gone out of scope.
5. ObjectStreamClass is a primordial class and cannot be extended to
contain package version information.
6. Due to the above issues memory consumption is too great.

A good place to experiment appears to be a KryoEndpoint for jeri.

I'll need to execute the writeReplace method then serialize the
returned proxy. Any ideas or suggestions are most welcome.

Cheers,

Peter.

Nate

unread,
Apr 11, 2010, 6:09:58 AM4/11/10
to kryo-...@googlegroups.com
Hard to foresee what issues you'll run into as you implement this using Kryo, but please feel free to post them as you go along. I'm pretty sure we can make it work. :)

-Nate



--
You received this message because you are subscribed to the "kryo-users" group.
http://groups.google.com/group/kryo-users

To unsubscribe, reply using "remove me" as the subject.

Peter

unread,
Apr 14, 2010, 3:33:07 AM4/14/10
to kryo-users
Thanks Nate, very much appreciated, I'll post my progress.

Cheers,

Peter.

On Apr 11, 8:09 pm, Nate <nathan.sw...@gmail.com> wrote:
> Hard to foresee what issues you'll run into as you implement this using
> Kryo, but please feel free to post them as you go along. I'm pretty sure we
> can make it work. :)
>
> -Nate
>

Reply all
Reply to author
Forward
0 new messages