From d1090c50ce66e10ab0adcadb996b0fe790c900b6 Mon Sep 17 00:00:00 2001 From: Michael Osipov Date: Wed, 30 Oct 2024 12:50:24 +0100 Subject: [PATCH 1/4] [maven-release-plugin] prepare for next development iteration --- pom.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 14e397917..bb2d1b96b 100644 --- a/pom.xml +++ b/pom.xml @@ -28,7 +28,7 @@ under the License. maven-javadoc-plugin - 3.11.0 + 3.11.1-SNAPSHOT maven-plugin Apache Maven Javadoc Plugin @@ -91,7 +91,7 @@ under the License. scm:git:https://gitbox.apache.org/repos/asf/maven-javadoc-plugin.git scm:git:https://gitbox.apache.org/repos/asf/maven-javadoc-plugin.git - maven-javadoc-plugin-3.11.0 + HEAD https://github.com/apache/maven-javadoc-plugin/tree/${project.scm.tag} @@ -127,7 +127,7 @@ under the License. 3.3.0 3.20.0 3.7.0 - 2024-10-30T11:47:51Z + 2024-10-30T11:50:24Z 1.7.36 From 62a686180915de1e3c0a2f71081776eacfd1d4c3 Mon Sep 17 00:00:00 2001 From: Laurent Goujon Date: Wed, 9 Oct 2024 11:56:17 -0600 Subject: [PATCH 2/4] [MJAVADOC-820] [REGRESSION] MJAVADOC-787 was merged incompletely This closes #333 --- pom.xml | 2 +- .../org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index bb2d1b96b..16b9e43fd 100644 --- a/pom.xml +++ b/pom.xml @@ -120,7 +120,7 @@ under the License. 9.4.55.v20240627 4.0.2 - 3.11.0 + 3.13.0 3.3.0 3.4.1 3.15.0 diff --git a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java index c5d9ce293..c0efb5716 100644 --- a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java +++ b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java @@ -4625,7 +4625,7 @@ private void addJavadocOptions( addArgIf(arguments, quiet, "-quiet", SINCE_JAVADOC_1_5); } - if (release != null) { + if (javadocRuntimeVersion.isAtLeast("9") && release != null) { arguments.add("--release"); arguments.add(release); } else { From e314da0226d100eae39d96d7a0cbdad799879dca Mon Sep 17 00:00:00 2001 From: Michael Osipov Date: Wed, 30 Oct 2024 15:43:50 +0100 Subject: [PATCH 3/4] [MJAVADOC-821] Align toolchain discovery code with Maven Compiler Plugin This closes #334 --- .../plugins/javadoc/AbstractJavadocMojo.java | 21 +++---------------- 1 file changed, 3 insertions(+), 18 deletions(-) diff --git a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java index c0efb5716..5c545aa32 100644 --- a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java +++ b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java @@ -23,7 +23,6 @@ import java.io.IOException; import java.io.InputStream; import java.io.Writer; -import java.lang.reflect.Method; import java.net.MalformedURLException; import java.net.URI; import java.net.URISyntaxException; @@ -2615,27 +2614,13 @@ public Artifact resolveDependency(Dependency dependency) throws MavenReportExcep } } - // TODO remove the part with ToolchainManager lookup once we depend on - // 3.0.9 (have it as prerequisite). Define as regular component field then. protected final Toolchain getToolchain() { Toolchain tc = null; if (jdkToolchain != null) { - // Maven 3.3.1 has plugin execution scoped Toolchain Support - try { - Method getToolchainsMethod = toolchainManager - .getClass() - .getMethod("getToolchains", MavenSession.class, String.class, Map.class); - - @SuppressWarnings("unchecked") - List tcs = - (List) getToolchainsMethod.invoke(toolchainManager, session, "jdk", jdkToolchain); - - if (tcs != null && tcs.size() > 0) { - tc = tcs.get(0); - } - } catch (SecurityException | ReflectiveOperationException e) { - // ignore + List tcs = toolchainManager.getToolchains(session, "jdk", jdkToolchain); + if (tcs != null && !tcs.isEmpty()) { + tc = tcs.get(0); } } From 619650c667070ef114d571c0f075ce456ace1cf8 Mon Sep 17 00:00:00 2001 From: Michael Osipov Date: Wed, 30 Oct 2024 17:52:10 +0100 Subject: [PATCH 4/4] [maven-release-plugin] prepare release maven-javadoc-plugin-3.11.1 --- pom.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 16b9e43fd..fbe6deb8f 100644 --- a/pom.xml +++ b/pom.xml @@ -28,7 +28,7 @@ under the License. maven-javadoc-plugin - 3.11.1-SNAPSHOT + 3.11.1 maven-plugin Apache Maven Javadoc Plugin @@ -91,7 +91,7 @@ under the License. scm:git:https://gitbox.apache.org/repos/asf/maven-javadoc-plugin.git scm:git:https://gitbox.apache.org/repos/asf/maven-javadoc-plugin.git - HEAD + maven-javadoc-plugin-3.11.1 https://github.com/apache/maven-javadoc-plugin/tree/${project.scm.tag} @@ -127,7 +127,7 @@ under the License. 3.3.0 3.20.0 3.7.0 - 2024-10-30T11:50:24Z + 2024-10-30T16:49:47Z 1.7.36