activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbert...@apache.org
Subject [activemq-artemis] 01/05: ARTEMIS-3328: fix assembly descriptors and stop downgrading assembly plugin
Date Fri, 04 Jun 2021 18:56:36 GMT
This is an automated email from the ASF dual-hosted git repository.

jbertram pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git

commit 5bf32282591c0e12d9fdbc5b87284cd4dd03675a
Author: Robbie Gemmell <robbie@apache.org>
AuthorDate: Thu Jun 3 11:40:57 2021 +0100

    ARTEMIS-3328: fix assembly descriptors and stop downgrading assembly plugin
    
    - Remove assembly plugin downgrade from 7733a76649403193e0e0e7e1a6279095fdbf426c in ARTEMIS-3296.
    - Ensure bin descriptor marks key artemis setup/startup script executable file permissions,
it wasnt
      before as while aiming to it only defined inclusions for old files that no longer exist.
    - Add mode fields to every area to make clear what they will be using, make formats consistent
with doc.
    - Update source release assembly to similarly mark key scripts with executable file permissions.
---
 artemis-distribution/src/main/assembly/dep.xml     | 62 +++++++++++++++++-----
 .../src/main/assembly/source-assembly.xml          | 27 +++++++++-
 pom.xml                                            |  9 ----
 3 files changed, 73 insertions(+), 25 deletions(-)

diff --git a/artemis-distribution/src/main/assembly/dep.xml b/artemis-distribution/src/main/assembly/dep.xml
index 0b24360..018266d 100644
--- a/artemis-distribution/src/main/assembly/dep.xml
+++ b/artemis-distribution/src/main/assembly/dep.xml
@@ -21,8 +21,8 @@
 
    <dependencySets>
       <dependencySet>
-        <directoryMode>755</directoryMode>
-        <fileMode>644</fileMode>
+        <directoryMode>0755</directoryMode>
+        <fileMode>0644</fileMode>
         <outputDirectory>lib</outputDirectory>
         <outputFileNameMapping>${artifact.artifactId}.${artifact.extension}</outputFileNameMapping>
         <unpack>false</unpack>
@@ -34,8 +34,8 @@
       </dependencySet>
 
       <dependencySet>
-         <directoryMode>755</directoryMode>
-         <fileMode>644</fileMode>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
          <includes>
 
             <!-- modules -->
@@ -106,8 +106,8 @@
          <useProjectArtifact>false</useProjectArtifact>
       </dependencySet>
       <dependencySet>
-         <directoryMode>755</directoryMode>
-         <fileMode>644</fileMode>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
          <includes>
             <include>org.apache.activemq:artemis-jms-client-all</include>
          </includes>
@@ -128,6 +128,8 @@
             </includes>
          </unpackOptions>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       <dependencySet>
          <includes>
@@ -139,6 +141,8 @@
          <outputDirectory>web</outputDirectory>
          <unpack>true</unpack>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       <dependencySet>
          <includes>
@@ -147,6 +151,8 @@
          <outputDirectory>web/api</outputDirectory>
          <unpack>true</unpack>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       
       <!-- Management Console Dependencies -->
@@ -158,6 +164,8 @@
          <unpack>false</unpack>
          <outputFileNameMapping>console.war</outputFileNameMapping>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       <dependencySet>
          <includes>
@@ -167,6 +175,8 @@
          <unpack>false</unpack>
          <outputFileNameMapping>activemq-branding.war</outputFileNameMapping>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       <dependencySet>
          <includes>
@@ -176,6 +186,8 @@
          <unpack>false</unpack>
          <outputFileNameMapping>artemis-plugin.war</outputFileNameMapping>
          <useProjectArtifact>false</useProjectArtifact>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </dependencySet>
       
    </dependencySets>
@@ -185,16 +197,22 @@
          <directory>${activemq.basedir}/artemis-server/src/main/resources/schema/</directory>
          <outputDirectory>schema</outputDirectory>
          <lineEnding>keep</lineEnding>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
       <fileSet>
          <directory>${activemq.basedir}/artemis-jms-server/src/main/resources/schema/</directory>
          <outputDirectory>schema</outputDirectory>
          <lineEnding>keep</lineEnding>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
       <fileSet>
          <directory>${activemq.basedir}/artemis-dto/target/schema/org.apache.activemq/dto/</directory>
          <outputDirectory>schema</outputDirectory>
          <lineEnding>keep</lineEnding>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
       <!-- resources -->
       <fileSet>
@@ -202,25 +220,21 @@
          <outputDirectory>${file.separator}</outputDirectory>
          <lineEnding>keep</lineEnding>
          <excludes>
