Thanks Olaf. Your response pretty much sums it up. :)
Jim, Thanks for the questions, Glad to know Shoal looks promising. Let
us know if you have more questions or if you see any issues.
ClusterManager.send() is an internal API or rather what we call part of
the Shoal Group Communication Provider API which the Shoal
implementation uses to send messages through Jxta platform.
When you send a message through Shoal's public api i.e.
GroupHandle.sendMessage() the payload and destination gets wrapped into
a GMSMessage object and that's sent through the clusterManager.send()
api. There may be potential for improving that but as far as apps are
concerned, as Olaf mentions, you could hook, a
serialization/deserialization module at the app end.
Thanks
Shreedhar
Olaf Krische wrote:
> Hello Jim,
>
>
> On Tue, Sep 30, 2008 at 09:38:05AM -0700, Jim Marino wrote:
>
>> I noticed in ClusterManager.send(final ID peerid, final Serializable
>> msg) messages are serialized using Java serialization. Since our
>> message classes will be loaded in a different classloaders than the
>> TCCL or the Shoal classloader, we need to insert a mechanism to handle
>> deserialization in our peer classloader environment. Currently, we
>> are using JXTA for communication and have implemented a mechanism to
>> handle serialization/deserialization in our environment. Is there a
>> way our runtime can hook into Shoal to perform message serialization/
>> deserialization? If not, would the best approach be to encode our
>>
>
> With Shoal you will always send messages as byte[]:
>
> GroupManagementService gms = ...;
> gms.getGroupHandle().sendMessage(..., byte[] message);
>
> And in reverse, you get byte[], wenn unpacking a message:
>
> String groupName = signal.getGroupName();
> String sender = signal.getMemberToken();
> if (signal instanceof MessageSignal) {
> MessageSignal messageSignal = (MessageSignal)signal;
> String targetComponent = messageSignal.getTargetComponent();
> byte[] message = messageSignal.getMessage()
> ...
> }
>
> So you can hook up your own serializer/deserializer.
>
> Hope it helps.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_shoal.dev.java.net
> For additional commands, e-mail: users-help_at_shoal.dev.java.net
>
>