Maven目标清理安装错误

时间:2017-04-03 15:56:18

标签: maven pom.xml

我试图让目标成功执行,但是它给出了错误,任何人都可以提出可能存在的问题吗?

我将下面的依赖项添加到我的POM xml中,然后将下面的clean install抛出错误:

<dependency>
  <groupId>org.apache.poi</groupId>
  <artifactId>poi</artifactId>
  <version>3.14</version>
</dependency>

<dependency>
  <groupId>org.apache.poi</groupId>
  <artifactId>poi-ooxml</artifactId>
  <version>3.14</version>
</dependency>

<dependency>
  <groupId>emma</groupId>
  <artifactId>emma</artifactId>
  <version>2.1.5320</version>
</dependency>


<dependency>
  <groupId>org.apache.wink</groupId>
  <artifactId>wink-client</artifactId>
  <version>1.4</version>
</dependency>

<!-- https://mvnrepository.com/artifact/org.apache.axis/axis -->
<dependency>
  <groupId>org.apache.axis</groupId>
  <artifactId>axis</artifactId>
  <version>1.4</version>
</dependency>

<!-- https://mvnrepository.com/artifact/commons-discovery/commons-discovery -->
<dependency>
  <groupId>commons-discovery</groupId>
  <artifactId>commons-discovery</artifactId>
  <version>0.2</version>
</dependency>

<!-- https://mvnrepository.com/artifact/org.eclipse.birt.runtime.3_7_1/javax.wsdl -->
<dependency>
  <groupId>org.eclipse.birt.runtime.3_7_1</groupId>
  <artifactId>javax.wsdl</artifactId>
  <version>1.5.1</version>
</dependency>

<!-- https://mvnrepository.com/artifact/org.eclipse.equinox/org.apache.commons.logging -->
<dependency>
  <groupId>org.apache.commons</groupId>
  <artifactId>commons-logging</artifactId>
  <version>3.1</version>
</dependency>

<!-- https://mvnrepository.com/artifact/jaxrpc/jaxrpc -->
<dependency>
  <groupId>jaxrpc</groupId>
  <artifactId>jaxrpc</artifactId>
  <version>1.1</version>
</dependency>

错误:

