ws-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From veit...@apache.org
Subject svn commit: r1795801 - in /webservices/axiom/trunk: ./ aspects/ aspects/core-aspects/ aspects/dom-aspects/ aspects/fom-aspects/ aspects/om-aspects/ aspects/shared-aspects/ axiom-api/ buildutils/ buildutils/shade-osgi/ components/ components/base64-util...
Date Mon, 22 May 2017 12:56:08 GMT
Author: veithen
Date: Mon May 22 12:56:08 2017
New Revision: 1795801

URL: http://svn.apache.org/viewvc?rev=1795801&view=rev
Log:
Use maven-bundle-plugin instead of maven-shade-plugin to include aspects and components into
OSGi bundles. This should also solve AXIOM-424.

Removed:
    webservices/axiom/trunk/buildutils/shade-osgi/
Modified:
    webservices/axiom/trunk/aspects/core-aspects/pom.xml
    webservices/axiom/trunk/aspects/dom-aspects/pom.xml
    webservices/axiom/trunk/aspects/fom-aspects/pom.xml
    webservices/axiom/trunk/aspects/om-aspects/pom.xml
    webservices/axiom/trunk/aspects/pom.xml
    webservices/axiom/trunk/aspects/shared-aspects/pom.xml
    webservices/axiom/trunk/axiom-api/pom.xml
    webservices/axiom/trunk/buildutils/pom.xml
    webservices/axiom/trunk/components/base64-utils/pom.xml
    webservices/axiom/trunk/components/core-streams/pom.xml
    webservices/axiom/trunk/components/pom.xml
    webservices/axiom/trunk/components/xml-utils/pom.xml
    webservices/axiom/trunk/implementations/axiom-dom/pom.xml
    webservices/axiom/trunk/implementations/axiom-impl/pom.xml
    webservices/axiom/trunk/implementations/fom-impl/pom.xml
    webservices/axiom/trunk/implementations/pom.xml
    webservices/axiom/trunk/pom.xml

Modified: webservices/axiom/trunk/aspects/core-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/core-aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/core-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/core-aspects/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>core-aspects</artifactId>
-    <packaging>bundle</packaging>
 
     <name>Core Aspects</name>
     <url>http://ws.apache.org/axiom/</url>

Modified: webservices/axiom/trunk/aspects/dom-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/dom-aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/dom-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/dom-aspects/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>dom-aspects</artifactId>
-    <packaging>bundle</packaging>
 
     <name>DOM Aspects</name>
     <url>http://ws.apache.org/axiom/</url>

Modified: webservices/axiom/trunk/aspects/fom-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/fom-aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/fom-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/fom-aspects/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>fom-aspects</artifactId>
-    <packaging>bundle</packaging>
 
     <name>FOM Aspects</name>
     <url>http://ws.apache.org/axiom/</url>

Modified: webservices/axiom/trunk/aspects/om-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/om-aspects/pom.xml Mon May 22 12:56:08 2017
@@ -27,10 +27,6 @@
     </parent>
 
     <artifactId>om-aspects</artifactId>
-    <!-- Although om-aspects will never be used as a bundle itself, we still need the
OSGi metadata
-         so that we can generate a correct manifest when the classes are included in axiom-impl
and
-         axiom-dom by maven-shade-plugin. -->
-    <packaging>bundle</packaging>
 
     <name>OM Aspects</name>
     <description>Contains aspects and implementation classes shared by LLOM and DOOM.</description>

Modified: webservices/axiom/trunk/aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/pom.xml Mon May 22 12:56:08 2017
@@ -66,24 +66,6 @@
                 </executions>
             </plugin>
             <plugin>
