You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mina.apache.org by tw...@apache.org on 2022/11/02 22:35:14 UTC

[mina-sshd] 02/02: [releng] Update GitHub action versions

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

twolf pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mina-sshd.git

commit a85d0743e597544cd4fe4d5e64893aa2ca71c77b
Author: Thomas Wolf <tw...@apache.org>
AuthorDate: Wed Nov 2 12:08:51 2022 +0100

    [releng] Update GitHub action versions
    
    Use @v3 versions; the old versions are no longer supported and will
    stop working in a few months.
    
    Use the Temurin JDK distro. Temurin doesn't have Java 14, and anyway
    that was an intermediary version. Use the Java 17 LTS instead.
    
    Note that [DIRSTUDIO-1277] forces us to use --add-opens for the
    LDAP tests on Java >= 16.[1]
    
    [1] https://issues.apache.org/jira/browse/DIRSTUDIO-1277
---
 .github/workflows/master-build.yml | 18 ++++++------
 sshd-ldap/pom.xml                  | 23 +++++++++++++++-
 sshd-sftp/pom.xml                  | 56 +++++++++++++++++++-------------------
 3 files changed, 60 insertions(+), 37 deletions(-)

diff --git a/.github/workflows/master-build.yml b/.github/workflows/master-build.yml
index 8f03b76d4..869714862 100644
--- a/.github/workflows/master-build.yml
+++ b/.github/workflows/master-build.yml
@@ -31,16 +31,17 @@ jobs:
     strategy:
       matrix:
         os: [ ubuntu-latest, windows-latest ]
-        java: [ '1.8' ]
+        java: [ '8' ]
     steps:
-      - uses: actions/checkout@v2
+      - uses: actions/checkout@v3
 
       - name: Set up JDK ${{ matrix.java }}
-        uses: actions/setup-java@v1
+        uses: actions/setup-java@v3
         with:
+          distribution: temurin
           java-version: ${{ matrix.java }}
 
-      - uses: actions/cache@v1
+      - uses: actions/cache@v3
         with:
           path: ~/.m2/repository
           key: ${{ matrix.os }}-maven-${{ hashFiles('**/pom.xml') }}
@@ -56,16 +57,17 @@ jobs:
     strategy:
       matrix:
         os: [ ubuntu-latest, windows-latest ]
-        java: [ '1.8', '11', '14' ]
+        java: [ '8', '11', '17' ]
     steps:
-      - uses: actions/checkout@v2
+      - uses: actions/checkout@v3
 
       - name: Set up JDK ${{ matrix.java }}
-        uses: actions/setup-java@v1
+        uses: actions/setup-java@v3
         with:
+          distribution: temurin
           java-version: ${{ matrix.java }}
 
-      - uses: actions/cache@v1
+      - uses: actions/cache@v3
         with:
           path: ~/.m2/repository
           key: ${{ matrix.os }}-maven-${{ hashFiles('**/pom.xml') }}
diff --git a/sshd-ldap/pom.xml b/sshd-ldap/pom.xml
index 6a3b57dd0..df0f0a4e7 100644
--- a/sshd-ldap/pom.xml
+++ b/sshd-ldap/pom.xml
@@ -82,7 +82,6 @@
        <dependency>
             <groupId>org.apache.directory.server</groupId>
             <artifactId>apacheds-test-framework</artifactId>
-            <version>${apacheds.version}</version>
             <scope>test</scope>
         </dependency>
         <!--
@@ -134,4 +133,26 @@
             </plugin>
         </plugins>
     </build>
+    
+    <profiles>
+        <profile>
+            <id>test-on-java16+</id>
+            <activation>
+                <jdk>[16,)</jdk>
+            </activation>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-surefire-plugin</artifactId>
+                        <configuration>
+                            <useModulePath>false</useModulePath>
+                            <!-- See https://issues.apache.org/jira/browse/DIRSTUDIO-1277 -->
+                            <argLine>--add-opens=java.base/sun.security.util=ALL-UNNAMED --add-opens=java.base/sun.security.x509=ALL-UNNAMED</argLine>
+                        </configuration>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
 </project>
