Question
An exception occurred when compiling an open source project (openlookeng), resulting in compilation failure.
Abnormal content
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:3.1.1:analyze-only (default) on project presto-vv: Dependency problems found -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:3.1.1:analyze-only (default) on project presto-vv: Dependency problems found
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:148)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:957)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:289)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:193)
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:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
Caused by: org.apache.maven.plugin.MojoExecutionException: Dependency problems found
at org.apache.maven.plugins.dependency.analyze.AbstractAnalyzeMojo.execute (AbstractAnalyzeMojo.java:253)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:210)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:148)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:957)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:289)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:193)
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:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
[ERROR]
[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/MojoExecutionException
Causes and Solutions
This is because Maven’s dependency check plug-in is enabled. When checking the plug-in, it is found that some dependencies are not used or used but not defined. As follows:
[INFO] --- maven-dependency-plugin:3.1.1:analyze-only (default) @ presto-vv ---
[WARNING] Used undeclared dependencies found:
[WARNING] org.apache.pulsar:pulsar-client-api:jar:2.8.0:compile
[WARNING] org.apache.pulsar:pulsar-metadata:jar:2.8.0:compile
[WARNING] commons-configuration:commons-configuration:jar:1.10:compile
[WARNING] org.apache.bookkeeper:bookkeeper-common:jar:4.14.1:compile
[WARNING] org.slf4j:slf4j-api:jar:1.7.29:compile
[WARNING] javax.ws.rs:javax.ws.rs-api:jar:2.1:compile
[WARNING] org.apache.commons:commons-lang3:jar:3.11:compile
[WARNING] org.jctools:jctools-core:jar:2.1.2:compile
[WARNING] org.apache.bookkeeper:bookkeeper-server:jar:4.14.1:compile
[WARNING] org.apache.pulsar:pulsar-client-admin-api:jar:2.8.0:compile
[WARNING] org.apache.pulsar:pulsar-common:jar:2.8.0:compile
[WARNING] org.apache.avro:avro:jar:1.9.2:compile
[WARNING] io.netty:netty-buffer:jar:4.1.63.Final:compile
[WARNING] org.apache.bookkeeper.stats:bookkeeper-stats-api:jar:4.14.1:compile
[WARNING] Unused declared dependencies found:
[WARNING] org.projectlombok:lombok:jar:RELEASE:compile
If you do not need to strictly check invalid dependencies, you can set parameters to not check. Please refer to
Maven dependency plugin -> analyze-only
The parameter to be added to skip this check: skip, which is explained as follows:
skip plugin execution complete.
default value is: false.
user property is: mdep.analyze.skip
Read More:
- [Solved] MVN Build Project Error: Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M5:test
- MVN compile Error: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin…
- [Solved] O2oa compile error: Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin
- [Solved] Spring Boot Package Error: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0
- [Solved] SpringBoot Pack Project: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources
- [Solved] Failed to execute goal org.apache.maven.plugins:maven-install-plugin:2.4:install (default-cli) on
- [Solved] Maven Publish Error: Failed to execute goal org.apache.maven.pluginsmaven-deploy-plugin2.8.2deploy
- Springboot Project Error: Failed to execute goal org.apache.maven.plugins
- [Solved] Mybatis.generator error: Failed to execute goal org.mybatis.generator:mybatis-generator-maven-plugin:1.3.2
- [Solved] org.apache.maven.archiver.MavenArchiver.getManifest(org.apache.maven.project.MavenProject…
- [Solved] ‘build.plugins.plugin.version‘ for org.springframework.boot:spring-boot-maven-plugin is missing.
- maven.TestGenerateMojo.execute(TestGenerateMojo.java:65) [How to Solve]
- Maven (http://repo1.maven.org/maven2/): Failed to transfer file and PKIX path building failed: sun.secu
- IDEA Create maven project error: Error running‘[org.apache.maven.pluginsmaven-archetype-pluginRELEASE
- [Solved] IDEA Import springboot Project Error: Cannot resolve plugin org.springframework.boot:spring-boot-maven-plugin:<unknown>
- Maven plugin development report error- plugin:3.2 :descriptor fai
- IDEA Maven Fail to Download Dependencies Error: ERROR – #org.jetbrains.idea.maven – Cannot reconnect.
- [Solved] Maven Multi-Project Compile Error: The POM for xxx is invalid
- [Solved] Docker-maven-plugin Build Mirror Error: failed: Connection refused: connect
- [Solved] maven Error: Failed to read artifact descriptor for org.