-                <!-- Note: Aspect libraries are not intended to be used as an OSGi bundle.
-                     We generate OSGi metadata only for the shading process in the implementations.
-->
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-bundle-plugin</artifactId>
-                <extensions>true</extensions>
-                <configuration>
-                    <instructions>
-                        <Export-Package>*;-noimport:=true</Export-Package>
-                        <Import-Package>
-                            <!-- aspectjrt is not an OSGi bundle; we don't need to generate
imports because
-                                 the implementations include these classes into the final
JARs -->
-                            !org.aspectj.*,
-                            *
-                        </Import-Package>
-                    </instructions>
-                </configuration>
-            </plugin>
-            <plugin>
                 <groupId>com.github.veithen.phos</groupId>
                 <artifactId>enforcer-maven-plugin</artifactId>
                 <executions>

Modified: webservices/axiom/trunk/aspects/shared-aspects/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/shared-aspects/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/shared-aspects/pom.xml (original)
+++ webservices/axiom/trunk/aspects/shared-aspects/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>shared-aspects</artifactId>
-    <packaging>bundle</packaging>
 
     <name>Shared Aspects</name>
     <description>

Modified: webservices/axiom/trunk/axiom-api/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/axiom-api/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/axiom-api/pom.xml (original)
+++ webservices/axiom/trunk/axiom-api/pom.xml Mon May 22 12:56:08 2017
@@ -229,10 +229,14 @@
                 <extensions>true</extensions>
                 <configuration>
                     <instructions>
-                        <Export-Package>*;-noimport:=true</Export-Package>
+                        <Private-Package />
+                        <Export-Package>
+                            org.apache.axiom.*;-split-package:=merge-first;-noimport:=true
+                        </Export-Package>
                         <Import-Package>
                             org.jaxen.*;resolution:=optional,
                             org.codehaus.stax2;resolution:=optional,
+                            org.apache.james.mime4j.*;version="${range;[==,=+)}",
                             *
                         </Import-Package>
                         <Bundle-Activator>org.apache.axiom.locator.Activator</Bundle-Activator>
@@ -245,36 +249,6 @@
                     </instructions>
                 </configuration>
             </plugin>
