简体   繁体   English

maven clean install - 无法在项目 myGoogleAppEngine 上执行目标

[英]maven clean install - Failed to execute goal on project myGoogleAppEngine

I've created a maven project.我创建了一个 Maven 项目。 Before, in my pom.xml, I used the spring version 2.5.6 and now, I change the version number of spring to use the 3.1.0.RELEASE.之前,在我的 pom.xml 中,我使用的是 spring 版本 2.5.6,现在,我将 spring 的版本号更改为使用 3.1.0.RELEASE。

To update the different dependencies and update the different jar in my WEB-INF/lib, I used the following command line :'mvn clean install' and I've the following error要更新不同的依赖项并更新我的 WEB-INF/lib 中的不同 jar,我使用了以下命令行:'mvn clean install' 并且出现以下错误

[WARNING] The POM for org.springframework:spring:jar:3.1.0.RELEASE is missing, no dependency information available
[INFO] BUILD FAILURE
[INFO] Total time: 0.847s
[INFO] Finished at: Sat Dec 07 13:49:20 CET 2013
[INFO] Final Memory: 4M/15M
[ERROR] Failed to execute goal on project myGoogleAppEngine: Could not resolve dependencies for project com.application:myGoogleAppEngine:war:0.0.1-SNAPSHOT: Failure to find org.springframework:spring:jar:3.1.0.RELEASE in 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 -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException

Do you have any solutions ?你有什么解决办法吗?

Thank you谢谢

A part of my pom.xml我的 pom.xml 的一部分

<properties>
    <appengine.app.version>1</appengine.app.version>
    <appengine.target.version>1.8.0</appengine.target.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <org.springframework.version>3.1.0.RELEASE</org.springframework.version>
</properties>

<dependencies>
     <!-- Spring framework -->
     <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring</artifactId>
          <version>${org.springframework.version}</version>
     </dependency>

     <!-- Spring MVC framework -->
     <dependency>
           <groupId>org.springframework</groupId>
           <artifactId>spring-webmvc</artifactId>
           <version>${org.springframework.version}</version>
     </dependency>

     <dependency>
           <groupId>org.springframework</groupId>
           <artifactId>spring-context</artifactId>
           <version>${org.springframework.version}</version>
     </dependency>
</dependencies>

My WEB-INF/lib我的 WEB-INF/lib

-spring-2.5.6.jar
-spring-aop-3.1.0.RELEASE.jar
-spring-asm-3.1.0.RELEASE.jar
-spring-beans-2.5.6.jar
-spring-beans-3.1.0.RELEASE.jar
-spring-context-2.5.6.jar
-spring-context-3.1.0.RELEASE.jar
-spring-context-support-2.5.6.jar
-spring-context-support-3.1.0.RELEASE.jar
-spring-core-2.5.6.jar
-spring-core-3.1.0.RELEASE.jar
-spring-expression-3.1.0.RELEASE.jar
-spring-web-2.5.6.jar
-spring-web-3.1.0.RELEASE.jar
-spring-webmvc-2.5.6.jar
-spring-webmvc-3.1.0.RELEASE.jar
-...

If you are going to upgrade your Spring version, upgrade it to the latest v3: 3.2.5.RELEASE as outlined in the Maven mvn repository: http://mvnrepository.com/artifact/org.springframework如果您要升级 Spring 版本,请将其升级到最新的 v3: 3.2.5.RELEASE ,如 Maven mvn 存储库中所述: http : 3.2.5.RELEASE

However, your problem is here:但是,您的问题在这里:

<dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring</artifactId>
      <version>${org.springframework.version}</version>
 </dependency>

There is no artifactId 'spring' it should be spring-core .没有 artifactId 'spring' 它应该是spring-core

There is no dependancy named org.springframework:spring:3.1.0.RELEASE .没有名为org.springframework:spring:3.1.0.RELEASE依赖org.springframework:spring:3.1.0.RELEASE The last jar that was available with this groupId/artifactId combination was for version 2.5.6.SEC03 .此 groupId/artifactId 组合可用的最后一个 jar 适用于版本2.5.6.SEC03

You will have to change this dependency and re-name it to spring-core instead of spring您必须更改此依赖项并将其重命名为spring-core而不是spring

<dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-core</artifactId>
      <version>${org.springframework.version}</version>
</dependency>

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Maven全新安装无法在项目上执行目标 - Maven clean install failed to execute goal on project maven:无法执行项目目标 - maven: Failed to execute goal on project 无法在Maven上执行项目目标 - Failed to execute goal on project on the maven 如何解决“无法在项目上执行目标 org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean (default-clean)”? - How to solve "Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean (default-clean) on project"? 运行Maven项目的多个“实例”-无法执行目标org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean - Running multiple 'instances' of maven project - Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean Netbeans Maven 无法在项目上执行目标 - Netbeans Maven Failed to execute goal on project Maven 全新安装:无法执行目标 org.apache.maven.plugins:maven-resources-plugin:3.20。 - Maven clean install: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources Maven - 未能执行目标 org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean - Maven - Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.4.1:clean Maven-无法执行目标 - Maven - Failed to execute goal MAVEN 错误:“无法执行目标 org.apache.maven.plugins:maven-clean-plugin:3.2.0:clean” - MAVEN ERROR : "Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:3.2.0:clean "
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM