File tree Expand file tree Collapse file tree 2 files changed +24
-3
lines changed Expand file tree Collapse file tree 2 files changed +24
-3
lines changed Original file line number Diff line number Diff line change 26
26
name : Java ${{ matrix.java }} Maven Test on ${{ matrix.os }}
27
27
strategy :
28
28
matrix :
29
- # Test against the LTS Java versions. TODO: add JDK18 when it becomes available.
30
- java : [ 8.0.x, 11.0.x, 17.0.x ]
29
+ java : [ 8.0.x, 11.0.x ]
31
30
os : [ macos-latest, windows-latest, ubuntu-latest ]
32
31
runs-on : ${{ matrix.os }}
33
32
steps :
43
42
path : ~/.m2/repository
44
43
key : ${{ runner.os }}-maven-${{ matrix.java }}-${{ hashFiles('pom.xml', '**/pom.xml') }}
45
44
- name : Build with Maven
45
+ shell : bash
46
46
run : |
47
- mvn clean test -q -B --define=org.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
47
+ if [ $(grep -E '^(8|11)\.' <<< '${{ matrix.java }}') ]; then
48
+ # some module doesn't compile on java platform lower than 17, need to skip them by specifying a profile
49
+ mvn clean test -q -B -Pcompatibility-before-java17 --define=org.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
50
+ else
51
+ mvn clean test -q -B --define=org.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
52
+ fi
48
53
build-graalvm :
49
54
runs-on : ubuntu-latest
50
55
name : GraalVM Maven Test
Original file line number Diff line number Diff line change @@ -561,5 +561,21 @@ limitations under the License.
561
561
<module >fluent-gen</module >
562
562
</modules >
563
563
</profile >
564
+ <profile >
565
+ <id >compatibility-before-java17</id >
566
+ <modules >
567
+ <module >util</module >
568
+ <module >kubernetes</module >
569
+ <module >proto</module >
570
+ <module >extended</module >
571
+ <module >fluent</module >
572
+ <module >spring</module >
573
+ <module >e2e</module >
574
+ <module >examples</module >
575
+ <module >client-java-contrib/cert-manager</module >
576
+ <module >client-java-contrib/prometheus-operator</module >
577
+ <module >client-java-contrib/admissionreview</module >
578
+ </modules >
579
+ </profile >
564
580
</profiles >
565
581
</project >
You can’t perform that action at this time.
0 commit comments