Mvn clean package gives an unexpected java.lang.AssertionError - java

I am trying to do a mvn clean package to my Maven Springboot Project but I see the following message. What can be the reason? I already searched everything on the internet; it is a common situation but nobody has a definitive solution which can be useful for me.
My maven version is 3.6.3; I tried to do this from command line; my o.s. is Linux Mint Cinnamnon latest; my java is OpendJDK 11.0.5; maven compiler plugin 3.8.0.
[INFO] ------------------------------------------------------------------------
---------------------------------------------------
constituent[0]: file:/home/user/.sdkman/candidates/maven/current/conf/logging/
constituent[1]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-model-builder-3.6.3.jar
constituent[2]: file:/home/user/.sdkman/candidates/maven/current/lib/commons-io-2.5.jar
constituent[3]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-model-3.6.3.jar
constituent[4]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-settings-3.6.3.jar
constituent[5]: file:/home/user/.sdkman/candidates/maven/current/lib/jcl-over-slf4j-1.7.29.jar
constituent[6]: file:/home/user/.sdkman/candidates/maven/current/lib/cdi-api-1.0.jar
constituent[7]: file:/home/user/.sdkman/candidates/maven/current/lib/wagon-http-3.3.4-shaded.jar
constituent[8]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-embedder-3.6.3.jar
constituent[9]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-api-1.4.1.jar
constituent[10]: file:/home/user/.sdkman/candidates/maven/current/lib/wagon-provider-api-3.3.4.jar
constituent[11]: file:/home/user/.sdkman/candidates/maven/current/lib/plexus-interpolation-1.25.jar
constituent[12]: file:/home/user/.sdkman/candidates/maven/current/lib/guice-4.2.1-no_aop.jar
constituent[13]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-slf4j-provider-3.6.3.jar
constituent[14]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-connector-basic-1.4.1.jar
constituent[15]: file:/home/user/.sdkman/candidates/maven/current/lib/org.eclipse.sisu.plexus-0.3.4.jar
constituent[16]: file:/home/user/.sdkman/candidates/maven/current/lib/plexus-cipher-1.7.jar
constituent[17]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-shared-utils-3.2.1.jar
constituent[18]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-artifact-3.6.3.jar
constituent[19]: file:/home/user/.sdkman/candidates/maven/current/lib/plexus-sec-dispatcher-1.4.jar
constituent[20]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-impl-1.4.1.jar
constituent[21]: file:/home/user/.sdkman/candidates/maven/current/lib/org.eclipse.sisu.inject-0.3.4.jar
constituent[22]: file:/home/user/.sdkman/candidates/maven/current/lib/slf4j-api-1.7.29.jar
constituent[23]: file:/home/user/.sdkman/candidates/maven/current/lib/guava-25.1-android.jar
constituent[24]: file:/home/user/.sdkman/candidates/maven/current/lib/plexus-component-annotations-2.1.0.jar
constituent[25]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-core-3.6.3.jar
constituent[26]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-plugin-api-3.6.3.jar
constituent[27]: file:/home/user/.sdkman/candidates/maven/current/lib/jsr250-api-1.0.jar
constituent[28]: file:/home/user/.sdkman/candidates/maven/current/lib/plexus-utils-3.2.1.jar
constituent[29]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-repository-metadata-3.6.3.jar
constituent[30]: file:/home/user/.sdkman/candidates/maven/current/lib/jsoup-1.12.1.jar
constituent[31]: file:/home/user/.sdkman/candidates/maven/current/lib/commons-lang3-3.8.1.jar
constituent[32]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-compat-3.6.3.jar
constituent[33]: file:/home/user/.sdkman/candidates/maven/current/lib/commons-cli-1.4.jar
constituent[34]: file:/home/user/.sdkman/candidates/maven/current/lib/wagon-file-3.3.4.jar
constituent[35]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-transport-wagon-1.4.1.jar
constituent[36]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-settings-builder-3.6.3.jar
constituent[37]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-util-1.4.1.jar
constituent[38]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-spi-1.4.1.jar
constituent[39]: file:/home/user/.sdkman/candidates/maven/current/lib/javax.inject-1.jar
constituent[40]: file:/home/user/.sdkman/candidates/maven/current/lib/jansi-1.17.1.jar
constituent[41]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-builder-support-3.6.3.jar
constituent[42]: file:/home/user/.sdkman/candidates/maven/current/lib/maven-resolver-provider-3.6.3.jar
---------------------------------------------------
Exception in thread "main" java.lang.AssertionError
at jdk.compiler/com.sun.tools.javac.util.Assert.error(Assert.java:155)
at jdk.compiler/com.sun.tools.javac.util.Assert.check(Assert.java:46)
at jdk.compiler/com.sun.tools.javac.comp.Modules.enter(Modules.java:247)
at jdk.compiler/com.sun.tools.javac.main.JavaCompiler.readSourceFile(JavaCompiler.java:837)
at jdk.compiler/com.sun.tools.javac.processing.JavacProcessingEnvironment$ImplicitCompleter.complete(JavacProcessingEnvironment.java:1529)
at jdk.compiler/com.sun.tools.javac.code.Symbol.complete(Symbol.java:642)
at jdk.compiler/com.sun.tools.javac.code.Symbol$ClassSymbol.complete(Symbol.java:1326)
at jdk.compiler/com.sun.tools.javac.code.Type$ClassType.complete(Type.java:1140)
at jdk.compiler/com.sun.tools.javac.code.Type$ClassType.getTypeArguments(Type.java:1066)
at jdk.compiler/com.sun.tools.javac.code.Printer.visitClassType(Printer.java:237)
at jdk.compiler/com.sun.tools.javac.code.Printer.visitClassType(Printer.java:52)
at jdk.compiler/com.sun.tools.javac.code.Type$ClassType.accept(Type.java:993)
at jdk.compiler/com.sun.tools.javac.code.Printer.visit(Printer.java:136)
at jdk.compiler/com.sun.tools.javac.util.AbstractDiagnosticFormatter.formatArgument(AbstractDiagnosticFormatter.java:199)
at jdk.compiler/com.sun.tools.javac.util.AbstractDiagnosticFormatter.formatArguments(AbstractDiagnosticFormatter.java:167)
at jdk.compiler/com.sun.tools.javac.util.BasicDiagnosticFormatter.formatMessage(BasicDiagnosticFormatter.java:111)
at jdk.compiler/com.sun.tools.javac.util.BasicDiagnosticFormatter.formatMessage(BasicDiagnosticFormatter.java:67)
at jdk.compiler/com.sun.tools.javac.util.AbstractDiagnosticFormatter.formatArgument(AbstractDiagnosticFormatter.java:185)
at jdk.compiler/com.sun.tools.javac.util.AbstractDiagnosticFormatter.formatArguments(AbstractDiagnosticFormatter.java:167)
at jdk.compiler/com.sun.tools.javac.util.BasicDiagnosticFormatter.formatMessage(BasicDiagnosticFormatter.java:111)
at jdk.compiler/com.sun.tools.javac.util.BasicDiagnosticFormatter.formatMessage(BasicDiagnosticFormatter.java:67)
at jdk.compiler/com.sun.tools.javac.util.JCDiagnostic.getMessage(JCDiagnostic.java:788)
at jdk.compiler/com.sun.tools.javac.api.ClientCodeWrapper$DiagnosticSourceUnwrapper.getMessage(ClientCodeWrapper.java:799)
at org.codehaus.plexus.compiler.javac.JavaxToolsCompiler.compileInProcess(JavaxToolsCompiler.java:131)
at org.codehaus.plexus.compiler.javac.JavacCompiler.performCompile(JavacCompiler.java:174)
at org.apache.maven.plugin.compiler.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:1129)
at org.apache.maven.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:188)
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 java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
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)
And this is the previous part of the output
user#User-VirtualBox-Mint:~/Desktop/mycompany/myapp$ mvn clean package -U -Dwithout-frontend
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] myapp [pom]
[INFO] myapp-server [jar]
[INFO]
[INFO] -----------------------< com.mycompany:myapp >------------------------
[INFO] Building myapp 1.0.0-SNAPSHOT [1/2]
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) # myapp ---
[INFO]
[INFO] --------------------< com.mycompany:myapp-server >--------------------
[INFO] Building myapp-server 1.0.0-SNAPSHOT [2/2]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) # myapp-server ---
[INFO] Deleting /home/user/Desktop/mycompany/myapp/server/target
[INFO]
[INFO] --- git-commit-id-plugin:2.2.6:revision (default) # myapp-server ---
[INFO]
[INFO] --- spring-boot-maven-plugin:2.1.7.RELEASE:build-info (default) # myapp-server ---
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:resources (default-resources) # myapp-server ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 4 resources
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.0:compile (default-compile) # myapp-server ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 17 source files to /home/user/Desktop/mycompany/myapp/server/target/classes
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for myapp 1.0.0-SNAPSHOT:
[INFO]
[INFO] myapp ............................................. SUCCESS [ 0.252 s]
[INFO] myapp-server ...................................... FAILURE [ 4.913 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.494 s
[INFO] Finished at: 2019-12-12T14:48:34+01:00
[INFO] ------------------------------------------------------------------------
---------------------------------------------------
If I try to add javaccompilerforce use in my main pom.xml such that this part is as following
<version>3.8.0</version>
<configuration>
<forceJavacCompilerUse>true</forceJavacCompilerUse>
<compilerArgs>
<arg>-parameters</arg>
</compilerArgs>
</configuration>
</plugin>
I see this time this new error
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project myapp-server: Compilation failure: Compilation failure:
[ERROR] /home/user/Desktop/mycompany/myapp/server/src/main/java/com/mycompany/myapp/representation/rest/RestControllerAdvice.java:[8,38] error: package com.mycompany.myapp.exception does not exist
[ERROR] /home/user/Desktop/mycompany/myapp/server/src/main/java/com/mycompany/myapp/representation/rest/RestControllerAdvice.java:[25,84] error: cannot find symbol
[ERROR] symbol: class InvalidPropertyValueException
[ERROR] location: class RestControllerAdvice
[ERROR] /home/user/Desktop/mycompany/myapp/server/src/main/java/com/mycompany/myapp/representation/rest/RestControllerAdvice.java:[25,24] error: cannot find symbol
[ERROR] symbol: class InvalidPropertyValueException
[ERROR] location: class RestControllerAdvice
[ERROR] /home/user/Desktop/mycompany/myapp/server/src/main/java/com/mycompany/myapp/representation/rest/RestControllerAdvice.java:[24,20] error: cannot find symbol
[ERROR] symbol: class InvalidPropertyValueException
[ERROR] location: class RestControllerAdvice
[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/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <args> -rf :myapp-server
Really, is the reason of the problem the absence of one folder or package? Or this second row is simply related to the javaccompilerforce option itself and not with the core of the app? It seems me too strange or banal. And, in add, the exactly same app works perfectly in another computer.
Edit
Thanks to all for your time, I think, the problem is the absence of some components. I tried to add those and now the error message is changed. At this point, I am a little bit in trouble because I see this maven output:
[ERROR] /home/user/Desktop/mycompany/myapp/server/src/main/java/com/mycompany/myapp/representation/rest/RestControllerAdvice.java:[8,38] error: cannot find symbol
[ERROR] symbol: class InvalidPropertyValueException
[ERROR] location: package com.mycompany.myapp.exception
So, I searched the 8 row in that file and I found this one
import org.springframework.web.bind.annotation.ExceptionHandler;
But, the line which is referred to InvalidPropertyValueException is 2 rows before:
import com.mycompany.myapp.exception.InvalidPropertyValueException;
And, the strange thing, in the package com.mycompanny.myapp.exception I didn't found any class or file named InvalidPropertyValueException. But Eclipse accept it and present me in the option list. And this class don't generate any error or red line.

you can try this command with skip your unit test cases
"mvn clean install -DskipTests=true"

Related

Maven Home is not specified for Gluon JavaFX - Why?

I just installed Eclipse IDE 2022-03 and Gluon Plugin 2.8.2. Latest Eclipse IDE does not work with Gluon 2.8.2.
Anyway!
I created a FXML project and then I run the project with mvn gluonfx:run as the manual says. mvn javafx:run is working
But then I got this error.
[INFO] Scanning for projects...
[INFO]
[INFO] -------------------< com.gluonapplication:test-fxml >-------------------
[INFO] Building Test FXML 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] >>> gluonfx-maven-plugin:1.0.8:run (default-cli) > process-classes # test-fxml >>>
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # test-fxml ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 6 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) # test-fxml ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] <<< gluonfx-maven-plugin:1.0.8:run (default-cli) < process-classes # test-fxml <<<
[INFO]
[INFO]
[INFO] --- gluonfx-maven-plugin:1.0.8:run (default-cli) # test-fxml ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.174 s
[INFO] Finished at: 2022-09-23T11:13:29+02:00
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "pom.xml" could not be activated because it does not exist.
[ERROR] Failed to execute goal com.gluonhq:gluonfx-maven-plugin:1.0.8:run (default-cli) on project test-fxml: Execution default-cli of goal com.gluonhq:gluonfx-maven-plugin:1.0.8:run failed: ${maven.home} is not specified as a directory: 'C:\Users\dmn\eclipse-workspace\Test FXML\EMBEDDED'. -> [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/PluginExecutionException
As you can see, this is the problem. Maven for Gluon JavaFX is not specified. Why and how can I specifiy it?
[ERROR] Failed to execute goal com.gluonhq:gluonfx-maven-plugin:1.0.8:run (default-cli) on project test-fxml: Execution default-cli of goal com.gluonhq:gluonfx-maven-plugin:1.0.8:run failed: ${maven.home} is not specified as a directory: 'C:\Users\dmn\eclipse-workspace\Test FXML\EMBEDDED'. -> [Help 1]

Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.1.0:resources

Can any one help me? Why this is happen, and how to solve this error?
I try to run mvn clean package -DskipTests
[INFO]
[INFO] -------------------< com.hybris.hybris123:hybris123 >-------------------
[INFO] Building hybris123 1.1
[INFO] --------------------------------[ war ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) # hybris123 ---
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:resources (default-resources) # hybris123 ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.723 s
[INFO] Finished at: 2022-01-13T16:41:34+07:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.1.0:resources (default-resources) on project hybris123: Cannot create resource output directory: /opt/CXCOMM210500P_0-70005661/hybris123/target/classes -> [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/MojoExecutionException
My Java Home variable is /usr/lib/jvm/java-11-openjdk-amd64
And My maven variable like this :
export M2_HOME=/opt/maven
export MAVEN_HOME=/opt/maven
export PATH=${M2_HOME}/bin:${PATH}
Please Help me

Issue while running Jitsi videobridge

I tried to clone jvb and run with maven accordint to this. And i did it using docker. My dockerfile is
FROM ubuntu:18.04
RUN apt-get update -y
RUN apt-get install default-jdk -y
RUN apt-get install -y maven
CMD ["sleep","1000000"]
My docker-compose file is
version: '3.3'
services:
jvbz:
build: .
volumes:
- "./src:/jvb:rw"
- "./.m2:/root/.m2:rw"
working_dir: /jvb
ports:
- "8086:1999"
but when i run using maven it shows the following error:
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] jvb-parent
[INFO] jvb-api-parent
[INFO] jvb-api-common
[INFO] jvb-api-client
[INFO] jitsi-videobridge
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building jvb-parent 2.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-enforcer-plugin:3.0.0-M3:enforce (enforce-maven) # jvb-parent ---
[INFO]
[INFO] --- exec-maven-plugin:3.0.0:exec (default-cli) # jvb-parent ---
Error: Could not find or load main class org.jitsi.videobridge.MainKt
Caused by: java.lang.ClassNotFoundException: org.jitsi.videobridge.MainKt
[ERROR] Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)
at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:404)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:166)
at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:982)
at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:929)
at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:457)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
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:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:309)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:194)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:107)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:993)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:345)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:191)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
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)
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] jvb-parent ......................................... FAILURE [ 0.702 s]
[INFO] jvb-api-parent ..................................... SKIPPED
[INFO] jvb-api-common ..................................... SKIPPED
[INFO] jvb-api-client ..................................... SKIPPED
[INFO] jitsi-videobridge .................................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.118 s
[INFO] Finished at: 2021-03-31T14:55:55Z
[INFO] Final Memory: 11M/47M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.0.0:exec (default-cli) on project jvb-parent: Command execution failed.: Process exited with an error: 1 (Exit value: 1) -> [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/MojoExecutionException
You can view the source code here
Jitsi Videobridge is an XMPP server component that allows for multiuser video communication. Unlike the expensive dedicated hardware videobridges, Jitsi Videobridge does not mix the video channels into a composite video stream, but only relays the received video channels to all call participants. Therefore, while it does need to run on a server with good network bandwidth, CPU horsepower is not that critical for performance.
Can someone please help me with this.

Getting error while running Maven Project from Jenkins even though same setup works on Locally

Description : Same POM works locally with same suit but when i am swtiching to Jenkins execution, it shows the errors. Can anyone please help me to understand why this may happening?
Error Message recevied while running job from jenkins :
Started by user unknown or anonymous
[EnvInject] - Loading node environment variables.
Building in workspace /var/lib/jenkins/workspace/WanderlyAutomationSuite
> git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
> git config remote.origin.url git#github.com:orionhcs/automation-tests.git # timeout=10
Fetching upstream changes from git#github.com:orionhcs/automation-tests.git
> git --version # timeout=10
using GIT_SSH to set credentials
> git fetch --tags --progress git#github.com:orionhcs/automation-tests.git +refs/heads/*:refs/remotes/origin/*
> git rev-parse refs/remotes/origin/master^{commit} # timeout=10
> git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
Checking out Revision 53f5d799bb2578706e48d80e1f428ca5a324e96c (refs/remotes/origin/master)
> git config core.sparsecheckout # timeout=10
> git checkout -f 53f5d799bb2578706e48d80e1f428ca5a324e96c
Commit message: "updated the code"
> git rev-list --no-walk 53f5d799bb2578706e48d80e1f428ca5a324e96c # timeout=10
[WanderlyAutomationSuite] $ /bin/sh -xe /tmp/jenkins8894762653318384960.sh
+ export M2_HOME=/srv/maven/
Parsing POMs
Established TCP socket on 37493
[WanderlyAutomationSuite] $ /usr/lib/jvm/java-8-openjdk-amd64//bin/java -cp /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-agent-1.12.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4/boot/plexus-classworlds-2.5.2.jar:/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4/conf/logging jenkins.maven3.agent.Maven35Main /var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.5.4 /var/cache/jenkins/war/WEB-INF/lib/remoting-3.19.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven35-interceptor-1.12.jar /var/lib/jenkins/plugins/maven-plugin/WEB-INF/lib/maven3-interceptor-commons-1.12.jar 37493
<===[JENKINS REMOTING CAPACITY]===>channel started
Executing Maven: -B -f /var/lib/jenkins/workspace/WanderlyAutomationSuite/pom.xml compile test
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< Wanderly:WanderlyScenarios >---------------------
[INFO] Building WanderlyScenarios 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/workspace/WanderlyAutomationSuite/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.18.1:test (default-test) # WanderlyScenarios ---
[INFO] No tests to run.
[INFO] Surefire report directory: /var/lib/jenkins/workspace/WanderlyAutomationSuite/target/surefire-reports
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running TestSuite
Results :
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[JENKINS] Recording test results
hudson.AbortException: Test reports were found but none of them are new. Did leafNodes run?
For example, /var/lib/jenkins/workspace/WanderlyAutomationSuite/target/surefire-reports/TEST-TestSuite.xml is 37 min old
at hudson.tasks.junit.TestResult.parse(TestResult.java:266)
at hudson.tasks.junit.TestResult.parse(TestResult.java:231)
at hudson.maven.reporters.SurefireArchiver.postExecute(SurefireArchiver.java:148)
at hudson.maven.Maven3Builder$MavenExecutionListener.recordMojoEnded(Maven3Builder.java:629)
at hudson.maven.Maven3Builder$MavenExecutionListener.mojoFailed(Maven3Builder.java:662)
at hudson.maven.Maven3Builder$JenkinsEventSpy.onEvent(Maven3Builder.java:306)
at org.apache.maven.eventspy.internal.EventSpyDispatcher.onEvent(EventSpyDispatcher.java:104)
at org.apache.maven.eventspy.internal.EventSpyExecutionListener.mojoFailed(EventSpyExecutionListener.java:138)
at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:90)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:220)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
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.jvnet.hudson.maven3.launcher.Maven35Launcher.main(Maven35Launcher.java:130)
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:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at jenkins.maven3.agent.Maven35Main.launch(Maven35Main.java:176)
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 hudson.maven.Maven3Builder.call(Maven3Builder.java:139)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:70)
at hudson.remoting.UserRequest.perform(UserRequest.java:212)
at hudson.remoting.UserRequest.perform(UserRequest.java:54)
at hudson.remoting.Request$2.run(Request.java:369)
at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.440 s
[INFO] Finished at: 2019-03-06T12:25:02-08:00
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test (default-test) on project WanderlyScenarios: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test failed: There was an error in the forked process
[ERROR] org.testng.TestNGException:
[ERROR] Cannot find class in classpath: com.scenarios.Wanderly_ApplyJob_Scenario
[ERROR] at org.testng.xml.XmlClass.loadClass(XmlClass.java:81)
[ERROR] at org.testng.xml.XmlClass.init(XmlClass.java:73)
[ERROR] at org.testng.xml.XmlClass.<init>(XmlClass.java:59)
[ERROR] at org.testng.xml.TestNGContentHandler.startElement(TestNGContentHandler.java:546)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1339)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2784)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:842)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327)
[ERROR] at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
[ERROR] at org.testng.xml.XMLParser.parse(XMLParser.java:38)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:16)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:9)
[ERROR] at org.testng.xml.Parser.parse(Parser.java:172)
[ERROR] at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:300)
[ERROR] at org.testng.TestNG.run(TestNG.java:1021)
[ERROR] at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:295)
[ERROR] at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:84)
[ERROR] at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:90)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
[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/PluginExecutionException
[JENKINS] Archiving /var/lib/jenkins/workspace/WanderlyAutomationSuite/pom.xml to Wanderly/WanderlyScenarios/0.0.1-SNAPSHOT/WanderlyScenarios-0.0.1-SNAPSHOT.pom
channel stopped
Finished: FAILURE
Below is the POM file which has created to run the script :
http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
<groupId>Wanderly</groupId>
<artifactId>WanderlyScenarios</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>WanderlyScenarios</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.18.1</version>
<configuration>
<suiteXmlFiles>
<suiteXmlFile>testngExecutor.xml</suiteXmlFile>
</suiteXmlFiles>
<testFailureIgnore>true</testFailureIgnore>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-chrome-driver -->
<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-chrome-driver -->
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-chrome-driver</artifactId>
<version>3.14.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.testng/testng -->
<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>6.9.9</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-server</artifactId>
<version>2.46.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi</artifactId>
<version>3.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/log4j/log4j -->
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.qmetry/qaf -->
<dependency>
<groupId>com.qmetry</groupId>
<artifactId>qaf</artifactId>
<version>2.1.14-RC2</version>
</dependency>
</dependencies>
</project>
After using "**mvn clean install**" shows below error :
it seems the error is related with maven with surefire plugin:
Can you please help me on this?
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------< Wanderly:WanderlyScenarios >---------------------
[INFO] Building WanderlyScenarios 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom (3.9 kB at 1.5 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom (13 kB at 24 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar (25 kB at 38 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom (5.8 kB at 11 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.jar (34 kB at 44 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom (6.4 kB at 15 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar (27 kB at 48 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # WanderlyScenarios ---
Downloading from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.pom (4.1 kB at 10 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/sonatype/spice/spice-parent/16/spice-parent-16.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/sonatype/spice/spice-parent/16/spice-parent-16.pom (8.4 kB at 19 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/sonatype/forge/forge-parent/5/forge-parent-5.pom
Downloaded from central: https://repo.maven.apache.org/maven2/org/sonatype/forge/forge-parent/5/forge-parent-5.pom (8.4 kB at 19 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.jar
Downloaded from central: https://repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-utils/3.0/plexus-utils-3.0.jar (226 kB at 181 kB/s)
[INFO] Deleting E:\Study Material\Selenium\WanderlyScenarios - NormalFW\target
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory E:\Study Material\Selenium\WanderlyScenarios - NormalFW\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # WanderlyScenarios ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory E:\Study Material\Selenium\WanderlyScenarios - NormalFW\src\test\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) # WanderlyScenarios ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.18.1:test (default-test) # WanderlyScenarios ---
[INFO] No tests to run.
[INFO] Surefire report directory: E:\Study Material\Selenium\WanderlyScenarios - NormalFW\target\surefire-reports
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running TestSuite
Results :
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:11 min
[INFO] Finished at: 2019-03-07T11:16:08+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test (default-test) on project WanderlyScenarios: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.18.1:test failed: There was an error in the forked process
[ERROR] org.testng.TestNGException:
[ERROR] Cannot find class in classpath: com.scenarios.Wanderly_ApplyJob_Scenario
[ERROR] at org.testng.xml.XmlClass.loadClass(XmlClass.java:81)
[ERROR] at org.testng.xml.XmlClass.init(XmlClass.java:73)
[ERROR] at org.testng.xml.XmlClass.<init>(XmlClass.java:59)
[ERROR] at org.testng.xml.TestNGContentHandler.startElement(TestNGContentHandler.java:546)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1339)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2784)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)
[ERROR] at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:842)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
[ERROR] at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
[ERROR] at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327)
[ERROR] at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
[ERROR] at org.testng.xml.XMLParser.parse(XMLParser.java:38)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:16)
[ERROR] at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:9)
[ERROR] at org.testng.xml.Parser.parse(Parser.java:172)
[ERROR] at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:300)
[ERROR] at org.testng.TestNG.run(TestNG.java:1021)
[ERROR] at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:295)
[ERROR] at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:84)
[ERROR] at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:90)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
[ERROR]
[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/PluginExecutionException
Even when I am using "mvn compile test", its working for me locally. Even when I am trying to run inside eclispe then also it works properly*

maven: Unable to run junit5-jupiter-starter-maven?

I downloaded the current version of the JUnit 5 sample code from https://github.com/junit-team/junit5-samples/tree/r5.2.0/ and extracted the subfolder junit5-jupiter-starter-maven to a local temp folder.
Then I openend a console window and tried to run that sample with mvnw clean test, but all I got was an java.lang.NoClassDefFoundError: org/junit/platform/launcher/core/LauncherFactory
Full maven output (of re-run without downloads):
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building junit5-vanilla-maven 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # junit5-vanilla-maven ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\temp\junit5-jupiter-starter-maven\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.7.0:compile (default-compile) # junit5-vanilla-maven ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) # junit5-vanilla-maven ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory C:\temp\junit5-jupiter-starter-maven\src\test\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.7.0:testCompile (default-testCompile) # junit5-vanilla-maven ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-surefire-plugin:2.21.0:test (default-test) # junit5-vanilla-maven ---
[INFO]
[INFO] -------------------------------------------------------
[INFO] T E S T S
[INFO] -------------------------------------------------------
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.245 s
[INFO] Finished at: 2018-06-01T16:31:25+02:00
[INFO] Final Memory: 11M/306M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.21.0:test (default-test) on project junit5-vanilla-maven: There are test failures.
[ERROR]
[ERROR] Please refer to C:\temp\junit5-jupiter-starter-maven\target\surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.
[ERROR] There was an error in the forked process
[ERROR] java.lang.NoClassDefFoundError: org/junit/platform/launcher/core/LauncherFactory
[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process
[ERROR] java.lang.NoClassDefFoundError: org/junit/platform/launcher/core/LauncherFactory
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:658)
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:278)
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:244)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1149)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:978)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:854)
[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:117)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81)
[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:309)
[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:194)
[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:107)
[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:993)
[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:345)
[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:191)
[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)
[ERROR] at org.apache.maven.wrapper.BootstrapMainStarter.start(BootstrapMainStarter.java:39)
[ERROR] at org.apache.maven.wrapper.WrapperExecutor.execute(WrapperExecutor.java:122)
[ERROR] at org.apache.maven.wrapper.MavenWrapperMain.main(MavenWrapperMain.java:50)
[ERROR]
[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/MojoExecutionException
mvnw --version:
Apache Maven 3.5.0 (ff8f5e7444045639af65f6095c62210b5713f426; 2017-04-03T21:39:06+02:00)
Maven home: C:\Users\<XXX>\.m2\wrapper\dists\apache-maven-3.5.0-bin\6ps54u5pnnbbpr6ds9rppcc7iv\apache-maven-3.5.0
Java version: 1.8.0_171, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk1.8.0_171\jre
Default locale: de_AT, platform encoding: Cp1252
OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"
Did I do something wrong, or can you reproduce this problem?
Since the error is
[ERROR] java.lang.NoClassDefFoundError: org/junit/platform/launcher/core/LauncherFactory
I suggest to check the junit-platform-launcher jar file. Maybe it is corrupted.
It should be the one of\.m2\repository\org\junit\platform\junit-platform-launcher\1.2.0\junit-platform-launcher-1.2.0.jar
For my it was a different problem. Multimodule maven project has two modules A and B, where A is using junit-pioneer:1.9.1 (having transitive dependency from junit-platform-launcher:1.8.2) when module B doesn't use junit-pioneer but fails to build because of java.lang.NoClassDefFoundError: org/junit/platform/launcher/core/LauncherFactory when building the whole project with mvn clean install.
My solution was to add (unused) test dependency from junit-pioneer to module B.

Categories

Resources