This is an automated email from the ASF dual-hosted git repository. heneveld pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/brooklyn-dist.git
commit 151265a3a99015daca8e31ebb0eefc7fc04c1cfc Author: Alex Heneveld <[email protected]> AuthorDate: Tue Mar 30 14:07:20 2021 +0100 build a KAR and use that for the assembly moves all the resources to the features (kar) build, and the assembly is then pretty trivial The resulting assembly has no significant differences, but the slight differences for reference are: * excludes old versions of four libraries (com/hierynomus/sshj:0.20.0, net/i2p/crypto/eddsa:0.1.0, bcpkix-jdk15on:1.51, org/bouncycastle/bcprov-ext-jdk15on:1.5) * includes two brooklyn libraries which were previously excluded; they are mostly superfluous but perhaps handy as bundles that could be installed (rest-client, camp-server) * includes maven-metadata-local.xml in the brooklyn bundles in the system/ repository * redeclares upstream features in brooklyn-dist-features-1.1.0-SNAPSHOT-features.xml There is no apparent difference in operation and no difference to the started bundles (`bundle:list -s -t 0` after starting the server produces identical output). --- karaf/apache-brooklyn/pom.xml | 73 ++++---------------- karaf/features/pom.xml | 79 +++++++++++++++------- .../resources}/bin/generate-password.sh | 0 .../resources}/etc/branding.properties | 0 .../filtered-resources/resources}/etc/brooklyn.cfg | 0 .../resources}/etc/org.apache.karaf.features.xml | 0 .../src/main/resources}/resources/LICENSE | 0 .../src/main/resources}/resources/NOTICE | 0 .../src/main/resources}/resources/bin/runbrooklyn | 0 .../src/main/resources}/resources/bin/setenv | 0 .../src/main/resources}/resources/bin/setenv.bat | 0 .../resources}/resources/etc/custom.properties | 0 .../resources}/resources/etc/default.catalog.bom | 0 .../resources/etc/org.apache.karaf.shell.cfg | 0 .../resources/etc/org.ops4j.pax.logging.cfg | 0 .../etc/org.ops4j.pax.url.mvn.repositories.cfg | 0 .../resources}/resources/etc/org.ops4j.pax.web.cfg | 0 .../resources}/resources/etc/system.properties | 0 18 files changed, 68 insertions(+), 84 deletions(-) diff --git a/karaf/apache-brooklyn/pom.xml b/karaf/apache-brooklyn/pom.xml index 8a70ad7..1a35426 100755 --- a/karaf/apache-brooklyn/pom.xml +++ b/karaf/apache-brooklyn/pom.xml @@ -34,6 +34,7 @@ </parent> <dependencies> + <dependency> <groupId>org.apache.karaf.features</groupId> <artifactId>framework</artifactId> @@ -42,14 +43,6 @@ </dependency> <dependency> - <groupId>org.apache.karaf.features</groupId> - <artifactId>standard</artifactId> - <classifier>features</classifier> - <version>${karaf.version}</version> - <type>xml</type> - </dependency> - - <dependency> <groupId>org.apache.brooklyn</groupId> <artifactId>brooklyn-features</artifactId> <version>${project.version}</version> @@ -84,27 +77,17 @@ <type>xml</type> <classifier>features</classifier> </dependency> + <dependency> + <groupId>org.apache.brooklyn</groupId> + <artifactId>brooklyn-dist-features</artifactId> + <version>${project.version}</version> + <type>kar</type> + <scope>runtime</scope> + </dependency> </dependencies> <build> - <resources> - <resource> - <directory>src/main/resources</directory> - <filtering>false</filtering> - <includes> - <include>**/*</include> - </includes> - </resource> - <resource> - <directory>src/main/filtered-resources</directory> - <filtering>true</filtering> - <includes> - <include>**/*</include> - </includes> - </resource> - </resources> - <plugins> <plugin> <groupId>org.apache.rat</groupId> @@ -115,12 +98,14 @@ </excludes> </configuration> </plugin> + <plugin> <groupId>org.apache.karaf.tooling</groupId> <artifactId>karaf-maven-plugin</artifactId> <version>${karaf.plugin.version}</version> <extensions>true</extensions> <configuration> + <framework>framework</framework> <installedFeatures> <feature>wrapper</feature> <!-- https://karaf.apache.org/manual/latest/wrapper --> </installedFeatures> @@ -132,8 +117,10 @@ <!-- Goes into org.apache.karaf.features.cfg. Can use brackets to guide loading order (same as prerequisite). --> <bootFeature>brooklyn-boot</bootFeature> </bootFeatures> + <installAllFeaturesByDefault>false</installAllFeaturesByDefault> </configuration> </plugin> + <!-- Exclude META-INF from dist; Disables https://github.com/apache/maven-pom/blob/43dd8d34421ae2dfda40b1adde404b52f3800735/asf/pom.xml#L285-L301 --> <plugin> <artifactId>maven-remote-resources-plugin</artifactId> @@ -141,41 +128,7 @@ <skip>true</skip> </configuration> </plugin> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>unpack</id> - <phase>process-resources</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>brooklyn-dist-config</artifactId> - <version>${project.version}</version> - <classifier>classrename</classifier> - <type>cfg</type> - <outputDirectory>${project.build.directory}/assembly/etc</outputDirectory> - <destFileName>${project.groupId}.classrename.cfg</destFileName> - </artifactItem> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>brooklyn-dist-config</artifactId> - <version>${project.version}</version> - <classifier>osgilauncher</classifier> - <type>cfg</type> - <outputDirectory>${project.build.directory}/assembly/etc</outputDirectory> - <destFileName>${project.groupId}.osgilauncher.cfg</destFileName> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> - </plugin> + </plugins> </build> diff --git a/karaf/features/pom.xml b/karaf/features/pom.xml index 269c425..8224e1c 100644 --- a/karaf/features/pom.xml +++ b/karaf/features/pom.xml @@ -31,7 +31,7 @@ <artifactId>brooklyn-dist-features</artifactId> <name>Brooklyn Dist Karaf Features</name> <description>Defines Karaf features for Karaf runtime</description> - <packaging>feature</packaging> + <packaging>kar</packaging> <dependencies> <dependency> @@ -55,33 +55,27 @@ <classifier>features</classifier> <type>xml</type> </dependency> - - <dependency> - <groupId>org.apache.karaf.features</groupId> - <artifactId>standard</artifactId> - <classifier>features</classifier> - <version>${karaf.version}</version> - <type>xml</type> - <scope>runtime</scope> - </dependency> - <dependency> - <groupId>org.apache.karaf.features</groupId> - <artifactId>enterprise</artifactId> - <classifier>features</classifier> - <version>${karaf.version}</version> - <type>xml</type> - <scope>runtime</scope> - <exclusions> - <exclusion> - <groupId>org.hibernate</groupId> - <artifactId>hibernate-osgi</artifactId> - </exclusion> - </exclusions> - </dependency> </dependencies> <build> + <resources> + <resource> + <directory>src/main/resources</directory> + <filtering>false</filtering> + <includes> + <include>**/*</include> + </includes> + </resource> + <resource> + <directory>src/main/filtered-resources</directory> + <filtering>true</filtering> + <includes> + <include>**/*</include> + </includes> + </resource> + </resources> + <pluginManagement> <plugins> <plugin> @@ -103,6 +97,43 @@ <resolver>(obr)</resolver> </configuration> </plugin> + + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>unpack</id> + <phase>process-resources</phase> + <goals> + <goal>copy</goal> + </goals> + <configuration> + <artifactItems> + <artifactItem> + <groupId>${project.groupId}</groupId> + <artifactId>brooklyn-dist-config</artifactId> + <version>${project.version}</version> + <classifier>classrename</classifier> + <type>cfg</type> + <outputDirectory>${project.build.directory}/classes/resources/etc</outputDirectory> + <destFileName>${project.groupId}.classrename.cfg</destFileName> + </artifactItem> + <artifactItem> + <groupId>${project.groupId}</groupId> + <artifactId>brooklyn-dist-config</artifactId> + <version>${project.version}</version> + <classifier>osgilauncher</classifier> + <type>cfg</type> + <outputDirectory>${project.build.directory}/classes/resources/etc</outputDirectory> + <destFileName>${project.groupId}.osgilauncher.cfg</destFileName> + </artifactItem> + </artifactItems> + </configuration> + </execution> + </executions> + </plugin> + </plugins> </build> diff --git a/karaf/apache-brooklyn/src/main/filtered-resources/bin/generate-password.sh b/karaf/features/src/main/filtered-resources/resources/bin/generate-password.sh similarity index 100% rename from karaf/apache-brooklyn/src/main/filtered-resources/bin/generate-password.sh rename to karaf/features/src/main/filtered-resources/resources/bin/generate-password.sh diff --git a/karaf/apache-brooklyn/src/main/filtered-resources/etc/branding.properties b/karaf/features/src/main/filtered-resources/resources/etc/branding.properties similarity index 100% rename from karaf/apache-brooklyn/src/main/filtered-resources/etc/branding.properties rename to karaf/features/src/main/filtered-resources/resources/etc/branding.properties diff --git a/karaf/apache-brooklyn/src/main/filtered-resources/etc/brooklyn.cfg b/karaf/features/src/main/filtered-resources/resources/etc/brooklyn.cfg similarity index 100% rename from karaf/apache-brooklyn/src/main/filtered-resources/etc/brooklyn.cfg rename to karaf/features/src/main/filtered-resources/resources/etc/brooklyn.cfg diff --git a/karaf/apache-brooklyn/src/main/filtered-resources/etc/org.apache.karaf.features.xml b/karaf/features/src/main/filtered-resources/resources/etc/org.apache.karaf.features.xml similarity index 100% rename from karaf/apache-brooklyn/src/main/filtered-resources/etc/org.apache.karaf.features.xml rename to karaf/features/src/main/filtered-resources/resources/etc/org.apache.karaf.features.xml diff --git a/karaf/apache-brooklyn/src/main/resources/LICENSE b/karaf/features/src/main/resources/resources/LICENSE similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/LICENSE rename to karaf/features/src/main/resources/resources/LICENSE diff --git a/karaf/apache-brooklyn/src/main/resources/NOTICE b/karaf/features/src/main/resources/resources/NOTICE similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/NOTICE rename to karaf/features/src/main/resources/resources/NOTICE diff --git a/karaf/apache-brooklyn/src/main/resources/bin/runbrooklyn b/karaf/features/src/main/resources/resources/bin/runbrooklyn similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/bin/runbrooklyn rename to karaf/features/src/main/resources/resources/bin/runbrooklyn diff --git a/karaf/apache-brooklyn/src/main/resources/bin/setenv b/karaf/features/src/main/resources/resources/bin/setenv similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/bin/setenv rename to karaf/features/src/main/resources/resources/bin/setenv diff --git a/karaf/apache-brooklyn/src/main/resources/bin/setenv.bat b/karaf/features/src/main/resources/resources/bin/setenv.bat similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/bin/setenv.bat rename to karaf/features/src/main/resources/resources/bin/setenv.bat diff --git a/karaf/apache-brooklyn/src/main/resources/etc/custom.properties b/karaf/features/src/main/resources/resources/etc/custom.properties similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/custom.properties rename to karaf/features/src/main/resources/resources/etc/custom.properties diff --git a/karaf/apache-brooklyn/src/main/resources/etc/default.catalog.bom b/karaf/features/src/main/resources/resources/etc/default.catalog.bom similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/default.catalog.bom rename to karaf/features/src/main/resources/resources/etc/default.catalog.bom diff --git a/karaf/apache-brooklyn/src/main/resources/etc/org.apache.karaf.shell.cfg b/karaf/features/src/main/resources/resources/etc/org.apache.karaf.shell.cfg similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/org.apache.karaf.shell.cfg rename to karaf/features/src/main/resources/resources/etc/org.apache.karaf.shell.cfg diff --git a/karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.logging.cfg b/karaf/features/src/main/resources/resources/etc/org.ops4j.pax.logging.cfg similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.logging.cfg rename to karaf/features/src/main/resources/resources/etc/org.ops4j.pax.logging.cfg diff --git a/karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.url.mvn.repositories.cfg b/karaf/features/src/main/resources/resources/etc/org.ops4j.pax.url.mvn.repositories.cfg similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.url.mvn.repositories.cfg rename to karaf/features/src/main/resources/resources/etc/org.ops4j.pax.url.mvn.repositories.cfg diff --git a/karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.web.cfg b/karaf/features/src/main/resources/resources/etc/org.ops4j.pax.web.cfg similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/org.ops4j.pax.web.cfg rename to karaf/features/src/main/resources/resources/etc/org.ops4j.pax.web.cfg diff --git a/karaf/apache-brooklyn/src/main/resources/etc/system.properties b/karaf/features/src/main/resources/resources/etc/system.properties similarity index 100% rename from karaf/apache-brooklyn/src/main/resources/etc/system.properties rename to karaf/features/src/main/resources/resources/etc/system.properties
