<div dir="auto">Hi Sebastian<div dir="auto"><br></div><div dir="auto">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.</div><div dir="auto"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">Le 7 janv. 2017 13:45, &quot;Sebastian Daschner&quot; &lt;<a href="mailto:java@sebastian-daschner.de">java@sebastian-daschner.de</a>&gt; a écrit :<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi experts,<br>
<br>
Regarding scopes, specificly @RequestScoped: We found in enterprise<br>
projects that there is a need for a request / invocation scope that is<br>
active during an invocation of a business method (HTTP, JMS, EJB, timer,<br>
whatever), regardless how many threads are involved. Naively, one could<br>
presume that @RequestScoped would deal that, but since it&#39;s strictly<br>
single threaded and not accessible from asyncronously started threads<br>
(ManagedExecuterService and so forth) that doesn&#39;t help much.<br>
<br>
This scope would e.g. enable correlation IDs that are needed in all<br>
threads started from one original invocation. Name is up to better<br>
suggestions :-)<br>
<br>
I guess it&#39;s not possible to change the behavior of @RequestScoped and<br>
to make it available in asyncronously started threads? Have there been<br>
considerations for adding such a scope or similar in the past?<br>
<br>
Cheers,<br>
Sebastian<br>
<br>
______________________________<wbr>_________________<br>
cdi-dev mailing list<br>
<a href="mailto:cdi-dev@lists.jboss.org">cdi-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/cdi-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/<wbr>mailman/listinfo/cdi-dev</a><br>
<br>
Note that for all code provided on this list, the provider licenses the code under the Apache License, Version 2 (<a href="http://www.apache.org/licenses/LICENSE-2.0.html" rel="noreferrer" target="_blank">http://www.apache.org/<wbr>licenses/LICENSE-2.0.html</a>). For all other ideas provided on this list, the provider waives all patent and other intellectual property rights inherent in such information.<br>
</blockquote></div></div>