我们使用Nexus代理远程maven存储库。除了与milton.io的maven存储库一起使用之外,它工作得很好。
如果我在不使用Nexus的情况下将存储库添加到我的maven settings.xml中,它可以很好地工作,工件会被正确拉取:
<repository>
<id>milton-repo</id>
<url>http://milton.io/maven/</url>
</repository>现在,如果我使用Nexus将存储库添加为“代理存储库”,它不起作用。Nexus无法提取所需的工件:
Failure to find io.milton:milton-server-ce:jar:2.6.4.0 in http://xxx:8180/nexus/content/groups/public was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced你知道为什么Nexus不能代理这个存储库吗?
编辑:如果我在Nexus日志中查看是否有以下内容:
2015-03-17 11:05:05,779+0100 INFO [ar-4-thread-4] admin org.sonatype.nexus.proxy.maven.routing.internal.RemoteScrapeStrategy - Not possible remote scrape of M2Repository(id=milton), no scraper succeeded.注意:代理存储库已正确添加到public组中。
发布于 2015-03-17 00:49:09
我看到这个服务器的性能非常差,这个请求花了将近一分钟的时间来处理:
http://milton.io/maven/io/milton/milton-server-ce/2.6.4.0/milton-server-ce-2.6.4.0.jar
因此,在Nexus中,您可能会遇到存储库的默认读取超时时间为20秒。
检查nexus.log文件,查看是否存在超时异常。如果有,那么在存储库的配置中增加"http request settings (optional)“中的超时时间。60秒的超时和3次重试似乎是可行的。
https://stackoverflow.com/questions/29079627
复制相似问题