[ 
http://jira.codehaus.org/browse/MSHADE-55?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=184687#action_184687
 ] 

rick gordon commented on MSHADE-55:
-----------------------------------

let's see what i can pull out:
from the pom:
<build>...
   <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.0-beta-7</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-shade-plugin</artifactId>
          <version>1.2.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-resources-plugin</artifactId>
          <version>2.3</version>
        </plugin>
      </plugins>
    </pluginManagement>
  <plugins>...
    <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-shade-plugin</artifactId>
        <version>1.2.1</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
            <configuration>
              <!-- We exclude the META-INF directories of several artifacts 
because their jars are signed and including
                their signature-related files in the Shade-generated bundle jar 
causes exceptions at service startup
                like the following:               
                java.lang.SecurityException: no manifiest section for signature 
file entry javax/activation/MimeType.class -->
              <filters>
                <filter>
                  <artifact>javax.activation:activation</artifact>
                  <excludes>
                    <exclude>META-INF/**</exclude>
                  </excludes>
                </filter>
                <filter>
                  <artifact>javax.mail:mail</artifact>
                  <excludes>
                    <exclude>META-INF/**</exclude>
                  </excludes>
                </filter>
                <filter>
                  <artifact>com.microsoft.sqlserver.jdbc:sqljdbc</artifact>
                  <excludes>
                    <exclude>META-INF/**</exclude>
                  </excludes>
                </filter>
              </filters>            
              <artifactSet>
                <excludes>
                  <exclude>junit:junit</exclude>
                  <!-- these all contain duplicate classes -->
                   <exclude>org.apache.activemq:activemq-core</exclude>
                  <exclude>commons-logging:commons-logging-api</exclude>
                  
<exclude>org.apache.geronimo.specs:geronimo-jms_1.1_spec</exclude>
                  
<exclude>org.apache.geronimo.specs:geronimo-j2ee-management_1.0_spec</exclude>
                  <exclude>org.apache.activemq:activemq-optional</exclude>
                  <exclude>org.apache.activemq:activemq-jaas</exclude>
                  <exclude>org.apache.activemq:activemq-console</exclude>
                  <exclude>javax.xml.bind:jaxb-api</exclude>
                  <exclude>stax:stax-api</exclude>
                  <exclude>axis:axis-wsdl4j</exclude>
                  <exclude>aopalliance:aopalliance</exclude>
                  <exclude>jdom:jdom</exclude>
                  <exclude>javax.jms:jms</exclude>
                  <exclude>axis:axis-jaxrpc</exclude>
                   <!-- I removed various private jars from this list too -->
                </excludes>
              </artifactSet>
            </configuration>
          </execution>
        </executions>
      </plugin>


> dependency conflict causes only .class files included in jar, not .properties
> -----------------------------------------------------------------------------
>
>                 Key: MSHADE-55
>                 URL: http://jira.codehaus.org/browse/MSHADE-55
>             Project: Maven 2.x Shade Plugin
>          Issue Type: Bug
>    Affects Versions: 1.2.1
>         Environment: Maven 2.0.9, Windows
>            Reporter: rick gordon
>            Priority: Minor
>
> My pom had a direct dependency on one version of a jar (3.3.5), but several 
> of the transitive dependencies had a dependency on a later version (3.3.6). 
> Looking at maven debug output (-X) I could see that it was choosing the 3.3.5 
> version because it was 'nearer' than the the 3.3.6 version. But when 
> including it, it would only include the .class files and skip a .properties 
> file in it. Switching the original dependency to the newer version (3.3.6) 
> 'fixed' the problem, so that the .properties file was now included.

-- 
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

        

Reply via email to