[vos-d] Sending unrecognized messages to S4
Peter Amstutz
tetron at interreality.org
Sun Feb 25 22:53:16 EST 2007
Yea, that's reasonable. It should be a core:error method though, and
you'll want to come up with an error code and maybe raise an exception
on the caller.
On Sat, Feb 24, 2007 at 08:24:36PM -0500, Reed Hedges wrote:
>
> I encountered a problem in S4 just now: if you send a message to an
> object for which there is no handler registered, it basically ignores
> it. If the sender happens to be waiting for a reply,
> then it has to wait for the full timeout.
>
> However, we have a fairly well defined way of replying to messages in
> VOS, so it could reply with an "unhandled message" error.
>
> E.g. the receiving Vobject can do this, I think? --
>
>
> if(...Message msg not handled...) {
> Message err;
> err.setNonce(msg->getNonce());
> err.setMethod(msg->getMethod() + "-reply"); // Or maybe "core:error"
> instead?
> err.insertField("error", "Unrecognized message method: " +
> msg->getMethod());
> err.setType("reply"); // ?? or "update"?
> from->sendMessage(err);
> }
>
>
> Does this make sense? Can I add it? (It would be in
> VobjectBase::msgSendImpl() I think)
--
[ Peter Amstutz ][ tetron at interreality.org ][ peter.amstutz at gdit.com ]
[Lead Programmer][Interreality Project][Virtual Reality for the Internet]
[ VOS: Next Generation Internet Communication][ http://interreality.org ]
[ http://interreality.org/~tetron ][ pgpkey: pgpkeys.mit.edu 18C21DF7 ]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://www.interreality.org/pipermail/vos-d/attachments/20070225/6158a40f/attachment.pgp
More information about the vos-d
mailing list