You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2021/08/24 16:02:36 UTC

[activemq-artemis] branch main updated (e2c1efb -> 20e66a2)

This is an automated email from the ASF dual-hosted git repository.

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


    from e2c1efb  NO-JIRA: fix profiles for run of examples module on JDK11+ on Travis, fix unintended build output caching, and cleanup existing cache
     new 5a1449d  ARTEMIS-3440: separate effect of -Pdev from test profiles, make them independent
     new 20e66a2  NO-JIRA: split various checks out to their own sub jobs on GHA

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .github/workflows/build.yml |  49 ++++++--
 .travis.yml                 |   2 +-
 pom.xml                     | 281 +++++++++++++++++++++++---------------------
 3 files changed, 193 insertions(+), 139 deletions(-)

[activemq-artemis] 01/02: ARTEMIS-3440: separate effect of -Pdev from test profiles, make them independent

Posted by cl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 5a1449d8127a11fb891819981739b04001d1d45b
Author: Robbie Gemmell <ro...@apache.org>
AuthorDate: Tue Aug 24 15:10:17 2021 +0100

    ARTEMIS-3440: separate effect of -Pdev from test profiles, make them independent
    
    use pluginManagement config + executions to enable the RAT and Checkstyle checks rather than properties
---
 .github/workflows/build.yml |   2 +-
 .travis.yml                 |   2 +-
 pom.xml                     | 281 +++++++++++++++++++++++---------------------
 3 files changed, 152 insertions(+), 133 deletions(-)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index cd24916..faefcb2 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -32,7 +32,7 @@ jobs:
       # By setting anything to org.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED we are disabling libaio loading on the testsuite
       - name: Build Main
         run: |
-          mvn -s .github/maven-settings.xml -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Derrorprone -Pfast-tests -Pextra-tests -Ptests-CI -Pjmh install
+          mvn -s .github/maven-settings.xml -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Derrorprone -Pdev -Pfast-tests -Pextra-tests -Ptests-CI -Pjmh install
 
       - name: Build Examples (JDK8 / -Prelease)
         if: matrix.java == '8'
diff --git a/.travis.yml b/.travis.yml
index cd51c08..d45c658 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -24,7 +24,7 @@ before_install:
 # By setting anything to org.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED we are disabling libaio loading on the testsuite
 script: 
 - set -e
-- mvn -s .github/maven-settings.xml -ntp -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Dmaven.test.redirectTestOutputToFile=true -Derrorprone -Pfast-tests -Pextra-tests -Ptests-CI -Pjmh -B install
+- mvn -s .github/maven-settings.xml -ntp -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Dmaven.test.redirectTestOutputToFile=true -Derrorprone -Pdev -Pfast-tests -Pextra-tests -Ptests-CI -Pjmh -B install
 - cd examples
 - mvn -s ../.github/maven-settings.xml verify -P${EXAMPLES_PROFILE} -B -q
 
diff --git a/pom.xml b/pom.xml
index 0438ff0..411747a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -208,8 +208,6 @@
          -Djava.net.preferIPv4Stack=true -Dbasedir=${basedir}
       </activemq-surefire-argline>
       <activemq.basedir>${project.basedir}</activemq.basedir>
-      <skipLicenseCheck>true</skipLicenseCheck>
-      <skipStyleCheck>true</skipStyleCheck>
       <skipOWASP>true</skipOWASP>
 
       <directory-version>2.0.0.AM25</directory-version>
@@ -1044,20 +1042,40 @@
       </profile>
       <profile>
          <id>dev</id>
-         <properties>
-            <skipStyleCheck>false</skipStyleCheck>
-            <skipLicenseCheck>false</skipLicenseCheck>
-         </properties>
+         <build>
+            <plugins>
+               <plugin>
+                  <groupId>org.apache.rat</groupId>
+                  <artifactId>apache-rat-plugin</artifactId>
+                  <executions>
+                     <execution>
+                        <phase>compile</phase>
+                        <goals>
+                           <goal>check</goal>
+                        </goals>
+                     </execution>
+                  </executions>
+               </plugin>
+               <plugin>
+                  <groupId>org.apache.maven.plugins</groupId>
+                  <artifactId>maven-checkstyle-plugin</artifactId>
+                  <executions>
+                     <execution>
+                        <phase>compile</phase>
+                        <goals>
+                           <goal>check</goal>
+                        </goals>
+                     </execution>
+                  </executions>
+               </plugin>
+            </plugins>
+         </build>
       </profile>
       <profile>
          <id>release</id>
          <modules>
             <module>examples</module>
          </modules>
