History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: MNG-3555
Type: Bug Bug
Status: Open Open
Priority: Blocker Blocker
Assignee: Unassigned
Reporter: Trenton
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Maven 2

transitive dependency exclusion fails when classifier specified

Created: 28/Apr/08 12:26 PM   Updated: 12/Jun/08 06:58 PM
Component/s: Dependencies
Affects Version/s: 2.0.9
Fix Version/s: 2.0.x

Time Tracking:
Not Specified

File Attachments: 1. XML File pom.xml (8 kb)

Environment: Gentoo linux
Issue Links:
Related
 

Complexity: Intermediate


 Description  « Hide
I have a profile like the one below. When I enable that profile, maven refuses to exclude the dependencies as specified, unless I remove the classifier. This is basically preventing us from using maven. We will have to stick with ant until this is resolved.

A little bit of background. We have an rmi module and a web module. This profile is in the web module pom. The rmi project creates two different types of jars. One is the rmi server jar, the other the rmi client jar. In the case of the rmi server jar, all the dependencies would be required. And, we allow the rmi server to be run in process (under tomcat). In a case like that, we require all the dependencies. But, when running in standard RMI mode, and using the client jar, we do not need all those dependencies, nor do we want them to be there.

<profile>
<!-- use full rmi when doing development, even if inproc server -->
<id>client</id>
<build>
<resources>
<!-- Copy configurations over to webapp folder -->
<resource>
<filtering>true</filtering>
<directory>${basedir}/src/main/resources</directory>
<excludes> <!-- Don't need these in production -->
<exclude>server.properties</exclude>
<exclude>response_codes.properties</exclude>
</excludes>
</resource>
</resources>
</build>
<dependencies>
<dependency>
<groupId>ca.athabascau.banner.oros</groupId>
<artifactId>rmi</artifactId>
<version>1.1.23-SNAPSHOT</version>
<scope>compile</scope>
<classifier>client</classifier>
<exclusions>
<exclusion>
<groupId>ca.athabascau</groupId>
<artifactId>moneris-test</artifactId>
</exclusion>
<exclusion>
<groupId>com.oracle.ojdbc</groupId>
<artifactId>ojdbc14</artifactId>
</exclusion>
<exclusion>
<groupId>com.novell</groupId>
<artifactId>java-ldap</artifactId>
</exclusion>
<exclusion>
<groupId>commons-dbcp</groupId>
<artifactId>commons-dbcp</artifactId>
</exclusion>
<exclusion>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
</exclusion>
<exclusion>
<groupId>commons-pool</groupId>
<artifactId>commons-pool</artifactId>
</exclusion>
<exclusion>
<groupId>cas</groupId>
<artifactId>casclient</artifactId>
</exclusion>
<exclusion>
<groupId>xerces</groupId>
<artifactId>xercesImpl</artifactId>
</exclusion>
<exclusion>
<groupId>oro</groupId>
<artifactId>oro</artifactId>
</exclusion>
<exclusion>
<groupId>xml-apis</groupId>
<artifactId>xml-apis</artifactId>
</exclusion>
<exclusion>
<groupId>javax.activation</groupId>
<artifactId>activation</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</profile>



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Trenton - 28/Apr/08 12:31 PM
Oh, one other thing. I think this MAY be related to this other bug, but perhaps not quite the same?
http://jira.codehaus.org/browse/MNG-1823

Trenton - 28/Apr/08 04:38 PM
On second thought, it's not a show stopper. But, sure is annoying.

Trenton - 30/Apr/08 11:35 AM
Note the "rmi" dependency in the main dependencies section with the "provided" scope. Also note the "client" profile.