Maven 3 warnings about build.plugins.plugin.version

MavenMaven PluginMaven 3

Maven Problem Overview

Since I updated to Maven 3 I get the following warning messages at each build :

How can I get rid of these warnings?

[INFO] Scanning for projects...
[WARNING] Some problems were encountered while building the effective model for proj:id:jar:3.1
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-javadoc-plugin is missing. @ line 195, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 204, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-surefire-plugin is missing. @ line 227, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-jar-plugin is missing. @ line 215, column 15
[WARNING] 'reporting.plugins.plugin.version' for org.codehaus.mojo:jdepend-maven-plugin is missing. @ line 271, column 15
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.

Maven Solutions

Solution 1 - Maven

Add a <version> element after the <plugin> <artifactId> in your pom.xml file. Find the following text:


Add the version tag to it:


The warning should be resolved.

Regarding this:

> 'build.plugins.plugin.version' for > org.apache.maven.plugins:maven-compiler-plugin is missing

Many people have mentioned why the issue is happening, but fail to suggest a fix. All I needed to do was to go into my POM file for my project, and add the <version> tag as shown above.

To discover the version number, one way is to look in Maven's output after it finishes running. Where you are missing version numbers, Maven will display its default version:

[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) @ entities ---

Take that version number (as in the 2.3.2 above) and add it to your POM, as shown.

Solution 2 - Maven

Run like:

$ mvn help:describe -DartifactId=maven-war-plugin -DgroupId=org.apache.maven.plugins

for plug-in that have no version. You get output:

Name: Maven WAR Plugin
Description: Builds a Web Application Archive (WAR) file from the project
output and its dependencies.
Group Id: org.apache.maven.plugins
Artifact Id: maven-war-plugin
Version: 2.2
Goal Prefix: war

Use version that shown in output.

UPDATE If you want to select among list of versions, use or Note that your favorite Java IDE must have Maven package search dialog. Just check docs.

SUPER UPDATE I also use:

$ mvn dependency:tree
$ mvn dependency:list
$ mvn dependency:resolve
$ mvn dependency:resolve-plugins  # <-- THIS

Recently I discover how to get latest version for plug-in (or library) so no longer needs for googling or visiting Maven Central:

$ mvn versions:display-dependency-updates
$ mvn versions:display-plugin-updates     # <-- THIS

Solution 3 - Maven

get the latest version information from:

click on the latest version (or the one you'd like to use) and you'll see the the dependency info (as of 2019-05 it's 3.8.1):

<!-- -->

you might want to use the version tag and the comment for your plugin tag.

<!-- -->
		<source />
		<target />

if you like you can modify your pom to have the version information in the properties tag as outlined in another answer.

Solution 4 - Maven

Maven 3 is more restrictive with the POM-Structure. You have to set versions of Plugins for instance.

With maven 3.1 these warnings may break you build. There are more changes between maven2 and maven3:

Solution 5 - Maven

I'm using a parent pom for my projects and wanted to specify the versions in one place, so I used properties to specify the version:

parent pom:

<project xmlns=""

project pom:

<project xmlns=""

See also:

Solution 6 - Maven

It's great answer in here. And I want to add 'Why Add a element in Maven3'.
In Maven 3.x Compatibility Notes

>Plugin Metaversion Resolution
Internally, Maven 2.x used the special version markers RELEASE and LATEST to support automatic plugin version resolution. These metaversions were also recognized in the element for a declaration. For the sake of reproducible builds, Maven 3.x no longer supports usage of these metaversions in the POM. As a result, users will need to replace occurrences of these metaversions with a concrete version.

And I also find in maven-compiler-plugin - usage >Note: Maven 3.0 will issue warnings if you do not specify the version of a plugin.

Solution 7 - Maven

Search "maven-jar-plugin" in pom.xml and add version tag maven version


All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionIstaoView Question on Stackoverflow
Solution 1 - MavenToddView Answer on Stackoverflow
Solution 2 - MavengavenkoaView Answer on Stackoverflow
Solution 3 - MavenWolfgang FahlView Answer on Stackoverflow
Solution 4 - MavenChristian KuetbachView Answer on Stackoverflow
Solution 5 - MavenPatrick KoorevaarView Answer on Stackoverflow
Solution 6 - MavenohahohahView Answer on Stackoverflow
Solution 7 - MavenShukantView Answer on Stackoverflow