directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trustin Lee <trus...@gmail.com>
Subject Re: [mina] Refactoring MINA IoFilterChain (Was: IoFilters: DIRMINA-121 / 122)
Date Tue, 15 Nov 2005 02:36:00 GMT
2005/11/15, Trustin Lee <trustin@gmail.com>:
>
> 1) There should be only *one* NextFilter implementation for all filters in
> the same chain for thread safety, and upstream/downstream (forwarding)
> operations should be executed in head or tail filter. It can be overriden by
> overriding createHeadFilter and createTailFilter. (and this is the same way
> Dave suggested to us, but the current implementation hides head and tail
> from the filter list to keep OOP encapsulation principal :)


I forgot to mention that we can remove createHead/TailFilter and let users
to specify them as constructor parameters.

Not let's consider Jose's IoFilterChainBuilder. It is really simple solution
> and work without any big changes. The only problem with the builder pattern
> is that it can be abused to contain more than just building. A user can even
> call System.exit(0) there. :) But it is entirely up to users eventually.
> So I'd like to choose Jose's approach. I thought his approach adds more
> complexity to the API, but now I think it is a way simpler and easy to
> understand.


Not -> Now

Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/

Mime
View raw message