-         <properties>
-            <skipStyleCheck>false</skipStyleCheck>
-            <skipLicenseCheck>false</skipLicenseCheck>
-         </properties>
          <build>
             <plugins>
                <plugin>
@@ -1080,6 +1098,30 @@
                      </execution>
                   </executions>
                </plugin>
+               <plugin>
+                  <groupId>org.apache.rat</groupId>
+                  <artifactId>apache-rat-plugin</artifactId>
+                  <executions>
+                     <execution>
+                        <phase>compile</phase>
+                        <goals>
+                           <goal>check</goal>
+                        </goals>
+                     </execution>
+                  </executions>
+               </plugin>
+               <plugin>
+                  <groupId>org.apache.maven.plugins</groupId>
+                  <artifactId>maven-checkstyle-plugin</artifactId>
+                  <executions>
+                     <execution>
+                        <phase>compile</phase>
+                        <goals>
+                           <goal>check</goal>
+                        </goals>
+                     </execution>
+                  </executions>
+               </plugin>
             </plugins>
          </build>
       </profile>
@@ -1136,8 +1178,6 @@
             <skipSoakTests>true</skipSoakTests>
             <skipPerformanceTests>true</skipPerformanceTests>
             <skipExtraTests>false</skipExtraTests>
-            <skipStyleCheck>false</skipStyleCheck>
-            <skipLicenseCheck>false</skipLicenseCheck>
          </properties>
       </profile>
       <profile>
@@ -1149,8 +1189,6 @@
             <skipJmsTests>false</skipJmsTests>
             <skipJoramTests>false</skipJoramTests>
             <skipConcurrentTests>false</skipConcurrentTests>
-            <skipStyleCheck>false</skipStyleCheck>
-            <skipLicenseCheck>false</skipLicenseCheck>
             <skipCompatibilityTests>false</skipCompatibilityTests>
             <testFailureIgnore>false</testFailureIgnore>
             <!-- This enables the karaf-client-integration-tests and
@@ -1513,6 +1551,104 @@
                <artifactId>maven-war-plugin</artifactId>
                <version>3.3.1</version>
             </plugin>
