This is an automated email from the ASF dual-hosted git repository. slachiewicz pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/maven-site.git
commit 4122ea25c131f9ec321a1d5162b714d39088d973 Author: Sylwester Lachiewicz <[email protected]> AuthorDate: Mon Nov 2 08:38:03 2026 +0000 Show current Maven versions in the samples --- .../guides/getting-started/maven-in-five-minutes.md | 18 +++++++++--------- .../guides/plugin/guide-java-plugin-development.md.vm | 2 +- .../plugin/guide-java-report-plugin-development.md.vm | 4 ++-- content/markdown/pom.md | 2 +- content/markdown/repositories/layout.md | 6 +++--- content/markdown/repository/layout.md | 2 +- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/content/markdown/guides/getting-started/maven-in-five-minutes.md b/content/markdown/guides/getting-started/maven-in-five-minutes.md index 6bea2aed..eb4b7de0 100644 --- a/content/markdown/guides/getting-started/maven-in-five-minutes.md +++ b/content/markdown/guides/getting-started/maven-in-five-minutes.md @@ -36,11 +36,11 @@ mvn --version It should print out your installed version of Maven, for example: ``` -Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f) -Maven home: D:\apache-maven-3.6.3\apache-maven\bin.. -Java version: 1.8.0_232, vendor: AdoptOpenJDK, runtime: C:\Program Files\AdoptOpenJDK\jdk-8.0.232.09-hotspot\jre -Default locale: en_US, platform encoding: Cp1250 -OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows" +Apache Maven 3.10.0 (c43a36b8d67be7e0805a411bc0898af1a51f5472) +Maven home: /opt/apache-maven-3.10.0 +Java version: 21.0.12.1, vendor: Ubuntu, runtime: /usr/lib/jvm/java-21-openjdk-arm64 +Default locale: en, platform encoding: UTF-8, time zone: Etc/UTC +OS name: "linux", version: "7.0.0-1013-oracle", arch: "aarch64", family: "unix" ``` Depending upon your network setup, you may require extra configuration. Check out the [Guide to Configuring Maven](../mini/guide-configuring-maven.html) if necessary. @@ -186,13 +186,13 @@ Hello World! ## Java 9 or later -By default your version of Maven might use an old version of the `maven-compiler-plugin` that is not compatible with Java 9 or later versions. To target Java 9 or later, you should at least use version 3.6.0 of the `maven-compiler-plugin` and set the `maven.compiler.release` property to the Java release you are targetting (e.g. 9, 10, 11, 12, etc.). +Recent Maven versions use a recent `maven-compiler-plugin` by default (3.15.0 with Maven 3.9.16, 3.16.0 with Maven 3.10.0). With an older Maven, you need at least version 3.6.0 of the `maven-compiler-plugin` to target Java 9 or later. Either way, set the `maven.compiler.release` property to the Java release you are targeting (e.g. 17, 21 or 25), and pin the plugin version so that your build does not change with the Maven version that runs it. -In the following example, we have configured our Maven project to use version 3.8.1 of `maven-compiler-plugin` and target Java 11: +In the following example, we have configured our Maven project to use version 3.16.0 of `maven-compiler-plugin` and target Java 17: ```xml <properties> - <maven.compiler.release>11</maven.compiler.release> + <maven.compiler.release>17</maven.compiler.release> </properties> <build> @@ -201,7 +201,7 @@ In the following example, we have configured our Maven project to use version 3. <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> - <version>3.8.1</version> + <version>3.16.0</version> </plugin> </plugins> </pluginManagement> diff --git a/content/markdown/guides/plugin/guide-java-plugin-development.md.vm b/content/markdown/guides/plugin/guide-java-plugin-development.md.vm index fa563c97..5fdd91e2 100644 --- a/content/markdown/guides/plugin/guide-java-plugin-development.md.vm +++ b/content/markdown/guides/plugin/guide-java-plugin-development.md.vm @@ -118,7 +118,7 @@ Listed below is an illustration of the sample mojo project's pom with the parame <dependency> <groupId>org.apache.maven</groupId> <artifactId>maven-plugin-api</artifactId> - <version>3.9.9</version> + <version>3.9.16</version> <scope>provided</scope> </dependency> diff --git a/content/markdown/guides/plugin/guide-java-report-plugin-development.md.vm b/content/markdown/guides/plugin/guide-java-report-plugin-development.md.vm index c55160e2..9e46ab0b 100644 --- a/content/markdown/guides/plugin/guide-java-report-plugin-development.md.vm +++ b/content/markdown/guides/plugin/guide-java-report-plugin-development.md.vm @@ -149,13 +149,13 @@ The below examples can be copied and pasted as a template. <dependency> <groupId>org.apache.maven</groupId> <artifactId>maven-core</artifactId> - <version>3.9.11</version> + <version>3.9.16</version> <scope>provided</scope> </dependency> <dependency> <groupId>org.apache.maven</groupId> <artifactId>maven-plugin-api</artifactId> - <version>3.9.11</version> + <version>3.9.16</version> <scope>provided</scope> </dependency> <dependency> diff --git a/content/markdown/pom.md b/content/markdown/pom.md index 677dd645..ca23307e 100644 --- a/content/markdown/pom.md +++ b/content/markdown/pom.md @@ -485,7 +485,7 @@ the dependencies you use, so you exclude all the transitive dependencies: <dependency> <groupId>org.apache.maven</groupId> <artifactId>maven-embedder</artifactId> - <version>3.8.6</version> + <version>3.10.0</version> <exclusions> <exclusion> <groupId>*</groupId> diff --git a/content/markdown/repositories/layout.md b/content/markdown/repositories/layout.md index eef824e6..1c4ccd1f 100644 --- a/content/markdown/repositories/layout.md +++ b/content/markdown/repositories/layout.md @@ -38,7 +38,7 @@ The transformation rule is quite simple for that matter: consider artifact prope |-------------|---------------------------------------------------------|------------------------------------------| | groupId | Replace "." (dot) characters with "/" (slash) character | `org.apache.maven` -> `org/apache/maven` | | artifactId | none | `apache-maven` | -| version | none | `3.8.4` | +| version | none | `3.10.0` | | baseVersion | none | (in this example same as version) | | classifier | none | `bin` | | extension | none | `tar.gz` | @@ -58,13 +58,13 @@ ${groupId as directory}/${artifactId}/${baseVersion}/${artifactId}-${version}-${ So the example artifact above noted as GAV: ``` -org.apache.maven:apache-maven:3.8.4:bin:tar.gz +org.apache.maven:apache-maven:3.10.0:bin:tar.gz ``` is translated to path as: ``` -org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.tar.gz +org/apache/maven/apache-maven/3.10.0/apache-maven-3.10.0-bin.tar.gz ``` And that is it! By applying this "algorithm" above to ANY Artifact we can build up the path segment that diff --git a/content/markdown/repository/layout.md b/content/markdown/repository/layout.md index 56090742..5d14cfdc 100644 --- a/content/markdown/repository/layout.md +++ b/content/markdown/repository/layout.md @@ -74,7 +74,7 @@ Classifier and extension definition is completely different at artifact *publica ## SNAPSHOT -In case of a SNAPSHOT version, version directory uses base version, i.e. version ending in `-SNAPSHOT`, for example `3.8.4-SNAPSHOT`. +In case of a SNAPSHOT version, version directory uses base version, i.e. version ending in `-SNAPSHOT`, for example `3.10.1-SNAPSHOT`. For artifact files, there are 2 options available:
