Provided scope not being applied correctly

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Provided scope not being applied correctly

David Hoffer
I have a module that has a provided scope dependency on a zip file (just
resources so no need for any dependencies).  The zip was produced via the
maven-assembly-plugin in another module.

The problem is that transitive dependencies of this zip are being included
in the war being generated.

<dependency>
    <groupId>com.issinc.odin.webservice.client</groupId>
    <artifactId>odin-webservice-client-rd</artifactId>
    <type>zip</type>
    <classifier>wsdl</classifier>
    <scope>provided</scope>
</dependency>

Note its marked as provided so none of its dependencies should be included.

+-
com.issinc.odin.webservice.client:odin-webservice-client-rd:zip:wsdl:2.0-ODIN-SNAPSHOT:provided
[INFO] |  +-
com.issinc.odin.webservice.client:odin-webservice-client-common:jar:2.0-ODIN-SNAPSHOT:provided
[INFO] |  +-
com.issinc.jms.satcat.client.cxf:satcat-client-cxf-common:jar:11.25.0-ODIN-SNAPSHOT:provided
[INFO] |  |  \- org.apache.cxf:cxf-rt-ws-policy:jar:2.7.11:compile
[INFO] |  |     +- org.apache.cxf:cxf-api:jar:2.7.11:compile
[INFO] |  |     \- org.apache.cxf:cxf-rt-core:jar:2.7.11:compile
[INFO] |  \- org.apache.cxf.xjc-utils:cxf-xjc-runtime:jar:2.7.0:provided
[INFO] |     \- javax.xml.bind:jaxb-api:jar:2.1:provided
[INFO] |        +- javax.xml.stream:stax-api:jar:1.0-2:provided
[INFO] |        \- javax.activation:activation:jar:1.1:provided

Note the 3 compile time dependencies above, these are being included in the
war but should not be because they should be provided.

Ideally when I created the zip I'd like it to have have any dependencies at
all but when using it marking as provided should work too.

I'm using Maven 3.5.0.  What is going on here?

-Dave
Loading...