-            <plugin>
-                <artifactId>maven-shade-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <phase>package</phase>
-                        <goals>
-                            <goal>shade</goal>
-                        </goals>
-                    </execution>
-                </executions>
-                <configuration>
-                    <artifactSet>
-                        <includes>
-                            <include>${project.groupId}:base64-utils</include>
-                        </includes>
-                    </artifactSet>
-                    <transformers>
-                        <transformer implementation="org.apache.axiom.buildutils.shade.osgi.OSGiManifestResourceTransformer"
/>
-                    </transformers>
-                    <createDependencyReducedPom>false</createDependencyReducedPom>
-                    <createSourcesJar>true</createSourcesJar>
-                </configuration>
-                <dependencies>
-                    <dependency>
-                        <groupId>${project.groupId}</groupId>
-                        <artifactId>shade-osgi</artifactId>
-                        <version>${project.version}</version>
-                    </dependency>
-                </dependencies>
-            </plugin>
             <!--
                 Attach a JAR with the test classes so that we can reuse them in
                 other modules (see

Modified: webservices/axiom/trunk/buildutils/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/buildutils/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/buildutils/pom.xml (original)
+++ webservices/axiom/trunk/buildutils/pom.xml Mon May 22 12:56:08 2017
@@ -35,7 +35,6 @@
     <modules>
         <module>jar-resource-bundle</module>
         <module>shade-axiom-xml</module>
-        <module>shade-osgi</module>
         <module>javadoc-postprocessor-maven-plugin</module>
     </modules>
 

Modified: webservices/axiom/trunk/components/base64-utils/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/components/base64-utils/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/components/base64-utils/pom.xml (original)
+++ webservices/axiom/trunk/components/base64-utils/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>base64-utils</artifactId>
-    <packaging>bundle</packaging>
 
     <url>http://ws.apache.org/axiom/</url>
 </project>

Modified: webservices/axiom/trunk/components/core-streams/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/components/core-streams/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/components/core-streams/pom.xml (original)
+++ webservices/axiom/trunk/components/core-streams/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>core-streams</artifactId>
-    <packaging>bundle</packaging>
 
     <url>http://ws.apache.org/axiom/</url>
 

Modified: webservices/axiom/trunk/components/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/components/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/components/pom.xml (original)
+++ webservices/axiom/trunk/components/pom.xml Mon May 22 12:56:08 2017
@@ -40,11 +40,6 @@
     <build>
         <plugins>
             <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-bundle-plugin</artifactId>
-                <extensions>true</extensions>
-            </plugin>
-            <plugin>
                 <groupId>com.github.veithen.phos</groupId>
                 <artifactId>enforcer-maven-plugin</artifactId>
                 <executions>

Modified: webservices/axiom/trunk/components/xml-utils/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/components/xml-utils/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/components/xml-utils/pom.xml (original)
+++ webservices/axiom/trunk/components/xml-utils/pom.xml Mon May 22 12:56:08 2017
@@ -27,7 +27,6 @@
     </parent>
 
     <artifactId>xml-utils</artifactId>
-    <packaging>bundle</packaging>
 
     <url>http://ws.apache.org/axiom/</url>
 

Modified: webservices/axiom/trunk/implementations/axiom-dom/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/implementations/axiom-dom/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/implementations/axiom-dom/pom.xml (original)
+++ webservices/axiom/trunk/implementations/axiom-dom/pom.xml Mon May 22 12:56:08 2017
@@ -122,15 +122,25 @@
                 </configuration>
             </plugin>
             <plugin>
-                <artifactId>maven-shade-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <phase>package</phase>
-                        <goals>
-                            <goal>shade</goal>
-                        </goals>
-                    </execution>
-                </executions>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <Import-Package>!org.aspectj.*,*</Import-Package>
+                        <Private-Package>
+                            org.apache.axiom.core.*,
+                            !org.apache.axiom.om.impl,
+                            org.apache.axiom.om.impl.*,
+                            org.apache.axiom.soap.impl.*,
+                            org.apache.axiom.dom.*,
+                            org.apache.axiom.shared.*,
+                            org.apache.axiom.util.xml.*,
+                            org.aspectj.lang,
+                            org.aspectj.lang.annotation
+                        </Private-Package>
+                    </instructions>
+                </configuration>
             </plugin>
         </plugins>
     </build>

Modified: webservices/axiom/trunk/implementations/axiom-impl/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/implementations/axiom-impl/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/implementations/axiom-impl/pom.xml (original)
+++ webservices/axiom/trunk/implementations/axiom-impl/pom.xml Mon May 22 12:56:08 2017
@@ -106,15 +106,24 @@
                 </configuration>
             </plugin>
             <plugin>
-                <artifactId>maven-shade-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <phase>package</phase>
-                        <goals>
-                            <goal>shade</goal>
-                        </goals>
-                    </execution>
-                </executions>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <Import-Package>!org.aspectj.*,*</Import-Package>
+                        <Private-Package>
+                            org.apache.axiom.core.*,
+                            !org.apache.axiom.om.impl,
+                            org.apache.axiom.om.impl.*,
+                            org.apache.axiom.soap.impl.*,
+                            org.apache.axiom.shared.*,
+                            org.apache.axiom.util.xml.*,
+                            org.aspectj.lang,
+                            org.aspectj.lang.annotation
+                        </Private-Package>
+                    </instructions>
+                </configuration>
             </plugin>
         </plugins>
     </build>

Modified: webservices/axiom/trunk/implementations/fom-impl/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/implementations/fom-impl/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/implementations/fom-impl/pom.xml (original)
+++ webservices/axiom/trunk/implementations/fom-impl/pom.xml Mon May 22 12:56:08 2017
@@ -134,15 +134,24 @@
                 </configuration>
             </plugin>
             <plugin>
-                <artifactId>maven-shade-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <phase>package</phase>
-                        <goals>
-                            <goal>shade</goal>
-                        </goals>
-                    </execution>
-                </executions>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <Import-Package>!org.aspectj.*,*</Import-Package>
+                        <Private-Package>
+                            org.apache.axiom.core.*,
+                            org.apache.axiom.om.impl.*,
+                            org.apache.axiom.soap.impl.*,
+                            org.apache.axiom.shared.*,
+                            org.apache.axiom.fom.*,
+                            org.apache.axiom.util.xml.*,
+                            org.aspectj.lang,
+                            org.aspectj.lang.annotation
+                        </Private-Package>
+                    </instructions>
+                </configuration>
             </plugin>
             <plugin>
                 <groupId>com.github.veithen.alta</groupId>

Modified: webservices/axiom/trunk/implementations/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/implementations/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/implementations/pom.xml (original)
+++ webservices/axiom/trunk/implementations/pom.xml Mon May 22 12:56:08 2017
@@ -78,42 +78,10 @@
                 <configuration>
                     <instructions>
                         <Bundle-ActivationPolicy>lazy</Bundle-ActivationPolicy>
-                        <Import-Package>!org.aspectj.*,*</Import-Package>
                     </instructions>
                 </configuration>
             </plugin>
             <plugin>
-                <artifactId>maven-shade-plugin</artifactId>
-                <configuration>
-                    <artifactSet>
-                        <includes>
-                            <include>${project.groupId}:*-aspects</include>
-                            <include>${project.groupId}:core-streams</include>
-                            <include>${project.groupId}:xml-utils</include>
-                            <include>org.aspectj:aspectjrt</include>
-                        </includes>
-                    </artifactSet>
-                    <transformers>
-                        <transformer implementation="org.apache.axiom.buildutils.shade.osgi.OSGiManifestResourceTransformer"
/>
-                    </transformers>
-                    <!-- Avoid dependency reduced POMs because the artifacts are used
as dependencies by other modules
-                         in the project and this causes recurring problems. E.g. in Maven
3.3, downstream modules in the
-                         same build still see the original dependencies of the unshaded JAR.
Instead of producing
-                         dependency reduced POMs, we simply declare the relevant dependencies
as optional. -->
-                    <createDependencyReducedPom>false</createDependencyReducedPom>
-                    <!-- This removes most of the AspectJ runtime classes from the shaded
JAR -->
-                    <minimizeJar>true</minimizeJar>
-                    <createSourcesJar>true</createSourcesJar>
-                </configuration>
-                <dependencies>
-                    <dependency>
-                        <groupId>${project.groupId}</groupId>
-                        <artifactId>shade-osgi</artifactId>
-                        <version>${project.version}</version>
-                    </dependency>
-                </dependencies>
-            </plugin>
-            <plugin>
                 <groupId>com.github.veithen.phos</groupId>
                 <artifactId>enforcer-maven-plugin</artifactId>
                 <executions>

Modified: webservices/axiom/trunk/pom.xml
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/pom.xml?rev=1795801&r1=1795800&r2=1795801&view=diff
==============================================================================
--- webservices/axiom/trunk/pom.xml (original)
+++ webservices/axiom/trunk/pom.xml Mon May 22 12:56:08 2017
@@ -527,10 +527,8 @@
                 <plugin>
                     <groupId>org.apache.felix</groupId>
                     <artifactId>maven-bundle-plugin</artifactId>
-                    <!-- Note: don't use 2.5.4 because of FELIX-4882 -->
-                    <version>2.5.3</version>
+                    <version>3.3.0</version>
                     <configuration>
-                        <excludeDependencies>true</excludeDependencies>
                         <instructions>
                             <_removeheaders>
                                 <!-- Remove these headers to make the output deterministic
-->
@@ -538,8 +536,8 @@
                                 <!-- There are not OSGi headers and shouldn't appear in
the manifest -->
                                 Private-Package,Include-Resource
                             </_removeheaders>
-                            <!-- These two are for compatibility with maven-bundle-plugin
1.4.0 -->
                             <_nodefaultversion>true</_nodefaultversion>
+                            <_consumer-policy>${range;[--,++)}</_consumer-policy>
                             <Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
                         </instructions>
                     </configuration>



Mime
View raw message