[ http://jira.codehaus.org/browse/MEAR-44?page=comments#action_77202 ]
Stephane Nicoll commented on MEAR-44:
-------------------------------------
OK Cédric, I had a look to your patch and it seems that you misunderstood the
purpose of the modules configuration element.
You can specify a classfier in your dependency section and it will be actually
taken into account by the EAR plugin. You don't need to specify anything in the
modules configuration element BUT if you need to customize some stuff.
So don't specify a classifier and it will work as expected.
Now it makes sense to apply your patch anyway if we want the same dependency
for multiple classifiers. Is it your use case?
{code:xml}
<project>
<modelVersion>4.0.0</modelVersion>
[...]
<dependencies>
<dependency>
<groupId>company1</groupId>
<artifactId>server</artifactId>
<type>ejb</type>
<classifier>dev</classifier>
<version>1.0.1</version>
</dependency>
<dependency>
<dependency>
<groupId>company1</groupId>
<artifactId>server</artifactId>
<type>ejb</type>
<classifier>prod</classifier>
<version>1.0.1</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<configuration>
<modules>
<ejbModule>
<groupId>company1</groupId>
<artifactId>server</artifactId>
<classifier>dev</classifier>
<unpack>true</unpack>
</ejbModule>
</modules>
</configuration>
</plugin>
</plugins>
</build>
</project>
{code}
If the classifier is unique for a dependency we don't need to specify it in the
modules configuration section.
Thoughts?
> Artifact classifier cannot be specified in modules
> --------------------------------------------------
>
> Key: MEAR-44
> URL: http://jira.codehaus.org/browse/MEAR-44
> Project: Maven 2.x Ear Plugin
> Issue Type: Bug
> Affects Versions: 2.2
> Reporter: Cédric Vidal
> Assigned To: Stephane Nicoll
> Priority: Critical
> Attachments: ejb-sample-one-1.0-classified.jar, MEAR-44.patch
>
>
> It should be possible to specify a module using a classifier.
> Cheers.
--
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