我无法将我的spring框架版本从3.0.1更新到3.1.3。
这是我在mvn安装时遇到的错误。
Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.core/3.1.3.RELEASE/org.springframework.core-3.1.3.RELEASE.pom Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.core/3.1.3.RELEASE/org.springframework.core-3.1.3.RELEASE.pom [WARNING] The POM for org.springframework:org.springframework.core:jar:3.1.3.RELEASE is missing, no dependency information available Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-tx/maven-metadata.xml Downloading: http://repo1.maven.org/maven2/org/springframework/spring-tx/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-tx/maven-metadata.xml (2 KB at 3.5 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-tx/maven-metadata.xml (2 KB at 1.0 KB/sec) Downloading: http://repo1.maven.org/maven2/org/springframework/spring-context/maven-metadata.xml Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-context/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-context/maven-metadata.xml (2 KB at 5.9 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-context/maven-metadata.xml (3 KB at 3.6 KB/sec) Downloading: http://repo1.maven.org/maven2/org/springframework/spring-beans/maven-metadata.xml Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-beans/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-beans/maven-metadata.xml (2 KB at 7.8 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-beans/maven-metadata.xml (2 KB at 2.2 KB/sec) Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-core/maven-metadata.xml Downloading: http://repo1.maven.org/maven2/org/springframework/spring-core/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-core/maven-metadata.xml (2 KB at 4.7 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-core/maven-metadata.xml (3 KB at 2.8 KB/sec) Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-expression/maven-metadata.xml Downloading: http://repo1.maven.org/maven2/org/springframework/spring-expression/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-expression/maven-metadata.xml (759 B at 4.4 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-expression/maven-metadata.xml (831 B at 1.2 KB/sec) Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-beans/maven-metadata.xml Downloading: http://repo1.maven.org/maven2/org/springframework/spring-beans/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-beans/maven-metadata.xml (2 KB at 8.0 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-beans/maven-metadata.xml (2 KB at 2.2 KB/sec) Downloading: http://repo1.maven.org/maven2/org/springframework/spring-tx/maven-metadata.xml Downloading: http://repo.springsource.org/libs-release/org/springframework/spring-tx/maven-metadata.xml Downloaded: http://repo1.maven.org/maven2/org/springframework/spring-tx/maven-metadata.xml (2 KB at 4.6 KB/sec) Downloaded: http://repo.springsource.org/libs-release/org/springframework/spring-tx/maven-metadata.xml (2 KB at 1.7 KB/sec) Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.beans/3.1.3.RELEASE/org.springframework.beans-3.1.3.RELEASE.pom Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.beans/3.1.3.RELEASE/org.springframework.beans-3.1.3.RELEASE.pom [WARNING] The POM for org.springframework:org.springframework.beans:jar:3.1.3.RELEASE is missing, no dependency information available Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.context/3.1.3.RELEASE/org.springframework.context-3.1.3.RELEASE.pom Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.context/3.1.3.RELEASE/org.springframework.context-3.1.3.RELEASE.pom [WARNING] The POM for org.springframework:org.springframework.context:jar:3.1.3.RELEASE is missing, no dependency information available Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.core/3.1.3.RELEASE/org.springframework.core-3.1.3.RELEASE.jar Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.beans/3.1.3.RELEASE/org.springframework.beans-3.1.3.RELEASE.jar Downloading: http://repo.springsource.org/libs-release/org/springframework/org.springframework.context/3.1.3.RELEASE/org.springframework.context-3.1.3.RELEASE.jar Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.core/3.1.3.RELEASE/org.springframework.core-3.1.3.RELEASE.jar Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.beans/3.1.3.RELEASE/org.springframework.beans-3.1.3.RELEASE.jar Downloading: http://repo1.maven.org/maven2/org/springframework/org.springframework.context/3.1.3.RELEASE/org.springframework.context-3.1.3.RELEASE.jar [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 16.128s [INFO] Finished at: Sat Dec 08 22:16:08 GMT+05:30 2012 [INFO] Final Memory: 4M/81M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal on project commons: Could not resolve dependencies for project HFC:commons:jar:1.0: The following artifacts could not be resolved: org.springframework:org.springframework.core:jar:3.1.3.RELEASE, org.springframework:org.springframework.beans:jar:3.1.3.RELEASE, org.springframework:org.springframework.context:jar:3.1.3.RELEASE: Could not find artifact org.springframework:org.springframework.core:jar:3.1.3.RELEASE in repository.springframework.maven.release (http://repo.springsource.org/libs-release) -> [Help 1]
我的pom.xml就像this
我在这里缺少什么。?
答案 0 :(得分:1)
看起来你使用了错误的artifactId。
您应该使用:
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>3.1.3.RELEASE</version>
</dependency>
请参阅here。