|
Home > Archive > Apache Directory Project > November 2005 > [MINA] MessageHandler interface
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
[MINA] MessageHandler interface
|
|
| Jose Alberto Fernandez 2005-10-31, 5:45 pm |
|
Hi guys,
It there any reason why
org.apache.mina.protocol.handler.MessageHandler.messageReceived() does
not allow throwing an Exception? I would have thought the signature
should be similar to
org.apache.mina.protocol.ProtocolHandler.messageReceived().
This means you need to treat error conditions differently depending if
you use one implementation strategy or another.
Any thoughts about it?
Jose Alberto
| |
| Trustin Lee 2005-11-02, 8:45 pm |
| Hi Jose,
2005/10/31, Jose Alberto Fernandez <jalberto-FQMVDHFwfny6lNtOUNzE6A@public.gmane.org>:
>
> It there any reason why
> org.apache.mina.protocol.handler.MessageHandler.messageReceived() does
> not allow throwing an Exception? I would have thought the signature
> should be similar to
> org.apache.mina.protocol.ProtocolHandler.messageReceived().
>
> This means you need to treat error conditions differently depending if
> you use one implementation strategy or another.
It was my mistake. Thank you for the heads up! I checked in the fix:
http://issues.apache.org/jira/browse/DIRMINA-111
Thanks,
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
| |
| Jose Alberto Fernandez 2005-11-04, 7:45 am |
| Thanks for the quick fix.
Another matter around Demux, is that currently it only looks at
super-interfaces if a direct match is not found,
But it does not look at super-classes. This is annoying when you have
protocols that extend all messages from some particular superclass and
you want to be able to treat groups of messages the same way (like
ignoring them).
Also, it may be interesting to see if there is a good way to cache the
resolution of super-interfaces and super-classes in order to make such
code more efficient. You will just need to make sure that the cache is
flushed when MessageHandlers are added or removed.
Keep the good work,
Jose Alberto
________________________________
From: Trustin Lee [mailto:trustin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org]
Sent: 03 November 2005 01:11
To: Apache Directory Developers List
Subject: Re: [MINA] MessageHandler interface
Hi Jose,
2005/10/31, Jose Alberto Fernandez <jalberto-FQMVDHFwfny6lNtOUNzE6A@public.gmane.org>:
It there any reason why
org.apache.mina.protocol.handler.MessageHandler.messageReceived() does
not allow throwing an Exception? I would have thought the signature
should be similar to
org.apache.mina.protocol.ProtocolHandler.messageReceived ().
This means you need to treat error conditions differently depending if
you use one implementation strategy or another.
It was my mistake. Thank you for the heads up! I checked in the fix:
http://issues.apache.org/jira/browse/DIRMINA-111
Thanks,
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
| |
| Trustin Lee 2005-11-08, 5:45 pm |
| Hi Jose,
I created a JIRA issue for this issue so you can track it:
http://issues.apache.org/jira/browse/DIRMINA-118
Trustin
2005/11/4, Jose Alberto Fernandez <jalberto-FQMVDHFwfny6lNtOUNzE6A@public.gmane.org>:
>
> Thanks for the quick fix.
>
> Another matter around Demux, is that currently it only looks at
> super-interfaces if a direct match is not found,
>
> But it does not look at super-classes. This is annoying when you have
> protocols that extend all messages from some particular superclass and you
> want to be able to treat groups of messages the same way (like ignoring
> them).
>
> Also, it may be interesting to see if there is a good way to cache the
> resolution of super-interfaces and super-classes in order to make such code
> more efficient. You will just need to make sure that the cache is flushed
> when MessageHandlers are added or removed.
>
> Keep the good work,
>
> Jose Alberto
>
> ------------------------------
>
> *From:* Trustin Lee [mailto:trustin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org]
> *Sent:* 03 November 2005 01:11
> *To:* Apache Directory Developers List
> *Subject:* Re: [MINA] MessageHandler interface
>
> Hi Jose,
>
> 2005/10/31, Jose Alberto Fernandez <jalberto-FQMVDHFwfny6lNtOUNzE6A@public.gmane.org>:
>
> It there any reason why
> org.apache.mina.protocol.handler.MessageHandler.messageReceived() does
> not allow throwing an Exception? I would have thought the signature
> should be similar to
> org.apache.mina.protocol.ProtocolHandler.messageReceived ().
>
> This means you need to treat error conditions differently depending if
> you use one implementation strategy or another.
>
>
> It was my mistake. Thank you for the heads up! I checked in the fix:
>
> http://issues.apache.org/jira/browse/DIRMINA-111
>
> Thanks,
> Trustin
>
> --
> what we call human nature is actually human habit
> --
> http://gleamynode.net/
>
--
what we call human nature is actually human habit
--
http://gleamynode.net/
|
|
|
|
|