Hi Emmanuel,

It won't be possible for me to provide with a reproducible test setup *at
the moment*.. Unfortunately our business logic is quite tightly integrated
with MINA constructs (encoder/decoder/handler/session etc.) and it will not
be easy to separate. However once I get some time off, I will look in to it.

-Dhruv

On Thu, Nov 29, 2012 at 2:19 PM, Emmanuel Lécharny <[email protected]>wrote:

> Le 11/29/12 5:16 AM, Dhruv Chopra a écrit :
> > So I tried acquiring the lock (added a new session attribute in
> > sessionCreated as suggested) when the encoder A starts encoding and
> unlock
> > after encoder B has written its output. However that didn't fix the
> > problem. In fact I then also some exceptions where a thread was trying to
> > unlock a resource it didn't own. I suppose it means that its not
> guaranteed
> > that the same thread will encode a message through all the filters.
> > Finally I synchronized the method that writes to a session in IoHandler
> > itself and the problem appears to have gone. I was able to do its since I
> > was already maintaining a wrapper around each IoSesion for some business
> > logic - and everywhere I needed to write to a session, it was going
> through
> > this wrapper.
>
> Ok, cool to see you have found a workaround. Altough it might be a
> contention point...
>
> It would be interesting for us to be able to have a reproductible
> example we can play with, if you can provide it (of course, with all the
> business part removed).
> Is that something possible ?
>
> --
> Regards,
> Cordialement,
> Emmanuel Lécharny
> www.iktek.com
>
>

Reply via email to