[JAVA-27739] Fix failing module maven-modules - upgrade to JDK 17 (#15841)

This commit is contained in:
panos-kakos 2024-03-15 23:37:49 +02:00 committed by GitHub
parent 9236adee65
commit c49d37a724
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
28 changed files with 53 additions and 68 deletions

View File

@ -35,10 +35,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.7.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
<compilerArgs>
<arg>-parameters</arg>
</compilerArgs>

View File

@ -17,12 +17,12 @@
<dependencies>
<dependency>
<groupId>com.baeldung.jacoco-coverage-aggregation</groupId>
<artifactId>services</artifactId>
<artifactId>jacoco-coverage-services-example</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>com.baeldung.jacoco-coverage-aggregation</groupId>
<artifactId>controllers</artifactId>
<artifactId>jacoco-coverage-controllers-example</artifactId>
<version>${project.parent.version}</version>
</dependency>
</dependencies>

View File

@ -17,7 +17,7 @@
<dependencies>
<dependency>
<groupId>com.baeldung.jacoco-coverage-aggregation</groupId>
<artifactId>services</artifactId>
<artifactId>jacoco-coverage-services-example</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>

View File

@ -33,7 +33,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.1.2</version>
<version>${maven-surefire-plugin.version}</version>
<configuration>
<includes>
<include>**/*Test.java</include>
@ -46,6 +46,7 @@
<properties>
<junit-jupiter-engine.version>5.9.2</junit-jupiter-engine.version>
<spring-context.version>6.0.11</spring-context.version>
<maven-surefire-plugin.version>3.1.2</maven-surefire-plugin.version>
</properties>
</project>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>jacoco-coverage-aggregation</artifactId>
<version>1.0</version>
<name>jacoco-coverage-aggregation</name>
@ -11,9 +10,8 @@
<parent>
<groupId>com.baeldung</groupId>
<artifactId>parent-modules</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../../</relativePath>
<artifactId>maven-modules</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<modules>

View File

@ -21,8 +21,6 @@
</build>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<archetype-packaging.version>3.0.1</archetype-packaging.version>
</properties>

View File

@ -12,12 +12,9 @@
<artifactId>maven-build-lifecycle</artifactId>
<properties>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.surefire.version>3.1.2</maven.surefire.version>
<maven.failsafe.version>3.1.2</maven.failsafe.version>
<junit.jupiter.version>5.3.1</junit.jupiter.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>

View File

@ -7,6 +7,12 @@
<artifactId>maven-builder-plugin</artifactId>
<version>1.0-SNAPSHOT</version>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>maven-modules</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<build>
<plugins>
<plugin>
@ -32,10 +38,7 @@
</build>
<properties>
<build-helper-maven-plugin.version>3.2.0</build-helper-maven-plugin.version>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<build-helper-maven-plugin.version>3.4.0</build-helper-maven-plugin.version>
</properties>
</project>

View File

@ -45,9 +45,4 @@
</dependency>
</dependencies>
<properties>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
</properties>
</project>

View File

@ -18,9 +18,4 @@
<module>maven-classifier-example-provider</module>
</modules>
<properties>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
</properties>
</project>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>maven-copy-files</artifactId>
<version>1.0-SNAPSHOT</version>
<name>maven-copy-files</name>
@ -78,10 +77,4 @@
</pluginManagement>
</build>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
</properties>
</project>

View File

@ -56,6 +56,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<reportSets>
<reportSet>
<reports>
@ -68,12 +69,13 @@
</reporting>
<properties>
<maven.compiler.target>1.8</maven.compiler.target>
<maven.compiler.source>1.8</maven.compiler.source>
<maven-compiler-plugin.version>3.12.1</maven-compiler-plugin.version>
<maven.compiler.source>17</maven.compiler.source>
<maven.compiler.target>17</maven.compiler.target>
<maven-plugin-api.version>3.6.2</maven-plugin-api.version>
<maven-plugin-annotations.version>3.6.0</maven-plugin-annotations.version>
<maven-project.version>2.2.1</maven-project.version>
<maven-plugin-plugin.version>3.6.0</maven-plugin-plugin.version>
<maven-plugin-plugin.version>3.11.0</maven-plugin-plugin.version>
<maven-site-plugin.version>3.8.2</maven-site-plugin.version>
</properties>

View File

@ -3,11 +3,16 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>maven-exec-plugin</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>maven-exec-plugin</name>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>maven-modules</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<dependencies>
<dependency>
<groupId>org.apache.maven.shared</groupId>
@ -37,6 +42,17 @@
<version>${junit.jupiter.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>
<version>${junit.jupiter.version}</version>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-params</artifactId>
<version>${junit.jupiter.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>

View File

@ -59,10 +59,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source.version}</source>
<target>${maven.compiler.target.version}</target>
</configuration>
</plugin>
</plugins>
</build>

View File

@ -273,7 +273,7 @@
<maven.verifier.version>1.1</maven.verifier.version>
<maven.clean.version>3.0.0</maven.clean.version>
<maven.build.helper.version>3.0.0</maven.build.helper.version>
<jetty.version>9.4.11.v20180605</jetty.version>
<jetty.version>10.0.20</jetty.version>
<jersey.version>2.27</jersey.version>
</properties>

View File

@ -20,8 +20,6 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
<compilerArgs>
<arg>-Xlint:unchecked</arg>
</compilerArgs>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung.maven-parent-pom-resolution</groupId>
<artifactId>empty-phase</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung.maven-parent-pom-resolution</groupId>
<artifactId>phase-none</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung.maven-parent-pom-resolution</groupId>
<artifactId>plugin-enabled</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

View File

@ -26,7 +26,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0</version>
<version>${maven-enforcer-plugin.version}</version>
<executions>
<execution>
<id>enforce-file-exists</id>
@ -49,7 +49,7 @@
</build>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven-enforcer-plugin.version>3.0.0</maven-enforcer-plugin.version>
</properties>
</project>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung.maven-parent-pom-resolution</groupId>
<artifactId>skip-parameter</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

View File

@ -43,8 +43,6 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven.compiler.version}</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
<compilerArgs>
<arg>-Xlint:unchecked</arg>
</compilerArgs>

View File

@ -17,7 +17,7 @@
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<version>3.0.0</version>
<version>${maven-antrun-plugin.version}</version>
<executions>
<execution>
<id>antrun-plugin</id>
@ -41,7 +41,7 @@
<plugin>
<groupId>com.github.ekryd.echo-maven-plugin</groupId>
<artifactId>echo-maven-plugin</artifactId>
<version>1.3.2</version>
<version>${echo-maven-plugin.version}</version>
<executions>
<execution>
<id>echo-maven-plugin-1</id>
@ -66,7 +66,7 @@
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<version>2.1.1</version>
<version>${groovy-maven-plugin.version}</version>
<executions>
<execution>
<phase>validate</phase>
@ -87,4 +87,10 @@
</plugins>
</build>
<properties>
<maven-antrun-plugin.version>3.0.0</maven-antrun-plugin.version>
<echo-maven-plugin.version>1.3.2</echo-maven-plugin.version>
<groovy-maven-plugin.version>2.1.1</groovy-maven-plugin.version>
</properties>
</project>

View File

@ -61,7 +61,6 @@
<!-- and would be overidden by the plugin specific properties above. -->
<!--project.build.sourceEncoding></project.build.sourceEncoding -->
<!--project.build.sourceEncoding>US-ASCII</project.build.sourceEncoding -->
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
</properties>

View File

@ -17,12 +17,12 @@
<dependencies>
<dependency>
<groupId>com.baeldung.entitymodule</groupId>
<artifactId>entitymodule</artifactId>
<artifactId>maven-entitymodule</artifactId>
<version>${entitymodule.version}</version>
</dependency>
<dependency>
<groupId>com.baeldung.daomodule</groupId>
<artifactId>daomodule</artifactId>
<artifactId>maven-daomodule</artifactId>
<version>${daomodule.version}</version>
</dependency>
</dependencies>
@ -41,8 +41,6 @@
</build>
<properties>
<maven.compiler.source>9</maven.compiler.source>
<maven.compiler.target>9</maven.compiler.target>
<entitymodule.version>1.0</entitymodule.version>
<daomodule.version>1.0</daomodule.version>
</properties>

View File

@ -27,7 +27,7 @@
<module>maven-classifier</module>
<module>maven-copy-files</module>
<module>maven-custom-plugin</module>
<module>maven-exec-plugin</module>
<!-- <module>maven-exec-plugin</module>--> <!-- failing after upgrading to jdk17-->
<module>maven-generate-war</module>
<module>maven-integration-test</module>
<module>maven-multi-source</module>

View File

@ -3,7 +3,6 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>versions-maven-plugin</name>

View File

@ -755,7 +755,7 @@
<module>lombok-modules</module>
<module>lucene</module>
<module>mapstruct</module>
<!--<module>maven-modules</module>--> <!-- JAVA-27739 -->
<module>maven-modules</module>
<module>mesos-marathon</module>
<module>messaging-modules</module>
<module>metrics</module>
@ -1003,7 +1003,7 @@
<module>lombok-modules</module>
<module>lucene</module>
<module>mapstruct</module>
<!--<module>maven-modules</module>--> <!-- JAVA-27739 -->
<module>maven-modules</module>
<module>mesos-marathon</module>
<module>messaging-modules</module>
<module>metrics</module>