28

I have been trying to setup a Springboot project but am getting an error. I researched and tried various options but no luck so far. Any help would be appreciated.

Project build error:

Non-resolvable parent POM: Failure to find org.springframework.boot:spring-boot-starter-parent:pom:1.1.3.RELEASE in http://repo.maven.apache.org/ maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced and 'parent.relativePath' points at no local POM

POM.XML (error in parent tag)

<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> <groupId>com.programmingfree</groupId> <artifactId>spring-data-rest-angular</artifactId> <version>0.0.1-SNAPSHOT</version> <name>Spring Data Rest + AngularJS</name> <description>This project uses Spring Data Rest and AngularJS to perform CRUD operations against MySql Database.</description> <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.1.3.RELEASE</version> <relativePath/> <!-- lookup parent from repository --> </parent> <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-thymeleaf</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-jpa</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-rest</artifactId> </dependency> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> </dependency> </dependencies> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <start-class>com.programmingfree.springservice.Application</start-class> <java.version>1.7</java.version> </properties> <build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> </plugin> </plugins> </build> </project>

2
  • Try 1.2.5.RELEASE for version is it's not the hard requirement. Commented Aug 9, 2015 at 5:54
  • Updated to 1.2.5 as well... Commented Aug 9, 2015 at 6:45

9 Answers 9

43

There might have been some intermittent Internet issue or something. I was facing the same problem yesterday. Updating the the project (On STS or Eclipse, right click on the project and Maven -> Update project -> tick everything except Offline) after sometime fixed it.

Sign up to request clarification or add additional context in comments.

2 Comments

I think ill switch back to intellij ...only a few hours with eclipse and all this silly configuration stuff is so annoying
switch to intellij and gradle and you'll be much happier.
7

I got a similar exception while maven-build process.

If you are using a proxy network - update settings.xml in your maven folder

../apache-maven-3.2.3\conf/settings.xml 

settings.xml content

<proxies> <proxy> <id>...</id> <active>true</active> <protocol>http</protocol> <username>....</username> <password>....</password> <host>....</host> <port>....</port> <nonProxyHosts>local.net|some.host.com</nonProxyHosts> </proxy> </proxies> project(right click) -> Maven -> Update project -> tick everything (except OfflinI) 

I got the issue resolved.

2 Comments

This must be set if you are under a proxy
@AdinduStevens Thanks for the update, but I have mentioned same in second sentence in the answer.
4

Check Settings.xml file mapping in Eclipse Window->Project->Maven->User Settings, It should be default xml provided from Maven config folder. You might have configured your own xml file which suites for you project needs.

1 Comment

You mean preferences- Window -> Preferences -> Maven -> User Settings
3

I tried few things 1. set up the settings.xml file 2. Update maven project option for eclipse didin't solved my issue 3. Run the following command manually , my issue got resolved

mvn dependency:purge-local-repository 

1 Comment

this voodoo is why i finally went to gradle for new projects. But still have old mvn projects. thanks for tip!
1

Change the version of springboot to the next version or previous version and do update the pom file. It worked for me. I had issue with spring boot 2.1.5 so I changed it to 2.1.4 in the pom file and updated it. It worked.

Comments

1

Delete the repository in .m2 folder, perform Maven install and update the project , it worked for me.

Attaching pom.xml file here.

<?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 https://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.5.8</version> <relativePath/> <!-- lookup parent from repository --> </parent> <groupId>com.springbootproject</groupId> <artifactId>SpringBootRestServices</artifactId> <version>0.0.1-SNAPSHOT</version> <name>SpringBootRestServices</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-data-jpa</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </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> 

Comments

0

This happened because the STS is not able to find the Parent POM location. You can go to Command Prompt and exectute mvn -x to get location of your Global and Local Settings.xml file.Go to Window-> Preferences-> Maven, and then set the locations for both Gloabal and User level with the above command locations. Then right click on the project and Goto Maven-> UpdateProject. This will solve the problem

Comments

0

<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> <groupId>com.programmingfree</groupId> <artifactId>spring-data-rest-angular</artifactId> <version>0.0.1-SNAPSHOT</version> <name>Spring Data Rest + AngularJS</name> <description>This project uses Spring Data Rest and AngularJS to perform CRUD operations against MySql Database.</description> <parent>	<groupId>org.springframework.boot</groupId>	<artifactId>spring-boot-starter-parent</artifactId>	<version>1.1.3.RELEASE</version>	<relativePath/> <!-- lookup parent from repository -->	</parent> <dependencies>	<dependency>	<groupId>org.springframework.boot</groupId>	<artifactId>spring-boot-starter-thymeleaf</artifactId>	</dependency>	<dependency>	<groupId>org.springframework.boot</groupId>	<artifactId>spring-boot-starter-data-jpa</artifactId>	</dependency>	<dependency>	<groupId>org.springframework.boot</groupId>	<artifactId>spring-boot-starter-data-rest</artifactId>	</dependency>	<dependency>	<groupId>mysql</groupId>	<artifactId>mysql-connector-java</artifactId>	</dependency>	</dependencies>	<properties>	<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>	<start-class>com.programmingfree.springservice.Application</start-class>	<java.version>1.7</java.version>	</properties>	<build>	<plugins>	<plugin>	<groupId>org.springframework.boot</groupId>	<artifactId>spring-boot-maven-plugin</artifactId>	</plugin>	</plugins>	</build> </project>

1 Comment

A bit explanation would be helpful
-2

I am facing this issue as i am writing this answer. Well seems my office internet settings has restricted downloading content using tools like eclipse. I have faced issues with multiple tools like eclipse, youtube-dl. When I use my mobile internet for my laptop it works fine. That means it has got to do something with the internet settings.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.