diff --git a/sshd-sftp/pom.xml b/sshd-sftp/pom.xml
index c706b61db..2e19b8503 100644
--- a/sshd-sftp/pom.xml
+++ b/sshd-sftp/pom.xml
@@ -137,19 +137,19 @@
             </activation>
 
             <dependencies>
-		        <dependency>
-		            <groupId>org.apache.sshd</groupId>
-		            <artifactId>sshd-mina</artifactId>
-		            <version>${project.version}</version>
-		            <scope>test</scope>
-		        </dependency>
+                <dependency>
+                    <groupId>org.apache.sshd</groupId>
+                    <artifactId>sshd-mina</artifactId>
+                    <version>${project.version}</version>
+                    <scope>test</scope>
+                </dependency>
             </dependencies>
 
             <build>
                 <plugins>
-		            <plugin>
-		                <groupId>org.apache.maven.plugins</groupId>
-		                <artifactId>maven-surefire-plugin</artifactId>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-surefire-plugin</artifactId>
                         <executions>
                             <execution>
                                 <id>mina</id>
@@ -158,14 +158,14 @@
                                 </goals>
                                 <configuration>
                                     <redirectTestOutputToFile>true</redirectTestOutputToFile>
-				                    <reportsDirectory>${project.build.directory}/surefire-reports-mina</reportsDirectory>
-				                    <systemProperties>
-				                        <org.apache.sshd.common.io.IoServiceFactoryFactory>org.apache.sshd.mina.MinaServiceFactoryFactory</org.apache.sshd.common.io.IoServiceFactoryFactory>
-				                    </systemProperties>
+                                    <reportsDirectory>${project.build.directory}/surefire-reports-mina</reportsDirectory>
+                                    <systemProperties>
+                                        <org.apache.sshd.common.io.IoServiceFactoryFactory>org.apache.sshd.mina.MinaServiceFactoryFactory</org.apache.sshd.common.io.IoServiceFactoryFactory>
+                                    </systemProperties>
                                 </configuration>
                             </execution>
                         </executions>
-		            </plugin>
+                    </plugin>
                 </plugins>
             </build>
         </profile>
@@ -180,19 +180,19 @@
             </activation>
 
             <dependencies>
-		        <dependency>
-		            <groupId>org.apache.sshd</groupId>
-		            <artifactId>sshd-netty</artifactId>
-		            <version>${project.version}</version>
-		            <scope>test</scope>
-		        </dependency>
+                <dependency>
+                    <groupId>org.apache.sshd</groupId>
+                    <artifactId>sshd-netty</artifactId>
+                    <version>${project.version}</version>
+                    <scope>test</scope>
+                </dependency>
             </dependencies>
 
             <build>
                 <plugins>
-		            <plugin>
-		                <groupId>org.apache.maven.plugins</groupId>
-		                <artifactId>maven-surefire-plugin</artifactId>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-surefire-plugin</artifactId>
                         <executions>
                             <execution>
                                 <id>netty</id>
@@ -201,14 +201,14 @@
                                 </goals>
                                 <configuration>
                                     <redirectTestOutputToFile>true</redirectTestOutputToFile>
-				                    <reportsDirectory>${project.build.directory}/surefire-reports-netty</reportsDirectory>
-				                    <systemProperties>
-				                        <org.apache.sshd.common.io.IoServiceFactoryFactory>org.apache.sshd.netty.NettyIoServiceFactoryFactory</org.apache.sshd.common.io.IoServiceFactoryFactory>
-				                    </systemProperties>
+                                    <reportsDirectory>${project.build.directory}/surefire-reports-netty</reportsDirectory>
+                                    <systemProperties>
+                                        <org.apache.sshd.common.io.IoServiceFactoryFactory>org.apache.sshd.netty.NettyIoServiceFactoryFactory</org.apache.sshd.common.io.IoServiceFactoryFactory>
+                                    </systemProperties>
                                 </configuration>
                             </execution>
                         </executions>
-		            </plugin>
+                    </plugin>
                 </plugins>
             </build>
         </profile>