首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Sonatype Nexus:无法代理http://milton.io/maven/

Sonatype Nexus:无法代理http://milton.io/maven/
EN

Stack Overflow用户
提问于 2015-03-16 22:41:45
回答 1查看 730关注 0票数 1

我们使用Nexus代理远程maven存储库。除了与milton.io的maven存储库一起使用之外,它工作得很好。

如果我在不使用Nexus的情况下将存储库添加到我的maven settings.xml中,它可以很好地工作,工件会被正确拉取:

代码语言:javascript
复制
<repository>
   <id>milton-repo</id>
   <url>http://milton.io/maven/</url>
</repository>

现在,如果我使用Nexus将存储库添加为“代理存储库”,它不起作用。Nexus无法提取所需的工件:

代码语言:javascript
复制
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日志中查看是否有以下内容:

代码语言:javascript
复制
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组中。

EN

回答 1

Stack Overflow用户

发布于 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次重试似乎是可行的。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/29079627

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档