+            <plugin>
+               <groupId>org.apache.maven.plugins</groupId>
+               <artifactId>maven-checkstyle-plugin</artifactId>
+               <version>${maven.checkstyle.plugin.version}</version>
+               <dependencies>
+                  <dependency>
+                     <groupId>com.github.sevntu-checkstyle</groupId>
+                     <artifactId>sevntu-checks</artifactId>
+                     <version>${sevntu.checks.version}</version>
+                  </dependency>
+                  <dependency>
+                     <groupId>com.puppycrawl.tools</groupId>
+                     <artifactId>checkstyle</artifactId>
+                     <version>${checkstyle.version}</version>
+                  </dependency>
+               </dependencies>
+               <configuration>
+                  <configLocation>${activemq.basedir}/etc/checkstyle.xml</configLocation>
+                  <suppressionsLocation>${activemq.basedir}/etc/checkstyle-suppressions.xml</suppressionsLocation>
+                  <failsOnError>false</failsOnError>
+                  <failOnViolation>true</failOnViolation>
+                  <consoleOutput>true</consoleOutput>
+                  <includeTestSourceDirectory>true</includeTestSourceDirectory>
+               </configuration>
+            </plugin>
+            <plugin>
+               <groupId>org.apache.rat</groupId>
+               <artifactId>apache-rat-plugin</artifactId>
+               <configuration>
+                  <reportFile>${activemq.basedir}/ratReport.txt</reportFile>
+                  <excludes>
+                     <exclude>**/src/main/webapp/hawtconfig.json</exclude>
+                     <exclude>.repository/**</exclude>
+                     <exclude>.travis.yml</exclude>
+                     <exclude>.github/workflows/*</exclude>
+                     <exclude>**/footer.html</exclude>
+                     <exclude>**/*.txt</exclude>
+                     <exclude>**/*.md</exclude>
+                     <exclude>etc/ide-settings/**</exclude>
+                     <exclude>**/*.json</exclude>
+                     <exclude>docs/**/*.json</exclude>
+                     <exclude>docs/**/_book/</exclude>
+                     <exclude>docs/**/_layouts/</exclude>
+                     <exclude>**/target/</exclude>
+                     <exclude>**/META-INF/services/*</exclude>
+                     <exclude>**/META-INF/MANIFEST.MF</exclude>
+                     <exclude>**/*.iml</exclude>
+                     <exclude>**/*.jceks</exclude>
+                     <exclude>**/*.jks</exclude>
+                     <exclude>**/*.p12</exclude>
+                     <exclude>**/xml.xsd</exclude>
+                     <exclude>**/org/apache/activemq/artemis/utils/json/**</exclude>
+                     <exclude>**/org/apache/activemq/artemis/utils/Base64.java</exclude>
+                     <exclude>**/.settings/**</exclude>
+                     <exclude>**/.project</exclude>
+                     <exclude>**/.classpath</exclude>
+                     <exclude>**/.editorconfig</exclude>
+                     <exclude>**/.checkstyle</exclude>
+                     <exclude>**/.factorypath</exclude>
+                     <exclude>**/org.apache.activemq.artemis.cfg</exclude>
+                     <exclude>**/nb-configuration.xml</exclude>
+                     <exclude>**/nbactions-tests.xml</exclude>
+                     <exclude>**/.vscode/settings.json</exclude>
+                     <!-- activemq5 unit tests exclude -->
+                     <exclude>**/*.data</exclude>
+                     <exclude>**/*.bin</exclude>
+                     <exclude>**/src/test/resources/keystore</exclude>
+                     <exclude>**/src/test/java/org/apache/activemq/security/*.ts</exclude>
+                     <exclude>**/*.log</exclude>
+                     <exclude>**/*.redo</exclude>
+
+                      <!-- NPM files -->
+                     <exclude>**/node/**</exclude>
+                     <exclude>**/node_modules/**</exclude>
+                     <exclude>**/package.json</exclude>
+                     <exclude>**/npm-shrinkwrap.json</exclude>
+
+                     <!-- Build time overlay folder -->
+                     <exclude>**/overlays/**</exclude>
+
+                     <!-- things from cmake on the native build -->
+                     <exclude>**/CMakeFiles/</exclude>
+                     <exclude>**/Makefile</exclude>
+                     <exclude>**/cmake_install.cmake</exclude>
+                     <exclude>activemq-artemis-native/src/main/c/org_apache_activemq_artemis_jlibaio_LibaioContext.h</exclude>
+                     <exclude>**/dependency-reduced-pom.xml</exclude>
+
+                     <!-- Mockito -->
+                     <exclude>**/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker</exclude>
+
+                     <!-- .NET Examples-->
+                     <exclude>examples/protocols/amqp/dotnet/**/obj/**/*</exclude>
+                     <exclude>examples/protocols/amqp/dotnet/**/bin/**/*</exclude>
+                     <exclude>examples/protocols/amqp/dotnet/**/readme.md</exclude>
+                     <exclude>examples/protocols/amqp/**/readme.md</exclude>
+                  </excludes>
+               </configuration>
+            </plugin>
          </plugins>
       </pluginManagement>
 
@@ -1571,41 +1707,6 @@
             <version>2.2</version>
          </plugin>
          <plugin>
-            <groupId>org.apache.maven.plugins</groupId>
-            <artifactId>maven-checkstyle-plugin</artifactId>
-            <version>${maven.checkstyle.plugin.version}</version>
-            <dependencies>
-               <dependency>
-                  <groupId>com.github.sevntu-checkstyle</groupId>
-                  <artifactId>sevntu-checks</artifactId>
-                  <version>${sevntu.checks.version}</version>
-               </dependency>
-               <dependency>
-                  <groupId>com.puppycrawl.tools</groupId>
-                  <artifactId>checkstyle</artifactId>
-                  <version>${checkstyle.version}</version>
-               </dependency>
-            </dependencies>
-            <configuration>
-               <skip>${skipStyleCheck}</skip>
-               <configLocation>${activemq.basedir}/etc/checkstyle.xml</configLocation>
-               <suppressionsLocation>${activemq.basedir}/etc/checkstyle-suppressions.xml</suppressionsLocation>
-               <failsOnError>false</failsOnError>
-               <failOnViolation>true</failOnViolation>
-               <consoleOutput>true</consoleOutput>
-               <includeTestSourceDirectory>true</includeTestSourceDirectory>
-            </configuration>
-            <executions>
-               <execution>
-                  <phase>compile</phase>
-                  <goals>
-                     <goal>check</goal>
-                  </goals>
-               </execution>
-            </executions>
-         </plugin>
-
-         <plugin>
             <groupId>org.codehaus.mojo</groupId>
             <artifactId>findbugs-maven-plugin</artifactId>
             <version>2.5.2</version>
