Eug*_*gen 2 model-view-controller spring spring-roo pom.xml maven
我正在使用Spring Tool Suite(最新版本),每当我做New project - > Maven Project并选择maven-archetype-webapp作为我的原型时,我的pom文件中出现以下奇怪的错误.
Failure to transfer org.codehaus.plexus:plexus-components:pom:1.1.18 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-components:pom:1.1.18 from/to central (http://repo.maven.apache.org/maven2): No response received after 60000
Run Code Online (Sandbox Code Playgroud)
此外,这是非常简短的生成的pom.xml文件
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>Tset</groupId>
<artifactId>Tset</artifactId>
<packaging>war</packaging>
<version>0.0.1-SNAPSHOT</version>
<name>Tset Maven Webapp</name>
<url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<finalName>Tset</finalName>
</build>
</project>
Run Code Online (Sandbox Code Playgroud)
我是这些人的新手,所以我可能会错过一些明显的东西.
我通过从ROO生成的新项目中获取POM文件来解决它,但我真的很好奇是什么导致了这个以及我如何解决它.
根据我的经验,当maven下载或者当maven试图下载这个人工制品或出于任何原因没有互联网连接时,有时会发生这种情况.
尝试删除.m2目录中的工件,例如删除文件夹C:\Users\yourname\.m2\repository\org\codehaus\plexus\plexus-components.