[INFO] --- copy-maven-plugin:0.2.5:copy (Copy files to install folder) @ bpm_ui_testing ---
[WARNING] Error injecting: com.github.goldin.plugins.copy.CopyMojo
java.lang.NoClassDefFoundError: Lorg/sonatype/aether/RepositorySystem;
	at java.lang.Class.getDeclaredFields0(Native Method)
	at java.lang.Class.privateGetDeclaredFields(Class.java:2583)
	at java.lang.Class.getDeclaredFields(Class.java:1916)
	at com.google.inject.spi.InjectionPoint.getInjectionPoints(InjectionPoint.java:661)
	at com.google.inject.spi.InjectionPoint.forInstanceMethodsAndFields(InjectionPoint.java:366)
	at com.google.inject.internal.ConstructorBindingImpl.getInternalDependencies(ConstructorBindingImpl.java:165)
	at com.google.inject.internal.InjectorImpl.getInternalDependencies(InjectorImpl.java:612)
	at com.google.inject.internal.InjectorImpl.cleanup(InjectorImpl.java:568)
	at com.google.inject.internal.InjectorImpl.initializeJitBinding(InjectorImpl.java:554)
	at com.google.inject.internal.InjectorImpl.createJustInTimeBinding(InjectorImpl.java:877)
	at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive(InjectorImpl.java:798)
	at com.google.inject.internal.InjectorImpl.getJustInTimeBinding(InjectorImpl.java:281)
	at com.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImpl.java:213)
	at com.google.inject.internal.InjectorImpl.getProviderOrThrow(InjectorImpl.java:998)
	at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1031)
	at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:994)
	at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1044)
	at org.eclipse.sisu.space.AbstractDeferredClass.get(AbstractDeferredClass.java:48)
	at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86)
	at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:54)
	at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70)
	at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
	at org.eclipse.sisu.bean.BeanScheduler$Activator.onProvision(BeanScheduler.java:176)
	at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:126)
	at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
	at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68)
	at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:46)
	at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
	at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1059)
	at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
	at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:36)
	at org.eclipse.sisu.inject.LazyBeanEntry.getValue(LazyBeanEntry.java:81)
	at org.eclipse.sisu.plexus.LazyPlexusBean.getValue(LazyPlexusBean.java:51)
	at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:263)
	at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:255)
	at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:546)
	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:121)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
	at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:197)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: java.lang.ClassNotFoundException: org.sonatype.aether.RepositorySystem
	at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
	... 58 more
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] java ............................................... SUCCESS [  3.624 s]
[INFO] bpm_ui_testing ..................................... FAILURE [01:58 min]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 02:02 min
[INFO] Finished at: 2017-04-03T21:04:57+05:30
[INFO] Final Memory: 73M/690M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.goldin:copy-maven-plugin:0.2.5:copy (Copy files to install folder) on project bpm_ui_testing: Execution Copy files to install folder of goal com.github.goldin:copy-maven-plugin:0.2.5:copy failed: A required class was missing while executing com.github.goldin:copy-maven-plugin:0.2.5:copy: Lorg/sonatype/aether/RepositorySystem;
[ERROR] -----------------------------------------------------
[ERROR] realm =    plugin>com.github.goldin:copy-maven-plugin:0.2.5
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/C:/Users/kancharp/.m2/repository/com/github/goldin/copy-maven-plugin/0.2.5/copy-maven-plugin-0.2.5.jar
[ERROR] urls[1] = file:/C:/Users/kancharp/.m2/repository/com/github/goldin/maven-common/0.2.5/maven-common-0.2.5.jar
[ERROR] urls[2] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-component-annotations/1.5.5/plexus-component-annotations-1.5.5.jar
[ERROR] urls[3] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/plexus/plexus-sec-dispatcher/1.3/plexus-sec-dispatcher-1.3.jar
[ERROR] urls[4] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[ERROR] urls[5] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/aether/aether-util/1.13.1/aether-util-1.13.1.jar
[ERROR] urls[6] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/file-management/1.2.1/file-management-1.2.1.jar
[ERROR] urls[7] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-shared-io/1.1/maven-shared-io-1.1.jar
[ERROR] urls[8] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-filtering/1.0/maven-filtering-1.0.jar
[ERROR] urls[9] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/plexus/plexus-build-api/0.0.4/plexus-build-api-0.0.4.jar
[ERROR] urls[10] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-common-artifact-filters/1.4/maven-common-artifact-filters-1.4.jar
[ERROR] urls[11] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus/3.1/plexus-3.1.pom
[ERROR] urls[12] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-containers/1.5.5/plexus-containers-1.5.5.pom
[ERROR] urls[13] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-interpolation/1.15/plexus-interpolation-1.15.jar
[ERROR] urls[14] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.jar
[ERROR] urls[15] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-digest/1.1/plexus-digest-1.1.jar
[ERROR] urls[16] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/groovy/groovy-all/1.8.6/groovy-all-1.8.6.jar
[ERROR] urls[17] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/gmaven/gmaven-mojo/1.4/gmaven-mojo-1.4.jar
[ERROR] urls[18] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/gmaven/runtime/gmaven-runtime-api/1.4/gmaven-runtime-api-1.4.jar
[ERROR] urls[19] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/gmaven/feature/gmaven-feature-api/1.4/gmaven-feature-api-1.4.jar
[ERROR] urls[20] = file:/C:/Users/kancharp/.m2/repository/org/apache/ant/ant/1.8.3/ant-1.8.3.jar
[ERROR] urls[21] = file:/C:/Users/kancharp/.m2/repository/org/apache/ant/ant-launcher/1.8.3/ant-launcher-1.8.3.jar
[ERROR] urls[22] = file:/C:/Users/kancharp/.m2/repository/org/apache/ant/ant-commons-net/1.8.3/ant-commons-net-1.8.3.jar
[ERROR] urls[23] = file:/C:/Users/kancharp/.m2/repository/commons-net/commons-net/1.4.0/commons-net-1.4.0.jar
[ERROR] urls[24] = file:/C:/Users/kancharp/.m2/repository/oro/oro/2.0.8/oro-2.0.8.jar
[ERROR] urls[25] = file:/C:/Users/kancharp/.m2/repository/org/apache/ant/ant-jsch/1.8.3/ant-jsch-1.8.3.jar
[ERROR] urls[26] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/mojo/versions-maven-plugin/1.3.1/versions-maven-plugin-1.3.1.jar
[ERROR] urls[27] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/wagon/wagon-file/1.0-beta-2/wagon-file-1.0-beta-2.jar
[ERROR] urls[28] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-i18n/1.0-beta-7/plexus-i18n-1.0-beta-7.jar
[ERROR] urls[29] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/woodstox/wstx-asl/3.2.7/wstx-asl-3.2.7.jar
[ERROR] urls[30] = file:/C:/Users/kancharp/.m2/repository/stax/stax-api/1.0.1/stax-api-1.0.1.jar
[ERROR] urls[31] = file:/C:/Users/kancharp/.m2/repository/org/gcontracts/gcontracts-core/1.2.5/gcontracts-core-1.2.5.jar
[ERROR] urls[32] = file:/C:/Users/kancharp/.m2/repository/asm/asm/3.2/asm-3.2.jar
[ERROR] urls[33] = file:/C:/Users/kancharp/.m2/repository/log4j/log4j/1.2.16/log4j-1.2.16.jar
[ERROR] urls[34] = file:/C:/Users/kancharp/.m2/repository/com/github/goldin/gcommons/0.5.4/gcommons-0.5.4.jar
[ERROR] urls[35] = file:/C:/Users/kancharp/.m2/repository/org/slf4j/slf4j-log4j12/1.6.4/slf4j-log4j12-1.6.4.jar
[ERROR] urls[36] = file:/C:/Users/kancharp/.m2/repository/org/apache/commons/commons-exec/1.1/commons-exec-1.1.jar
[ERROR] urls[37] = file:/C:/Users/kancharp/.m2/repository/de/schlichtherle/truezip/6.8.2/truezip-6.8.2.jar
[ERROR] urls[38] = file:/C:/Users/kancharp/.m2/repository/org/springframework/spring-core/3.1.1.RELEASE/spring-core-3.1.1.RELEASE.jar
[ERROR] urls[39] = file:/C:/Users/kancharp/.m2/repository/org/springframework/spring-asm/3.1.1.RELEASE/spring-asm-3.1.1.RELEASE.jar
[ERROR] urls[40] = file:/C:/Users/kancharp/.m2/repository/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.jar
[ERROR] urls[41] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/sisu/sisu-guice/3.1.1/sisu-guice-3.1.1.jar
[ERROR] urls[42] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/sisu/sisu-guava/0.11.1/sisu-guava-0.11.1.jar
[ERROR] urls[43] = file:/C:/Users/kancharp/.m2/repository/com/google/code/findbugs/jsr305/1.3.9/jsr305-1.3.9.jar
[ERROR] urls[44] = file:/C:/Users/kancharp/.m2/repository/org/sonatype/sisu/sisu-inject-bean/2.3.0/sisu-inject-bean-2.3.0.jar
[ERROR] urls[45] = file:/C:/Users/kancharp/.m2/repository/br/com/ingenieux/maven/annomojo/org.jfrog.maven.maven-plugin-anno/1.4.1/org.jfrog.maven.maven-plugin-anno-1.4.1.jar
[ERROR] urls[46] = file:/C:/Users/kancharp/.m2/repository/com/jcraft/jsch/0.1.48/jsch-0.1.48.jar
[ERROR] urls[47] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/plugins/maven-dependency-plugin/2.4/maven-dependency-plugin-2.4.jar
[ERROR] urls[48] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/reporting/maven-reporting-api/3.0/maven-reporting-api-3.0.jar
[ERROR] urls[49] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/reporting/maven-reporting-impl/2.0.5/maven-reporting-impl-2.0.5.jar
[ERROR] urls[50] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-core/1.0/doxia-core-1.0.jar
[ERROR] urls[51] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-doxia-tools/1.0.2/maven-doxia-tools-1.0.2.jar
[ERROR] urls[52] = file:/C:/Users/kancharp/.m2/repository/commons-io/commons-io/1.4/commons-io-1.4.jar
[ERROR] urls[53] = file:/C:/Users/kancharp/.m2/repository/commons-validator/commons-validator/1.2.0/commons-validator-1.2.0.jar
[ERROR] urls[54] = file:/C:/Users/kancharp/.m2/repository/commons-beanutils/commons-beanutils/1.7.0/commons-beanutils-1.7.0.jar
[ERROR] urls[55] = file:/C:/Users/kancharp/.m2/repository/commons-digester/commons-digester/1.6/commons-digester-1.6.jar
[ERROR] urls[56] = file:/C:/Users/kancharp/.m2/repository/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar
[ERROR] urls[57] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-sink-api/1.0/doxia-sink-api-1.0.jar
[ERROR] urls[58] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-site-renderer/1.0/doxia-site-renderer-1.0.jar
[ERROR] urls[59] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-velocity/1.1.7/plexus-velocity-1.1.7.jar
[ERROR] urls[60] = file:/C:/Users/kancharp/.m2/repository/org/apache/velocity/velocity/1.5/velocity-1.5.jar
[ERROR] urls[61] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-decoration-model/1.0/doxia-decoration-model-1.0.jar
[ERROR] urls[62] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-module-apt/1.0/doxia-module-apt-1.0.jar
[ERROR] urls[63] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-module-fml/1.0/doxia-module-fml-1.0.jar
[ERROR] urls[64] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-module-xdoc/1.0/doxia-module-xdoc-1.0.jar
[ERROR] urls[65] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/doxia/doxia-module-xhtml/1.0/doxia-module-xhtml-1.0.jar
[ERROR] urls[66] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-archiver/2.0/plexus-archiver-2.0.jar
[ERROR] urls[67] = file:/C:/Users/kancharp/.m2/repository/org/codehaus/plexus/plexus-io/2.0.1/plexus-io-2.0.1.jar
[ERROR] urls[68] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-dependency-analyzer/1.2/maven-dependency-analyzer-1.2.jar
[ERROR] urls[69] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-dependency-tree/1.2/maven-dependency-tree-1.2.jar
[ERROR] urls[70] = file:/C:/Users/kancharp/.m2/repository/org/apache/maven/shared/maven-invoker/2.0.11/maven-invoker-2.0.11.jar
[ERROR] urls[71] = file:/C:/Users/kancharp/.m2/repository/commons-lang/commons-lang/2.6/commons-lang-2.6.jar
[ERROR] urls[72] = file:/C:/Users/kancharp/.m2/repository/junit/junit/4.10/junit-4.10.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
[ERROR] 
[ERROR] -----------------------------------------------------: org.sonatype.aether.RepositorySystem
[ERROR] -> [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/AetherClassNotFound
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :bpm_ui_testing

2 个答案:

答案 0 :(得分:0)

右键点击你的项目。在Maven子菜单下单击更新,然后重试

<强>更新

这是缺失的工件

<dependency>
  <groupId>jaxrpc</groupId>
   <artifactId>jaxrpc</artifactId>
   <version>1.1</version>
</dependency>

尝试使用

<dependency>
   <groupId>javax.xml</groupId>
   <artifactId>jaxrpc-api</artifactId>
    <version>1.1</version>
 </dependency>

并且

<dependency>
   <groupId>org.apache.commons</groupId>
     <artifactId>commons-logging</artifactId>
    <version>3.1</version>
 </dependency>

也缺少神器

所以使用不同的。或者从这个下载链接下载jar Common logging

答案 1 :(得分:0)

看起来你有一个丢失的jar,试着将这个依赖项添加到你的项目

<dependency>
    <groupId>org.sonatype.aether</groupId>
    <artifactId>aether-api</artifactId>
    <version>1.13.1</version>
</dependency>