`

maven执行报错resolution will not be reattempted until the update interval of nexus h

阅读更多
maven在执行过程中抛错:
引用
... was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced -> [Help 1]

原因就是有些jar包没有完全下载完成,在编译的时候找不到jar包。只需要在配置文件中增加一个更新策略<updatePolicy>always</updatePolicy>就可以了。
找到你的conf/setting.xml
引用

<profile>
  <id>nexus</id>
  <!--Enable snapshots for the built in central repo to direct -->
  <!--all requests to nexus via the mirror -->
  <repositories>
    <repository>
      <id>central</id>
      <url>http://central</url>
      <releases><enabled>true</enabled><updatePolicy>always</updatePolicy></releases>
      <snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
    </repository>
  </repositories>
<pluginRepositories>
    <pluginRepository>
      <id>central</id>
      <url>http://central</url>
      <releases><enabled>true</enabled><updatePolicy>always</updatePolicy></releases>
      <snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>
    </pluginRepository>
  </pluginRepositories>
</profile>

分享到:
评论
2 楼 lord_is_layuping 2015-11-24  
额,还是没解决,已经在我的maven配置(d:\tools\maven\apache-maven-3.0.4\conf\settings.xml)里面加了这两句:<snapshots><enabled>true</enabled><updatePolicy>always</updatePolicy></snapshots>


1 楼 107x 2014-11-06  
不错,3Q

相关推荐

Global site tag (gtag.js) - Google Analytics