第一次用 Spring Starter Project 创建一个Spring应用时,POM 文件报错:

Project build error: Non-resolvable parent POM for com.example:demo-1:0.0.1-SNAPSHOT: Failure to transfer org.springframework.boot:spring-boot-starter-parent:pom:1.5.4.RELEASE from https://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. Original error: Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom:1.5.4.RELEASE from/to central (https://repo.maven.apache.org/maven2): repo.maven.apache.org: nodename nor servname provided, or not known and 'parent.relativePath' points at no local POM

解决方法:

参考stack overflow:

I've also encountered a lot of error when creating a new STS project for the first time. This seems to be happen only if I don't have any Maven repository or haven't launch/use Maven before. In my case, I solve this by launching Maven command from command line manually. Try to 'cd' to the project directory that contains pom.xml and call mvn that comes with STS from there.

cd c:\users\name\sts-projects\projectname
c:\programs\springsource\apache-maven-3.0.3\bin\mvn compile
Then, open STS, right click on project name, select 'Maven', 'Update Project...' Select on 'Force Update of Snapshots/Releases'. Don't select 'Offline'.

即打开终端,进入出错项目的根目录,然后使用 maven bin 目录下的 mvn 编译一下,完成之后右键项目 Maven——Update Project 即可。

Failure to transfer org.springframework.boot:spring-boot-starter-parent:pom:2.0.1.RELEASE from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempt的更多相关文章

  1. Failure to transfer org.apache.maven:maven-archiver:pom:2.5 from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval o

    pom.xml报错: Failure to transfer org.apache.maven:maven-archiver:pom:2.5 from https://repo.maven.apach ...

  2. Failure to transfer org.apache.maven:maven-archiver:pom:2.5 from http://repo.maven.apache.org/ maven2 was cached in the local repository, resolution will not be reattempted until the update interv

    Failure to transfer org.apache.maven:maven-archiver:pom:2.5 from http://repo.maven.apache.org/  mave ...

  3. spark mllib配置pom.xml错误 Multiple markers at this line Could not transfer artifact net.sf.opencsv:opencsv:jar:2.3 from/to central (https://repo.maven.apache.org/maven2): repo.maven.apache.org

    刚刚spark mllib,在maven repository网站http://mvnrepository.com/中查询mllib后得到相关库的最新dependence为: <dependen ...

  4. 二、Spring Boot 中maven中dependencies所有的jar包都报红,install报错(https://repo.maven.apache.org/maven2): Not authorized , ReasonPhrase:Authorizatio

    问题一:现象:打开SpringBoot项目后,所有依赖包都报红色波浪线 1.install报错(https://repo.maven.apache.org/maven2): Not authorize ...

  5. Failure to find xxx in xxx was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced @ xxx

    问题: 在linux服务器上使用maven编译war时报错: 16:41:35 [FATAL] Non-resolvable parent POM for ***: Failure to find * ...

  6. Maven-010-maven 编译报错:Failure to ... in ... was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced.

    今晚在编译 maven 项目的时候,命令行报错,出现 Failure to ... in ... 类似错误,详细的错误信息如下所示: [INFO] -------------------------- ...

  7. Failure to transfer org.springframework:spring-jcl:jar:5.0.7.RELEASE from

    错误信息: Failure to transfer org.springframework.boot:spring-boot-maven-plugin:pom:1.5.4.RELEASE from h ...

  8. Failed to transfer file: http://repo.maven.apache.org/maven2/xpp3/xpp3_min/1.1.4c/xpp3_min-1.1.4c.jar

    解决办法:maven的配置文件settings.xml中添加mirror地址 <mirror>       <id>alimaven</id>       < ...

  9. maven build失败 (Failure to find io.renren:renren-security:pom:3.2.0 in http://maven.aliyun.com/nexus/content/groups/public/ was cached in the local repository...)

      今天mvn clean package一个子工程(renren-admin)时报错: Failed to execute goal on project renren-admin: Could n ...

随机推荐

  1. (笔记)Linux线程编译undefined reference to 'pthread_create'

    在使用线程时,使用gcc或arm-linux-gcc编译时,会出现错误:undefined reference to 'pthread_create' 主要是以下两种原因: 1.#include &l ...

  2. 使用Maven清理项目

    在基于Maven的项目中,很多缓存输出在“target”文件夹中.如果想建立项目部署,必须确保清理所有缓存的输出,从面能够随时获得最新的部署. 要清理项目缓存的输出,发出以下命令: mvn clean ...

  3. Eclispe IDE集成Maven

    Eclipse提供了一个很好的插件m2eclipse 无缝将Maven和Eclipse集成在一起. m2eclipse一些特点如下 您可以从Eclipse运行Maven目标. 可以使用其自己的控制台查 ...

  4. mac命令行启动tomcat

    一.修改授权 进入tomcat的bin目录,修改授权 ➜ bin pwd /Users/yp/Documents/workspace/apache-tomcat-7.0.68/bin ➜ bin su ...

  5. 嵌入式开发之hi3519---spi nor flash启动

    author:pkf qq:1327706646 1.官方hi3519默认是硬件3byte 地址模式,配置完ddr始终后,sdkv100.020是可以支持正常启动,用到低位16Mflash内存 2.如 ...

  6. Linux CPU Load Average

    理解Linux系统负荷 LINUX下CPU Load Average的一点研究 Linux load average负载量分析与解决思路 Understanding Linux CPU Load - ...

  7. (实用)使用unetbootin制作Linux的U盘启动盘

    本文介绍在Ubuntu(基于Debian的操作相同)使用unetbootin将Linux操作系统的安装镜像烧录到U盘中,使得U盘成为安装介质.当然,windows系统下也同样可以使用该软件的相应版本. ...

  8. 混合线路接入时,360、QQ管家等测速显示电信IP或任意线路的IP

    最近很多人QQ上问我,我有电信.联通接入,用户测速的时候有的时候显示联通的IP,可是我想让他显示为电信的IP,怎么办? 3年前开始使用联通的线路时,就这样设置了,有些人还拿这个设置当宝贝了???? 其 ...

  9. iOS:获取 NSDate 的年

    NSDate *currentDate = [NSDate date]; NSCalendar* calendar = [NSCalendar currentCalendar]; NSDateComp ...

  10. C#实现http协议支持上传下载文件的GET、POST请求

    C#实现http协议支持上传下载文件的GET.POST请求using System; using System.Collections.Generic; using System.Text; usin ...