2015-08-30 66 views
1

我有一個Maven的春季啓動項目STS中運行它建立精細:Maven構建錯誤在升級到新的Spring引導版本

<parent> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-parent</artifactId> 
     <version>1.2.5.RELEASE</version> 
     <relativePath /> <!-- lookup parent from repository --> 
    </parent> 

更新春天啓動的上述版本1.3.0.M4結果在:

[FATAL] Non-resolvable parent POM: Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom:1.3.0.M4 from/to IWS_Repo (https://build-devtools.fw.net/artifactory/repo/): sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target and 'parent.relativePath' points at no local POM @ line 18, column 10 

我在STS和命令行中都試過:同樣的錯誤。

可能是什麼問題?

回答

5

不像春天啓動Spring Boot里程碑不會發布到Maven Central。他們只發布到repo.spring.io。

要從1.2.5.RELEASE(可從Maven Central獲得)升級到1.3.0.M4(不是),您需要爲您的pom添加一些額外的配置,以便Maven知道查看repo.spring.io的里程碑庫:

<repositories> 
    <repository> 
     <id>spring-milestones</id> 
     <url>https://repo.spring.io/milestone</url> 
    </repository> 
</repositories> 
<pluginRepositories> 
    <pluginRepository> 
     <id>spring-milestones</id> 
     <url>https://repo.spring.io/milestone</url> 
    </pluginRepository> 
</pluginRepositories> 
+0

安迪,你會碰巧知道一些很好的閱讀材料,說明如何在沒有提供正確的回購時發生Maven絆跌(??)的證書的低級解析?謝謝!! –

+0

這可能是一個很好的起點:https://maven.apache.org/guides/mini/guide-repository-ssl.html –

0

好像是你有您的倉庫證書問題:

sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path 

https://build-devtools.fw.net/artifactory/repo/

嘗試直接將Maven的中央:>http://repo1.maven.org/maven/

http://maven.apache.org/guides/introduction/introduction-to-repositories.html

+0

爲什麼當我更新父級時證書突然無效? –

+0

分享你的整個pom.xml文件。 –