@@ -1618,88 +1719,6 @@
             </configuration>
          </plugin>
          <plugin>
-            <groupId>org.apache.rat</groupId>
-            <artifactId>apache-rat-plugin</artifactId>
-            <configuration>
-               <reportFile>${activemq.basedir}/ratReport.txt</reportFile>
-               <skip>${skipLicenseCheck}</skip>
-               <excludes>
-                  <exclude>**/src/main/webapp/hawtconfig.json</exclude>
-                  <exclude>.repository/**</exclude>
-                  <exclude>.travis.yml</exclude>
-                  <exclude>.github/workflows/*</exclude>
-                  <exclude>**/footer.html</exclude>
-                  <exclude>**/*.txt</exclude>
-                  <exclude>**/*.md</exclude>
-                  <exclude>etc/ide-settings/**</exclude>
-                  <exclude>**/*.json</exclude>
-                  <exclude>docs/**/*.json</exclude>
-                  <exclude>docs/**/_book/</exclude>
-                  <exclude>docs/**/_layouts/</exclude>
-                  <exclude>**/target/</exclude>
-                  <exclude>**/META-INF/services/*</exclude>
-                  <exclude>**/META-INF/MANIFEST.MF</exclude>
-                  <exclude>**/*.iml</exclude>
-                  <exclude>**/*.jceks</exclude>
-                  <exclude>**/*.jks</exclude>
-                  <exclude>**/*.p12</exclude>
-                  <exclude>**/xml.xsd</exclude>
-                  <exclude>**/org/apache/activemq/artemis/utils/json/**</exclude>
-                  <exclude>**/org/apache/activemq/artemis/utils/Base64.java</exclude>
-                  <exclude>**/.settings/**</exclude>
-                  <exclude>**/.project</exclude>
-                  <exclude>**/.classpath</exclude>
-                  <exclude>**/.editorconfig</exclude>
-                  <exclude>**/.checkstyle</exclude>
-                  <exclude>**/.factorypath</exclude>
-                  <exclude>**/org.apache.activemq.artemis.cfg</exclude>
-                  <exclude>**/nb-configuration.xml</exclude>
-                  <exclude>**/nbactions-tests.xml</exclude>
-                  <exclude>**/.vscode/settings.json</exclude>
-                  <!-- activemq5 unit tests exclude -->
-                  <exclude>**/*.data</exclude>
-                  <exclude>**/*.bin</exclude>
-                  <exclude>**/src/test/resources/keystore</exclude>
-                  <exclude>**/src/test/java/org/apache/activemq/security/*.ts</exclude>
-                  <exclude>**/*.log</exclude>
-                  <exclude>**/*.redo</exclude>
-
-                  <!-- NPM files -->
-                  <exclude>**/node/**</exclude>
-                  <exclude>**/node_modules/**</exclude>
-                  <exclude>**/package.json</exclude>
-                  <exclude>**/npm-shrinkwrap.json</exclude>
-
-                  <!-- Build time overlay folder -->
-                  <exclude>**/overlays/**</exclude>
-
-                  <!-- things from cmake on the native build -->
-                  <exclude>**/CMakeFiles/</exclude>
-                  <exclude>**/Makefile</exclude>
-                  <exclude>**/cmake_install.cmake</exclude>
-                  <exclude>activemq-artemis-native/src/main/c/org_apache_activemq_artemis_jlibaio_LibaioContext.h</exclude>
-                  <exclude>**/dependency-reduced-pom.xml</exclude>
-
-                  <!-- Mockito -->
-                  <exclude>**/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker</exclude>
-
-                  <!-- .NET Examples-->
-                  <exclude>examples/protocols/amqp/dotnet/**/obj/**/*</exclude>
-                  <exclude>examples/protocols/amqp/dotnet/**/bin/**/*</exclude>
-                  <exclude>examples/protocols/amqp/dotnet/**/readme.md</exclude>
-                  <exclude>examples/protocols/amqp/**/readme.md</exclude>
-               </excludes>
-            </configuration>
-            <executions>
-               <execution>
-                  <phase>compile</phase>
-                  <goals>
-                     <goal>check</goal>
-                  </goals>
-               </execution>
-            </executions>
-         </plugin>
-         <plugin>
             <groupId>org.apache.felix</groupId>
             <artifactId>maven-bundle-plugin</artifactId>
             <version>${maven.bundle.plugin.version}</version>

