Reputation: 71
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" 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>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.1.5.RELEASE</version>
</parent>
<groupId>com.app</groupId>
<artifactId>Demo</artifactId>
<version>1.0</version>
<name>Demo</name>
<description>Demo project for Spring Boot</description>
<properties>
<java.version>1.8</java.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
Upvotes: 7
Views: 40256
Reputation: 11
It is problem that is mostly occurring in eclipse IDE only. This is scheduled to fix in later version but not sure when.
To resolve this you can add a property to update the maven jar plugin in pom.xml.
<properties>
<java.version>1.8</java.version>
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
</properties>
Once you edit the pom.xml, just do an update to your spring boot application. Right click on Springboot Application>>Maven>>update project.
The error sign from your pom.xml will go away.
Upvotes: 1
Reputation: 131
There is incompatibilities between the version of M2E and the version 3.1.2 of the maven-jar-plugin.
Until the problem is solved by the development teams of M2E or maven-jar-plugins, you have to add in your pom.xml file the following line in order to solve this issue:
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.1.1</version>
</plugin>
</plugins>
</pluginManagement>
</build>
Upvotes: 3
Reputation: 131
Please update tag in porm.xml
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
</properties>
Upvotes: 0
Reputation: 101
Just edit properties of file pom.xml
<properties>
<java.version>1.8</java.version>
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
</properties>
Upvotes: 10
Reputation: 1044
This happening with 2.1.5.RELEASE. Add the following entry to your pom to fix that issue.
<properties>
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
</properties>
Why does change from Spring boot version 2.1.4 to 2.1.5 gives unknown configuration Maven error?
Upvotes: 26