Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

POM error: Failure to find org.springframework.boot

Tags:

I have been trying to setup a spring boot 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>
like image 250
EMinstrel Avatar asked Aug 09 '15 05:08

EMinstrel


People also ask

What does SpringApplication run () do?

SpringApplication. run(Classname. class, args) bootstraps a spring application as a stand-alone application from the main method. It creates an appropriate ApplicationContext instance and load beans.

How do I check my spring boot version?

In Spring boot application, you can easily obtain the info by altering the Spring Boot Maven/Gradle plugin configuration to generate the build. properties file and then accessing it through BuildProperties object.


2 Answers

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.

like image 142
Sanjay Avatar answered Sep 28 '22 08:09

Sanjay


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.

like image 44
Akhil S Kamath Avatar answered Sep 28 '22 10:09

Akhil S Kamath