[cdi-dev] InvocationScoped | RequestScoped thread context
rmannibucau at gmail.com
Sat Jan 7 10:13:41 EST 2017
Think we spoke of it and request scope is single threaded but should
propagate following servlet spec. That said i agree cdi misses a manually
controlled and inheritable scope. Implemented it 4-5 times last 2 years.
Le 7 janv. 2017 13:45, "Sebastian Daschner" <java at sebastian-daschner.de> a
> Hi experts,
> Regarding scopes, specificly @RequestScoped: We found in enterprise
> projects that there is a need for a request / invocation scope that is
> active during an invocation of a business method (HTTP, JMS, EJB, timer,
> whatever), regardless how many threads are involved. Naively, one could
> presume that @RequestScoped would deal that, but since it's strictly
> single threaded and not accessible from asyncronously started threads
> (ManagedExecuterService and so forth) that doesn't help much.
> This scope would e.g. enable correlation IDs that are needed in all
> threads started from one original invocation. Name is up to better
> suggestions :-)
> I guess it's not possible to change the behavior of @RequestScoped and
> to make it available in asyncronously started threads? Have there been
> considerations for adding such a scope or similar in the past?
> cdi-dev mailing list
> cdi-dev at lists.jboss.org
> Note that for all code provided on this list, the provider licenses the
> code under the Apache License, Version 2 (http://www.apache.org/
> licenses/LICENSE-2.0.html). For all other ideas provided on this list,
> the provider waives all patent and other intellectual property rights
> inherent in such information.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cdi-dev