Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Jetty 9 - can same thread become carrier for another request?

Hi,

On Sun, Jul 31, 2016 at 11:02 PM, Sunny Singh <mailtosunny85@xxxxxxxxx> wrote:
> Thanks Bill! Thats what I also thought initially. But, this is what bothered
> me:
>
> 1. Thread-1 stored something in a  InheritableThreadLocal variable and
> started an operation which required a database call etc.
> 2. Thread-2 progresses and sets something in its own InheritableThreadLocal
> variable.
> 3. When Thread-1 becomes active and starts processing, I see that Thread ID
> is still Thread-1 but the InheritableThreadLocal variable now reflects what
> was set by Thread-2.

That would be a JDK bug, but I doubt.
I would double check what you are doing.

-- 
Simone Bordet
----
http://cometd.org
http://webtide.com
Developer advice, training, services and support
from the Jetty & CometD experts.


Back to the top