-            <exclude>bin/activemq</exclude>
-            <exclude>bin/run.sh</exclude>
-            <exclude>bin/stop.sh</exclude>
+            <exclude>bin/artemis</exclude>
             <exclude>**/target/**</exclude>
             <exclude>**/**/*.iml</exclude>
             <exclude>**/**/*.dat</exclude>
             <exclude>**/licenses/**</exclude>
-            <exclude>docker/**</exclude>
          </excludes>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
-      <!-- chmod to 755 on linux executables -->
       <fileSet>
          <directory>src/main/resources</directory>
          <outputDirectory>${file.separator}</outputDirectory>
          <lineEnding>keep</lineEnding>
          <includes>
-            <include>bin/activemq</include>
-            <include>bin/run.sh</include>
-            <include>bin/stop.sh</include>
+            <include>bin/artemis</include>
          </includes>
          <directoryMode>0755</directoryMode>
          <fileMode>0755</fileMode>
@@ -235,18 +249,38 @@
             <exclude>**/**/*.iml</exclude>
             <exclude>**/**/*.dat</exclude>
             <exclude>**/**/*.md</exclude>
+            <exclude>**/**/*.sh</exclude>
          </excludes>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
+      </fileSet>
+      <fileSet>
+         <directory>${activemq.basedir}/examples</directory>
+         <outputDirectory>examples</outputDirectory>
+         <lineEnding>keep</lineEnding>
+         <includes>
+            <include>**/**/*.sh</include>
+         </includes>
+         <excludes>
+            <exclude>**/target/**</exclude>
+         </excludes>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0755</fileMode>
       </fileSet>
       <fileSet>
          <directory>${project.build.directory}/markdown-pages/examples</directory>
          <outputDirectory>examples</outputDirectory>
          <lineEnding>keep</lineEnding>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
       <!-- Include license and notice files -->
       <fileSet>
          <directory>${activemq.basedir}/artemis-distribution/src/main/resources/licenses/bin</directory>
          <outputDirectory>${file.separator}</outputDirectory>
          <useDefaultExcludes>true</useDefaultExcludes>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
       </fileSet>
    </fileSets>
 </component>
diff --git a/artemis-distribution/src/main/assembly/source-assembly.xml b/artemis-distribution/src/main/assembly/source-assembly.xml
index c0e151f..46805d4 100644
--- a/artemis-distribution/src/main/assembly/source-assembly.xml
+++ b/artemis-distribution/src/main/assembly/source-assembly.xml
@@ -34,12 +34,18 @@
          <directory>${activemq.basedir}</directory>
          <outputDirectory>${file.separator}</outputDirectory>
          <useDefaultExcludes>true</useDefaultExcludes>
-         <!-- TODO These excludes were lifted from maven-resources-apache-source-release-assembly-descriptor-1.0.4.
We
-         should use this descriptor directly in future -->
+         <directoryMode>0755</directoryMode>
+         <fileMode>0644</fileMode>
          <excludes>
             <exclude>tests/extra-tests/</exclude>
             <exclude>tests/performance-jmh/</exclude>
 
+            <exclude>artemis-distribution/src/main/resources/bin/artemis</exclude>
+            <exclude>artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis</exclude>
+            <exclude>artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis-service</exclude>
+            <exclude>scripts/*.sh</exclude>
+            <exclude>**/**/*.sh</exclude>
+
             <!-- in case some of the build generates data, this needs to be ignored -->
             <exclude>data/</exclude>
 
@@ -130,5 +136,22 @@
 
          </excludes>
       </fileSet>
+      <fileSet>
+         <directory>${activemq.basedir}</directory>
+         <outputDirectory>${file.separator}</outputDirectory>
+         <useDefaultExcludes>true</useDefaultExcludes>
+         <directoryMode>0755</directoryMode>
+         <fileMode>0755</fileMode>
+         <includes>
+            <include>artemis-distribution/src/main/resources/bin/artemis</include>
+            <include>artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis</include>
+            <include>artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis-service</include>
+            <include>scripts/*.sh</include>
+            <include>**/**/*.sh</include>
+         </includes>
+         <excludes>
+            <exclude>**/target/**</exclude>
+         </excludes>
+      </fileSet>
    </fileSets>
 </assembly>
diff --git a/pom.xml b/pom.xml
index 5bd914a..a48af17 100644
--- a/pom.xml
+++ b/pom.xml
@@ -97,10 +97,6 @@
       <jetty.version>9.4.40.v20210413</jetty.version>
       <jgroups.version>3.6.13.Final</jgroups.version>
       <errorprone.version>2.6.0</errorprone.version>
-      <!-- Overrides the parent pom to downgrade to assembly plugin to < 3.2.0, and
-        keep the old file permission copying behaviour until such time as the assembly
-        descriptor properly defines them. See also MASSEMBLY-941. -->
-      <maven.assembly.plugin.version>3.1.1</maven.assembly.plugin.version>
       <maven.enforcer.plugin.version>3.0.0-M3</maven.enforcer.plugin.version>
       <maven.bundle.plugin.version>5.1.2</maven.bundle.plugin.version>
       <mockito.version>3.9.0</mockito.version>
@@ -1484,11 +1480,6 @@
             </plugin>
             <plugin>
                <groupId>org.apache.maven.plugins</groupId>
-               <artifactId>maven-assembly-plugin</artifactId>
-               <version>${maven.assembly.plugin.version}</version>
-            </plugin>
-            <plugin>
-               <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-rar-plugin</artifactId>
                <version>2.3</version>
             </plugin>

Mime
View raw message