Artifactory 从jcenter下载时出错
我们正在使用artifactory oss,从几天以来,我们在从jcenter存储库下载JAR时遇到了一些问题。并非所有下载都适用,原因也不清楚。下载时出现以下错误:Artifactory 从jcenter下载时出错,artifactory,bintray,jcenter,Artifactory,Bintray,Jcenter,我们正在使用artifactory oss,从几天以来,我们在从jcenter存储库下载JAR时遇到了一些问题。并非所有下载都适用,原因也不清楚。下载时出现以下错误: Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpa
Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
奇怪的是,我们试图从http源下载,而不是从https源下载,这与有效的认证是一致的
当查看日志时,我们可以看到有两种不同的下载方法,一种是“httpRepo”,它运行良好,另一种是“RemoteRepoBase”,但不清楚为什么有时使用一种,有时使用另一种
这是一个工作和非工作下载日志的剪报:
2018-05-22 16:03:25,928 [https-jsse-nio-8060-exec-6] [INFO ] (o.a.r.HttpRepo :414) - jcenter downloading http://jcenter.bintray.com/commons-lang/commons-lang/2.1/commons-lang-2.1.jar 202.85 KB
2018-05-22 16:03:25,992 [https-jsse-nio-8060-exec-6] [INFO ] (o.a.r.HttpRepo :427) - jcenter downloaded http://jcenter.bintray.com/commons-lang/commons-lang/2.1/commons-lang-2.1.jar 202.85 KB at 3,247.54 KB/sec
2018-05-22 16:03:52,322 [https-jsse-nio-8060-exec-12] [INFO ] (o.a.r.HttpRepo :414) - jcenter downloading http://jcenter.bintray.com/commons-lang/commons-lang/2.5/commons-lang-2.5.jar 272.65 KB
2018-05-22 16:03:52,662 [https-jsse-nio-8060-exec-12] [INFO ] (o.a.r.HttpRepo :427) - jcenter downloaded http://jcenter.bintray.com/commons-lang/commons-lang/2.5/commons-lang-2.5.jar 272.65 KB at 807.36 KB/sec
2018-05-22 16:03:57,121 [art-exec-6] [INFO ] (o.a.s.a.ArchiveIndexerImpl:145) - Indexing archive: jcenter-cache:commons-lang/commons-lang/2.1/commons-lang-2.1.jar
2018-05-22 16:03:57,328 [art-exec-6] [INFO ] (o.a.s.a.ArchiveIndexerImpl:145) - Indexing archive: jcenter-cache:commons-lang/commons-lang/2.5/commons-lang-2.5.jar
2018-05-22 16:07:58,243 [https-jsse-nio-8060-exec-7] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.6/commons-lang-2.6.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:10,319 [https-jsse-nio-8060-exec-7] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.6/commons-lang-2.6.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:13,255 [https-jsse-nio-8060-exec-12] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.6/commons-lang-2.6.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:13,874 [https-jsse-nio-8060-exec-7] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.6/commons-lang-2.6.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.6/commons-lang-2.6.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:22,943 [https-jsse-nio-8060-exec-4] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.3/commons-lang-2.3.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.3/commons-lang-2.3.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:35,290 [https-jsse-nio-8060-exec-5] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.3/commons-lang-2.3.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.3/commons-lang-2.3.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
2018-05-22 16:08:52,519 [https-jsse-nio-8060-exec-12] [WARN ] (o.a.r.RemoteRepoBase:433) - jcenter: Error in getting information for 'commons-lang/commons-lang/2.2/commons-lang-2.2.jar' (Failed retrieving resource from http://jcenter.bintray.com/commons-lang/commons-lang/2.2/commons-lang-2.2.jar: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target).
认证路径错误很可能是由于通过SSL重定向到Bintray的CDN,而不管远程repo URL是http而不是https。如果您尝试使用cURL拉取此文件,您将看到它确实重定向到 服务器证书看起来很好,也就是说,我个人能够通过我的Artifactory实例和使用cURL(w/o)查看任何SSL验证错误来提取文件 也就是说,我们通常会看到这种类型的错误是由于以下几个主要原因造成的:
我希望这有帮助认证路径错误很可能是由于通过SSL重定向到Bintray的CDN,而不管远程回购URL是http而不是https。如果您尝试使用cURL拉取此文件,您将看到它确实重定向到 服务器证书看起来很好,也就是说,我个人能够通过我的Artifactory实例和使用cURL(w/o)查看任何SSL验证错误来提取文件 也就是说,我们通常会看到这种类型的错误是由于以下几个主要原因造成的:
我希望这会有所帮助现在我们通过删除jcenter并使用mavenlink解决了这个问题。但是当查看您的描述和我们的设置时,我们可能会遇到类似选项1的问题。稍后我们将对此问题有更详细的了解。@DannyvanZunderd欢迎联系support@jfrog.com如果你无法弄清这件事的真相。我们不希望您仅仅因为以下原因而不使用Jcenter:))因为现在我们通过删除Jcenter并使用mavenlink解决了这个问题。但是当查看您的描述和我们的设置时,我们可能会遇到类似选项1的问题。稍后我们将对此问题有更详细的了解。@DannyvanZunderd欢迎联系support@jfrog.com如果你无法弄清这件事的真相。我们不希望您仅仅因为以下原因而不使用Jcenter:))