[activemq-artemis] 02/02: NO-JIRA: split various checks out to their own sub jobs on GHA

Posted by cl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 20e66a2063f8724ec0dfc3b2fec8775e7622f72c
Author: Robbie Gemmell <ro...@apache.org>
AuthorDate: Tue Aug 24 15:12:10 2021 +0100

    NO-JIRA: split various checks out to their own sub jobs on GHA
    
    - Ensures tests start and complete as fast as possible, speeding things up overall.
    - Makes the checks happen earlier, and doesnt prevent the tests running if they fail, and vice versa.
    
    Also tweaks build and cache config to avoid caching unintended build output as it has been.
---
 .github/workflows/build.yml | 49 ++++++++++++++++++++++++++++++++++++++-------
 1 file changed, 42 insertions(+), 7 deletions(-)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index faefcb2..0231e0c 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -3,7 +3,8 @@ name: "Build"
 on: [push, pull_request, workflow_dispatch]
 
 jobs:
-  build:
+  test:
+    name: Test (${{ matrix.java }})
     runs-on: ubuntu-18.04
     strategy:
       fail-fast: false
@@ -17,9 +18,11 @@ jobs:
           path: |
             ~/.m2/repository
             !~/.m2/repository/org/apache/activemq/artemis-*
-          key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
+            !~/.m2/repository/org/apache/activemq/*-artemis
+            !~/.m2/repository/org/apache/activemq/examples
+          key: ${{ runner.os }}-maven-test-${{ hashFiles('**/pom.xml') }}
           restore-keys: |
-            ${{ runner.os }}-maven-
+            ${{ runner.os }}-maven-test-
 
       - name: Install JDK ${{ matrix.java }}
         uses: actions/setup-java@v2
@@ -28,23 +31,55 @@ jobs:
           distribution: 'adopt'
 
       # use 'install' so smoke-tests will work
-      # use '-Pextra-tests' to ensure extra-tests compiles even though they won't actually run
       # By setting anything to org.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED we are disabling libaio loading on the testsuite
+      - name: Fast Tests
+        run: |
+          mvn -s .github/maven-settings.xml -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Pfast-tests -Ptests-CI install
+
+
+  checks:
+    name: Checks (${{ matrix.java }})
+    runs-on: ubuntu-18.04
+    strategy:
+      fail-fast: false
+      matrix:
+        java: [ 8, 11, 16 ]
+
+    steps:
+      - uses: actions/checkout@v2
+      - uses: actions/cache@v2
+        with:
+          path: |
+            ~/.m2/repository
+            !~/.m2/repository/org/apache/activemq/artemis-*
+            !~/.m2/repository/org/apache/activemq/*-artemis
+            !~/.m2/repository/org/apache/activemq/examples
+          key: ${{ runner.os }}-maven-checks-${{ hashFiles('**/pom.xml') }}
+          restore-keys: |
+            ${{ runner.os }}-maven-checks-
+            ${{ runner.os }}-maven-test-
+
+      - name: Install JDK ${{ matrix.java }}
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }}
+          distribution: 'adopt'
+
       - name: Build Main
         run: |
-          mvn -s .github/maven-settings.xml -Dorg.apache.activemq.artemis.core.io.aio.AIOSequentialFileFactory.DISABLED=AnythingNotNull -Derrorprone -Pdev -Pfast-tests -Pextra-tests -Ptests-CI -Pjmh install
+          mvn -s .github/maven-settings.xml -DskipTests -Derrorprone -Pdev -Pextra-tests -Pjmh install
 
       - name: Build Examples (JDK8 / -Prelease)
         if: matrix.java == '8'
         run: |
           cd examples
-          mvn -s ../.github/maven-settings.xml install -Prelease
+          mvn -s ../.github/maven-settings.xml verify -Prelease
 
       - name: Build Examples (JDK 11+ / -Pexamples,noRun)
         if: matrix.java != '8'
         run: |
           cd examples
-          mvn -s ../.github/maven-settings.xml install -Pexamples,noRun
+          mvn -s ../.github/maven-settings.xml verify -Pexamples,noRun
 
       - name: Javadoc Check (JDK8 / -Prelease)
         if: matrix.java == '8'