directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trustin Lee <trus...@gmail.com>
Subject Re: [jira] Commented: (DIRMINA-121) Per-port filter chain
Date Thu, 17 Nov 2005 12:45:49 GMT
2005/11/17, Jose Alberto Fernandez <jalberto@cellectivity.com>:
>
> My only point here is that caching NextFilter per se is useless.
> I originally thought we were caching NextFilter because we will not have
> a seesion to obtain it from. (That was my lala-land).


You're right. Caching is not the point. Look at this example:

NextFilter nextFilter = session.getIoFilterChain().getNextFilter( this ); //
--- (1)
nextFilter.exceptionCaught( session, new ResponseTimeoutException() ); //
--- (2)

If the reference of the nextFilter of 'this' changes internally between (1)
and (2), this code won't work. We cannot simply wrap this code with
synchronized block because it is very unconvenient. So the reference should
never change whenever getNextFilter() is invoked. That's my point.

I think all of us understood your and my point, so we can let Dave implement
his great idea. :)

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

Mime
View raw message