[ http://jira.codehaus.org/browse/MEAR-96?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stephane Nicoll closed MEAR-96. ------------------------------- Assignee: Stephane Nicoll Resolution: Not A Bug Fix Version/s: 2.3.2 It's not a bug, it's a feature request. earSourceExcludes like the name says excludes the content of the earSourceDirectory. It's not meant to exclude anything that was packed in the ear. A lot of people are also using the exploded form as a deployment unit so even I implemented it, we would have a different content between the exploded form and the generate ear file. If you don't want a module to be included in the ear, exclude it (http://maven.apache.org/plugins/maven-ear-plugin/examples/excluding-a-module.html) or manage your dependencies so that it's excluded (dependency exclusion) > earSourceExcludes does not work for jar dependency filtering like > warSourceExcludes / packagingExcludes for the maven-war-plugin > -------------------------------------------------------------------------------------------------------------------------------- > > Key: MEAR-96 > URL: http://jira.codehaus.org/browse/MEAR-96 > Project: Maven 2.x Ear Plugin > Issue Type: Bug > Environment: Windows XP SP3 > Reporter: Scott Heaberlin > Assignee: Stephane Nicoll > Fix For: 2.3.2 > > Attachments: pom.xml > > > The earSourceExcludes parameter of the EarMojo does not appear to have any > effect on jar dependencies. Given the pom below, commons-logging.jar should > be excluded from the resultant .ear archive but is not. > The junit test for the ear mojo (test-project-014) uses earSourceExcludes but > only with files that are in the earSourceDirectory. > Similar functionality works for the maven-war-plugin (warSourceExcludes, > which was renamed to packagingExcludes) so it was a little confusing to find > that earSourceIncludes does not allow filtering in the same fashion. > ------ example pom.xml > <project xmlns="http://maven.apache.org/POM/4.0.0" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > http://maven.apache.org/maven-v4_0_0.xsd"> > <modelVersion>4.0.0</modelVersion> > <groupId>example</groupId> > <artifactId>example-ear</artifactId> > <packaging>ear</packaging> > <name>example-ear</name> > <version>0.1-SNAPSHOT</version> > <description> > sample ear project demonstrating effectiveness of > earSourceExcludes parameter of the maven-ear-plugin > </description> > <build> > <plugins> > <plugin> > <artifactId>maven-ear-plugin</artifactId> > <version>2.3.1</version> > <configuration> > > <earSourceDirectory>src/main/application</earSourceDirectory> > <earSourceExcludes>**/commons*</earSourceExcludes> > </configuration> > </plugin> > </plugins> > </build> > <dependencies> > <dependency> > <groupId>org.springframework</groupId> > <artifactId>spring-core</artifactId> > <version>1.2.7</version> > </dependency> > </dependencies> > </project> -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira