users@jersey.java.net

[Jersey] Jersey & CDI & Weld == No active contexts for scope type javax.enterprise.context.RequestScoped

From: Thomas Meyer <thomas_at_m3y3r.de>
Date: Wed, 23 Mar 2016 21:28:14 +0100

Hi,

I did install all necessary libraries into Tomcat's lib/ directory, so
they are available for all deployed webapps.

Versions are:
Tomcat 8.0.32
Jersey 2.22.2 (servlet and ext-cdi1x)
Weld 2.3.3.Final

and I did deploy two webapps into the webapps directory, both are using
JAX-RS.
Tomcat is running with unpackWars=false.

When only one webapp is deployed everything seems to work correctly.
But when I install both apps into the webapp directoy I get a similar
stacktrace likeĀ https://java.net/jira/browse/JERSEY-2930

I.e. "org.jboss.weld.context.ContextNotActiveException: WELD-001303: No
active contexts for scope type javax.enterprise.context.RequestScoped"

So is this bug or feature? what do you think about it

with kind regards
thomas