关于MAVEN 问题

来源:互联网 发布:阿里云怎么赚钱 编辑:程序博客网 时间:2024/06/08 10:05

项目导入之后 pom 文件报错,如下:Failure to transfer org.codehaus.plexus:plexus-io:pom:2.0.1 from http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer artifact org.codehaus.plexus:plexus-io:pom:2.0.1 from/to central (http://repo.maven.apache.org/maven2): connection timed out to http://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-io/2.0.1/plexus-io-2.0.1.pom



经仔细研读报错日志可知道:plexus-io:pom:2.0.1不能从 http://repo.maven.apache.org/maven2下载到,原因是本地仓库中已存在它的缓存,解决方法就是在本地仓库下找到(org.codehaus.plexus:plexus-io:pom:2.0.1)并且删除掉或者强制更新即可;


另外要知道maven 在根据pom引用jar包时,如果本地已经存在相应jar包,即使jar包是有缺陷的,也不会从maven的服务器端下载jar包,除非将有缺陷的jar包 删除掉,才会重现下载!  希望会对大家有帮助!!!


0 0
原创粉丝点击