maven:Project build error: Non-resolvable parent POM for model:maven01:0.0.1-SNAPSHOT
問題:
建立maven專案的時候,新增parent標籤,報錯誤:
Project build error: Non-resolvable parent POM for model:maven01:0.0.1-SNAPSHOT: Failure to transfer org.springframework.boot:spring-boot-starter-parent:pom:1.5.3.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.3.RELEASE from/to central (https://repo.maven.apache.org/maven2): connect timed out and 'parent.relativePath' points at wrong local POM
解決:
maven使用國內代理————阿里映象
參考部落格:http://www.cnblogs.com/littleatp/p/6002289.html
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<!--<mirrorOf>central</mirrorOf> -->
<mirrorOf>*</mirrorOf>
</mirror>
不可以的嘗試這個:
<mirror> <id>alimaven</id> <mirrorOf>central</mirrorOf> <name>aliyun maven</name> <url>http://maven.aliyun.com/nexus/content/repositories/central/</url> </mirror>