directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Richard Wallace <>
Subject Re: [mina] ProtocolHandler interface
Date Fri, 17 Dec 2004 15:21:57 GMT
Trustin Lee wrote:
> Hi.
> I admit I am very accustomed with Netty-like session handler
> interface, but the entry users like Alex and other persons would not
> feel so familiar with it:
> So I want to know what all of you guys are thinking about this
> ProtocolHandler interface, and to improve its usability.
> If most of protocols are OK with simple request-response-close
> connection model, it would be also possible to provide two difference
> interfaces, ProtocolHandler (simple one) and AdvancedProtocolHandler
> which extends ProtocolHandler and provides full event handler methods
> like the current revision of ProtocolHandler.
> If is absolutely OK if you can suggest me totally different and better
> interface of course.

I like the interface, overall.  Like I said a couple of days ago, I
think it is important to notify the handler of all the different network
events, so it has a way to responds accordingly.  I like the
messageSent() and you're reasoning behind it and the sessionOpened()
method would allow a handler to fire off an initial greeting, similar to
what I've been looking for with a ConnectionEstablishedEvent of some
sort.  I am a little confused on what the sessionIdle() is meant to do
tho, could you give a use case where a implementation that uses that?

I do agree with Berin too.  I'd like to see one interface for this stuff
in protocol-api.  That way, in the future, it would be easy to switch
between MINA and SEDA without having to write any glue code.


View raw message