You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using jersey 3.1.5 in combination with JAXB in a Weld Grizzly container it fails to parse application/xml content because it tries to create a SAX parser within a Threadscoped CDI context that does not exist.
org.jboss.weld.contexts.ContextNotActiveException: WELD-001303: No active contexts for scope type org.jboss.weld.environment.se.contexts.ThreadScoped
org.jboss.weld.environment.se.contexts.ThreadScoped\n\tat org.jboss.weld.manager.BeanManagerImpl.getContext(BeanManagerImpl.java:628)\n\tat org.jboss.weld.bean.ContextualInstanceStrategy$DefaultContextualInstanceStrategy.getIfExists(ContextualInstanceStrategy.java:89)\n\tat org.jboss.weld.bean.ContextualInstance.getIfExists(ContextualInstance.java:63)\n\tat org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:87)\n\tat org.jboss.weld.bean.proxy.ProxyMethodHandler.getInstance(ProxyMethodHandler.java:131)\n\tat org.jboss.weld.generated.proxiesx.xml.parsers.SAXParserFactory$Proxy$_$$_WeldClientProxy.newSAXParser(Unknown Source)\n\tat org.glassfish.jersey.jaxb.internal.AbstractJaxbProvider.getSAXSource(AbstractJaxbProvider.java:304)\n\t... 72 common frames omitted\n",
Which makes some sense as only ApplicationScoped; RequestScoped or Dependent contexts are active (by default).
Unfortunately I am not able to pinpoint the exact location for the cause of this issue.
Downgrading jersey-media-jaxb to 3.1.1 currently solves it for now.
Relevant project dependencies:
Jersey 3.1.5:
jersey-client
jersey-proxy-client
jersey-cdi2-se
jersey-media-jaxb *
jersey-apache-connector
jersey-server
jersey-container-grizzly2-http
Grizzly 4.0.2
grizzly-http-server
grizzly-http2
grizzly-npn-bootstrap
Jaxb 3.0.2:
jaxb-core
jaxb-xjc
jaxb-runtime
Weld 5.1.2-Final:
weld-se-core
The text was updated successfully, but these errors were encountered:
I'm not extending any code provided by the libraries. The Jersey Jaxb media feature is used as-is (autoloaded) and the CDI managed Jersey client is produced using the following code:
When using jersey 3.1.5 in combination with JAXB in a Weld Grizzly container it fails to parse application/xml content because it tries to create a SAX parser within a Threadscoped CDI context that does not exist.
Which makes some sense as only ApplicationScoped; RequestScoped or Dependent contexts are active (by default).
Unfortunately I am not able to pinpoint the exact location for the cause of this issue.
Relevant project dependencies:
Jersey 3.1.5:
Grizzly 4.0.2
Jaxb 3.0.2:
Weld 5.1.2-Final:
The text was updated successfully, but these errors were encountered: