[2.x] Pre-release tidy-up (#1011)

Changes:
* no source change
* (build) expel all versions from child modules: they must be all top level depMgmt or pluginMgmt
* (build) Top POM contains GAVs while child modules GA+scope. This tremendously simplifies maintenance.
* (javadoc) fix Javadoc errors
* (build) remove obsolete profiles and mr-JARs, project is 17+

Updates:
* maven wrapper 3.3.2 w/ scripts
This commit is contained in:
Tamas Cservenak
2024-06-13 10:05:16 +02:00
committed by GitHub
parent d3cc476ae3
commit bc61f6441e
16 changed files with 107 additions and 236 deletions

View File

@@ -15,4 +15,5 @@
# specific language governing permissions and limitations
# under the License.
wrapperVersion=3.3.2
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip
distributionType=only-script
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.7/apache-maven-3.9.7-bin.zip

View File

@@ -31,12 +31,10 @@
<name>Maven Daemon - Agent</name>
<dependencies>
<dependency>
<groupId>org.javassist</groupId>
<artifactId>javassist</artifactId>
</dependency>
</dependencies>
<build>

View File

@@ -30,31 +30,6 @@
<packaging>maven-plugin</packaging>
<name>Maven Daemon - Documentation Maven Plugin</name>
<properties>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<roaster.version>2.29.0.Final</roaster.version>
<maven.version>3.9.6</maven.version>
<maven.plugin-tools.version>3.13.0</maven.plugin-tools.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>${maven.version}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>${maven.plugin-tools.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
@@ -70,9 +45,7 @@
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-jdt</artifactId>
<version>${roaster.version}</version>
</dependency>
</dependencies>
<build>
@@ -81,7 +54,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>${maven.plugin-tools.version}</version>
</plugin>
</plugins>
</pluginManagement>

View File

@@ -36,7 +36,6 @@
</properties>
<dependencies>
<dependency>
<groupId>org.jline</groupId>
<artifactId>jline-terminal</artifactId>
@@ -68,7 +67,6 @@
<plugin>
<groupId>org.apache.maven.daemon</groupId>
<artifactId>mvnd-build-maven-plugin</artifactId>
<version>${project.version}</version>
<executions>
<execution>
<goals>
@@ -78,6 +76,16 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
@@ -92,112 +100,4 @@
</plugins>
</build>
<profiles>
<profile>
<id>jdk11-15</id>
<activation>
<jdk>[11,15)</jdk>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<executions>
<execution>
<id>default-compile</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
</configuration>
</execution>
<execution>
<id>jdk11</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
<release>11</release>
<multiReleaseOutput>true</multiReleaseOutput>
<compileSourceRoots>
<root>${project.basedir}/src/main/java11</root>
</compileSourceRoots>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>jdk16+</id>
<activation>
<jdk>[16,)</jdk>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<executions>
<execution>
<id>default-compile</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
</configuration>
</execution>
<execution>
<id>jdk11</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
<release>11</release>
<multiReleaseOutput>true</multiReleaseOutput>
<compileSourceRoots>
<root>${project.basedir}/src/main/java11</root>
</compileSourceRoots>
</configuration>
</execution>
<execution>
<id>jdk16</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<fork>true</fork>
<compilerArgs>
<arg>-XDignore.symbol.file</arg>
</compilerArgs>
<release>16</release>
<multiReleaseOutput>true</multiReleaseOutput>
<compileSourceRoots>
<root>${project.basedir}/src/main/java16</root>
</compileSourceRoots>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

View File

@@ -75,7 +75,7 @@ public class InterpolationHelper {
* <p>
* This method performs property variable substitution on the
* specified value. If the specified value contains the syntax
* <tt>${&lt;prop-name&gt;}</tt>, where <tt>&lt;prop-name&gt;</tt>
* {@code ${prop-name}}, where {@code prop-name}
* refers to either a configuration property or a system property,
* then the corresponding property value is substituted for the variable
* placeholder. Multiple variable placeholders may exist in the

View File

@@ -138,7 +138,7 @@ public class OsUtils {
/**
* A simple wrapper over {@link Process} that manages its destroying and offers Java 8-like
* {@link #waitFor(long, TimeUnit, String[])} with timeout.
* {@link #waitFor(long)} with timeout.
*/
public static class CommandProcess implements AutoCloseable {
public static final int TIMEOUT_EXIT_CODE = Integer.MIN_VALUE + 42;

View File

@@ -20,5 +20,7 @@ package org.mvndaemon.mvnd.common;
public class ProcessHelper {
public static void killChildrenProcesses() {}
public static void killChildrenProcesses() {
ProcessHandle.current().descendants().forEach(ProcessHandle::destroy);
}
}

View File

@@ -20,20 +20,22 @@ package org.mvndaemon.mvnd.common;
import java.io.IOException;
import java.net.SocketAddress;
import java.net.StandardProtocolFamily;
import java.net.UnixDomainSocketAddress;
import java.nio.channels.ServerSocketChannel;
import java.nio.channels.SocketChannel;
public class SocketHelper {
public static SocketChannel openUnixSocket() throws IOException {
throw new UnsupportedOperationException("Unix sockets are supported only on JDK >= 16");
return SocketChannel.open(StandardProtocolFamily.UNIX);
}
public static ServerSocketChannel openUnixServerSocket() throws IOException {
throw new UnsupportedOperationException("Unix sockets are supported only on JDK >= 16");
return ServerSocketChannel.open(StandardProtocolFamily.UNIX).bind(null, 0);
}
public static SocketAddress unixSocketAddressOf(String s) {
throw new UnsupportedOperationException("Unix sockets are supported only on JDK >= 16");
return UnixDomainSocketAddress.of(s);
}
}

View File

@@ -1,26 +0,0 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.mvndaemon.mvnd.common;
public class ProcessHelper {
public static void killChildrenProcesses() {
ProcessHandle.current().descendants().forEach(ProcessHandle::destroy);
}
}

View File

@@ -1,41 +0,0 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.mvndaemon.mvnd.common;
import java.io.IOException;
import java.net.SocketAddress;
import java.net.StandardProtocolFamily;
import java.net.UnixDomainSocketAddress;
import java.nio.channels.ServerSocketChannel;
import java.nio.channels.SocketChannel;
public class SocketHelper {
public static SocketChannel openUnixSocket() throws IOException {
return SocketChannel.open(StandardProtocolFamily.UNIX);
}
public static ServerSocketChannel openUnixServerSocket() throws IOException {
return ServerSocketChannel.open(StandardProtocolFamily.UNIX).bind(null, 0);
}
public static SocketAddress unixSocketAddressOf(String s) {
return UnixDomainSocketAddress.of(s);
}
}

View File

@@ -94,14 +94,11 @@
<dependency>
<groupId>org.eclipse.sisu</groupId>
<artifactId>org.eclipse.sisu.inject</artifactId>
<version>${sisu.version}</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>6.0.0</version>
</dependency>
<dependency>

1
dist/pom.xml vendored
View File

@@ -59,7 +59,6 @@
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>6.0.0</version>
<scope>provided</scope>
</dependency>
</dependencies>

View File

@@ -40,8 +40,6 @@
org/junit/platform/junit-platform-commons/${junit-platform-launcher.version}
org/junit/jupiter/junit-jupiter/${junit.jupiter.version}
org/junit/jupiter/junit-jupiter-api/${junit.jupiter.version}</preinstall.artifacts>
<testcontainers.version>1.19.8</testcontainers.version>
</properties>
<dependencies>
@@ -85,13 +83,11 @@
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>testcontainers</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

View File

@@ -97,7 +97,6 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.6.0</version>
<executions>
<execution>
<id>add-unpacked-source-dir</id>

View File

@@ -28,10 +28,6 @@
<packaging>jar</packaging>
<name>Maven Daemon - Native Library</name>
<properties>
<picocli.version>4.7.6</picocli.version>
</properties>
<dependencies>
<dependency>
<groupId>org.junit.jupiter</groupId>
@@ -46,7 +42,6 @@
<dependency>
<groupId>info.picocli</groupId>
<artifactId>picocli-codegen</artifactId>
<version>${picocli.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

93
pom.xml
View File

@@ -90,6 +90,7 @@
<maven.resolver.version>2.0.0-alpha-11</maven.resolver.version>
<slf4j.version>2.0.11</slf4j.version>
<sisu.version>0.9.0.M2</sisu.version>
<maven.plugin-tools.version>3.13.1</maven.plugin-tools.version>
<!-- plugin versions a..z -->
<buildnumber-maven-plugin.version>3.2.0</buildnumber-maven-plugin.version>
@@ -99,9 +100,12 @@
<takari-provisio.version>1.0.25</takari-provisio.version>
<javassist.version>3.30.2-GA</javassist.version>
<xstream.version>1.4.20</xstream.version>
<picocli.version>4.7.6</picocli.version>
<plexus-interactivity-api.version>1.3</plexus-interactivity-api.version>
<roaster.version>2.29.0.Final</roaster.version>
<takari-smart-builder.version>0.6.6</takari-smart-builder.version>
<testcontainers.version>1.19.8</testcontainers.version>
<xstream.version>1.4.20</xstream.version>
</properties>
<dependencyManagement>
@@ -148,6 +152,11 @@
<version>${jakarta.inject.version}</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>${maven.version}</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-model</artifactId>
@@ -175,6 +184,11 @@
<classifier>bin</classifier>
<type>tar.gz</type>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>${maven.plugin-tools.version}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.resolver</groupId>
@@ -262,11 +276,33 @@
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>io.takari.maven</groupId>
<artifactId>takari-smart-builder</artifactId>
<version>${takari-smart-builder.version}</version>
</dependency>
<dependency>
<groupId>org.eclipse.sisu</groupId>
<artifactId>org.eclipse.sisu.inject</artifactId>
<version>${sisu.version}</version>
</dependency>
<dependency>
<groupId>org.eclipse.sisu</groupId>
<artifactId>org.eclipse.sisu.plexus</artifactId>
<version>${sisu.version}</version>
</dependency>
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>6.0.0</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>33.2.1-jre</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jline</groupId>
@@ -289,6 +325,12 @@
<version>${jline.version}</version>
</dependency>
<dependency>
<groupId>info.picocli</groupId>
<artifactId>picocli-codegen</artifactId>
<version>${picocli.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>log4j-over-slf4j</artifactId>
@@ -304,6 +346,11 @@
<artifactId>jul-to-slf4j</artifactId>
<version>${slf4j.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.forge.roaster</groupId>
<artifactId>roaster-jdt</artifactId>
<version>${roaster.version}</version>
</dependency>
<dependency>
<groupId>org.javassist</groupId>
@@ -323,15 +370,14 @@
</dependency>
<dependency>
<groupId>io.takari.maven</groupId>
<artifactId>takari-smart-builder</artifactId>
<version>${takari-smart-builder.version}</version>
<groupId>org.testcontainers</groupId>
<artifactId>testcontainers</artifactId>
<version>${testcontainers.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>33.2.0-jre</version>
<scope>provided</scope>
<groupId>org.testcontainers</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${testcontainers.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
@@ -339,6 +385,11 @@
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.daemon</groupId>
<artifactId>mvnd-build-maven-plugin</artifactId>
<version>${project.version}</version>
</plugin>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
@@ -416,6 +467,26 @@
<artifactId>native-maven-plugin</artifactId>
<version>${graalvm.plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.7.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.7.0</version>
<configuration>
<release>${maven-dist.required.jdk}</release>
<detectJavaApiLink>false</detectJavaApiLink>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>${maven.plugin-tools.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
@@ -435,6 +506,12 @@
<artifactId>maven-wrapper-plugin</artifactId>
<version>3.3.2</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.6.0</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>