Maarten Bosteels-4 wrote: > > Of course, your code should not assume that two messageReceived events for > the same IoSession will be handled by the same thread. > So storing something in a threadlocal in the first messageReceived event > and > trying to retrieve it in the second event is NOT safe. > (at least not in combination with an executorfilter) > But that's rather obvious, I guess. >
The various ThreadLocals only come into play once the message has already been received in its entirety and is being processed by the application-- in fact, I put the ExecutorFilter AFTER the protocol filter to ensure this. Sound ok? Chris -- View this message in context: http://www.nabble.com/ThreadLocal-with-Mina%3A-ok-or-not--tf4354098s16868.html#a12410308 Sent from the Apache MINA Support Forum mailing list archive at Nabble.com.
