[
https://issues.apache.org/jira/browse/CXF-5421?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Christophe Levesque closed CXF-5421.
------------------------------------
Saw the change in
http://svn.apache.org/repos/asf/cxf/trunk/rt/rs/security/oauth-parent/oauth2/pom.xml.
Thanks!
> Servlet dependency in OAuth2 pom.xml should be with scope "provided"
> --------------------------------------------------------------------
>
> Key: CXF-5421
> URL: https://issues.apache.org/jira/browse/CXF-5421
> Project: CXF
> Issue Type: Bug
> Components: JAX-RS, JAX-RS Security
> Reporter: Christophe Levesque
> Assignee: Sergey Beryozkin
> Fix For: 3.0.0-milestone2, 2.7.9
>
>
> From cxf-rt-rs-security-oauth2's pom.xml:
> <dependency>
> <groupId>${cxf.servlet-api.group}</groupId>
> <artifactId>${cxf.servlet-api.artifact}</artifactId>
> <version>${cxf.servlet-api.version}</version>
> </dependency>
> This should have a <scope>provided</scope> otherwise the servlet JAR will be
> pulled in as a transitive dependency. It may conflict with the container's
> own servlet and throw exceptions like:
> Caused by: java.lang.ClassCastException:
> org.springframework.web.SpringServletContainerInitializer cannot be cast to
> javax.servlet.ServletContainerInitializer
> at
> org.apache.catalina.startup.ContextConfig.getServletContainerInitializer(ContextConfig.java:1670)
> at
> org.apache.catalina.startup.ContextConfig.getServletContainerInitializers(ContextConfig.java:1652)
> at
> org.apache.catalina.startup.ContextConfig.processServletContainerInitializers(ContextConfig.java:1562)
> at
> org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1270)
> at
> org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
> at
> org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:376)
> at
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5322)
> at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
> ... 6 more
--
This message was sent by Atlassian JIRA
(v6.1#6144)