Surefire 2.22.0 : java.lang.IllegalStateException: error [STOPPED] to read process - junit4

When i execute unit tests i get this error from surefire plugin
am using maven-surefire-plugin, jacoco plugin and junit 4.12. This is the plugins from my pom :
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.0</version>
<configuration>
<skipTests>${skipTests}</skipTests>
<forkCount>1</forkCount>
<reuseForks>false</reuseForks>
</configuration>
<dependencies>
<dependency>
<groupId>org.apache.maven.surefire</groupId>
<artifactId>surefire-junit47</artifactId>
<version>2.21.0</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.7.201606060606</version>
<executions>
<execution>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>prepare-package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
# Created at 2020-10-28T17:58:53.813
System.exit() or native command error interrupted process checker.
java.lang.IllegalStateException: error [STOPPED] to read process 8076
at org.apache.maven.surefire.booter.PpidChecker.checkProcessInfo(PpidChecker.java:145)
at org.apache.maven.surefire.booter.PpidChecker.isProcessAlive(PpidChecker.java:116)
at org.apache.maven.surefire.booter.ForkedBooter$2.run(ForkedBooter.java:213)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
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)

Related

How to build executable jar from snowpark scala maven application and run from command line

I am able to build a jar for spark applications and java applications, but the same is not working for the snowpark applications. I would like to know, How to build executable jar from snowpark scala application and run from command line. I m able to build jar but not able to execute form command line
Below is my error
Exception in thread "main" net.snowflake.client.jdbc.SnowflakeSQLException: User Error Report:
Java Stack Trace:
java.lang.RuntimeException: java.lang.ClassNotFoundException: us.company.snowpark.etl.HashProcessor
at function_handler_0//com.snowflake.snowpark.internal.JavaUtils$.doDeserializeAndCloseInputStream(JavaUtils.scala:351)
at function_handler_0//com.snowflake.snowpark.internal.JavaUtils$.deserialize(JavaUtils.scala:335)
at function_handler_0//com.snowflake.snowpark.internal.JavaUtils.deserialize(JavaUtils.scala)
at function_handler_0//SnowUDF.<init>(InlineCode.java:12)
Caused by: java.lang.ClassNotFoundException: us.company.snowpark.etl.HashProcessor
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:471)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:589)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:398)
at java.base/java.io.ObjectInputStream.resolveClass(ObjectInputStream.java:745)
at java.base/java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1965)
at java.base/java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1851)
at java.base/java.io.ObjectInputStream.readClass(ObjectInputStream.java:1814)
at java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1639)
at java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2434)
at java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2328)
at java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2166)
at java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1668)
at java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:482)
at java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:440)
at function_handler_0//com.snowflake.snowpark.internal.JavaUtils$.doDeserializeAndCloseInputStream(JavaUtils.scala:348)
... 3 more
in function SNOWPARK_TEMP_FUNCTION_KTVPWBIRM0FSHTU with handler SnowUDF.compute
at net.snowflake.client.jdbc.SnowflakeUtil.checkErrorAndThrowExceptionSub(SnowflakeUtil.java:127)
at net.snowflake.client.jdbc.SnowflakeUtil.checkErrorAndThrowException(SnowflakeUtil.java:67)
at net.snowflake.client.core.StmtUtil.pollForOutput(StmtUtil.java:442)
at net.snowflake.client.core.StmtUtil.execute(StmtUtil.java:345)
at net.snowflake.client.core.SFStatement.executeHelper(SFStatement.java:487)
at net.snowflake.client.core.SFStatement.executeQueryInternal(SFStatement.java:198)
at net.snowflake.client.core.SFStatement.executeQuery(SFStatement.java:135)
at net.snowflake.client.core.SFStatement.execute(SFStatement.java:781)
at net.snowflake.client.core.SFStatement.execute(SFStatement.java:677)
at net.snowflake.client.jdbc.SnowflakeStatementV1.executeQueryInternal(SnowflakeStatementV1.java:238)
at net.snowflake.client.jdbc.SnowflakePreparedStatementV1.executeQuery(SnowflakePreparedStatementV1.java:117)
at com.snowflake.snowpark.internal.ServerConnection.$anonfun$runQueryGetResult$1(ServerConnection.scala:358)
at com.snowflake.snowpark.internal.ServerConnection.withValidConnection(ServerConnection.scala:810)
at com.snowflake.snowpark.internal.ServerConnection.runQueryGetResult(ServerConnection.scala:353)
at com.snowflake.snowpark.internal.ServerConnection.runQuery(ServerConnection.scala:336)
at com.snowflake.snowpark.Session.runQuery(Session.scala:781)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.createJavaUDF(UDXRegistrationHandler.scala:735)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.$anonfun$registerUDF$5(UDXRegistrationHandler.scala:117)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.retryAfterFixingClassPath(UDXRegistrationHandler.scala:54)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.$anonfun$registerUDF$4(UDXRegistrationHandler.scala:99)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.withUploadFailureCleanup(UDXRegistrationHandler.scala:169)
at com.snowflake.snowpark.internal.UDXRegistrationHandler.registerUDF(UDXRegistrationHandler.scala:99)
at com.snowflake.snowpark.UDFRegistration.register(UDFRegistration.scala:2368)
at com.snowflake.snowpark.functions$.registerUdf(functions.scala:2998)
at com.snowflake.snowpark.functions$.udf(functions.scala:3110)
at us.company.snowpark.etl.HashProcessor.<init>(HashProcessor.scala:228)
at us.company.snowpark.app.SnowparkAppDriver$.main(SnowparkAppDriver.scala:24)
at us.company.snowpark.app.SnowparkAppDriver.main(SnowparkAppDriver.scala)
I have added below mentioned build in my pom and ran "mvn clean install". The executable fat jar is generated in the target folder in the project. More information about the maven jar plugin can be found at https://maven.apache.org/plugins/maven-jar-plugin/
<build>
<sourceDirectory>src/main/scala</sourceDirectory>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
</resources>
<plugins>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>3.2.2</version>
<executions>
<execution>
<goals>
<goal>compile</goal>
<goal>testCompile</goal>
</goals>
</execution>
</executions>
<configuration>
<args>
<arg>-encoding</arg>
<arg>${project.build.sourceEncoding}</arg>
</args>
<checkMultipleScalaVersions>false</checkMultipleScalaVersions>
</configuration>
</plugin>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.1</version>
<executions>
<execution>
<id>jar-with-dependencies</id>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<transformers>
<transformer
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>us.company.mainClass</mainClass>
</transformer>
</transformers>
<shadedArtifactAttached>true</shadedArtifactAttached>
<shadedClassifierName>FAT</shadedClassifierName>
<filters>
<filter>
<artifact>*:*</artifact>
<excludes>
<exclude>META-INF/*.SF</exclude>
<exclude>META-INF/*.DSA</exclude>
<exclude>META-INF/*.RSA</exclude>
</excludes>
</filter>
</filters>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.7</version>
<configuration>
<skipTests>true</skipTests>
</configuration>
</plugin>
</plugins>
</build>
Just follow the guide in the Snowpark Documentation:
https://docs.snowflake.com/en/sql-reference/stored-procedures-scala.html#using-sbt-to-build-a-jar-file-with-dependencies

Unable to import java.io into a scala package in a mixed scala/java project

I have a mixed scala/java project. Why would the following import not work?
This error occurs both in Intellij and more importantly on maven command line using
mvn clean -DskipTests package
Here is the intellij SDK:
Here is the relevant section of the pom.xml showing the java/scala interaction - as recommended by https://davidb.github.io/scala-maven-plugin/example_java.html :
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>4.1.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<executions>
<execution>
<id>scala-compile-first</id>
<phase>process-resources</phase>
<goals>
<goal>add-source</goal>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>scala-test-compile</id>
<phase>process-test-resources</phase>
<goals>
<goal>testCompile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
Here is the error from maven command line:
[ERROR] /git/OCspark/tcpclient/src/main/scala/com/pointr/tcp/iotest/package.scala:2: object io is not a member of package com.pointr.tcp.java
[ERROR] import java.io._
[ERROR] ^
Update Based on a comment by # LuisMiguelMejíaSuárez I looked at the java sources. Note that java is not the root of the package hierarchy - which might have then been the more obvious cause of this problem:
But .. unmarking_ the java directory as sources does fix the problem..
Why would this fix it?

Maven AspectJ plugin non spring project won't work

I have a project, which is NOT a spring application. I am trying to use AspectJ annotations in it. The Annotation classes are being referenced from another jar I have. I have mentioned my plugin section of POM below. My build succeeds but the console output of Maven never mentions anything about the AspectJ plugin and also the annotations don't work when I run my project.
I have been trying to find out what's wrong for hours now but can't figure it out.
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
<version>1.4</version>
<configuration>
<complianceLevel>1.8</complianceLevel>
<showWeaveInfo>true</showWeaveInfo>
<aspectLibraries>
<aspectLibrary>
<groupId>it.cvc.ciscocommerce.lps.lp-commons</groupId>
<artifactId>lp-commons</artifactId>
</aspectLibrary>
</aspectLibraries>
<source>1.8</source>
<target>1.8</target>
</configuration>
<executions>
<execution>
<phase>process-sources</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.4</version>
<configuration>
<warSourceDirectory>WebContent</warSourceDirectory>
<failOnMissingWebXml>false</failOnMissingWebXml>
<warName>listpriceservice</warName>
</configuration>
</plugin>
<!-- Plugin for sdaas deployment. For compressing war to tar.gz -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
<configuration>
<appendAssemblyId>false</appendAssemblyId>
<descriptors>
<descriptor>src/main/resources/assembly.xml</descriptor>
</descriptors>
</configuration>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.5.201505241946</version>
<executions>
<execution>
<id>default-prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>default-report</id>
<phase>prepare-package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
These are the two dependencies defined in the Jar which I am trying to use as the aspect library.
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjrt</artifactId>
<version>1.7.4</version>
</dependency>
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjtools</artifactId>
<version>1.7.4</version>
</dependency>
The jar is compiled fine and I amble to use it another SPRING application but not this one. In the SPRING application I don't even have the maven aspect plugin defined.
When I run the maven build, in console I see only the following plugins listed.
[DEBUG] Goal: org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean)
[DEBUG] Style: Regular
[DEBUG] Goal: org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile)
[DEBUG] Style: Regular
[DEBUG] Goal: org.apache.maven.plugins:maven-resources-plugin:2.6:testResources (default-testResources)
[DEBUG] Style: Regular
[DEBUG] Goal: org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (default-testCompile)
[DEBUG] Style: Regular
[DEBUG] Goal: org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test)
[DEBUG] Style: Regular
[DEBUG] Goal: org.apache.maven.plugins:maven-war-plugin:2.4:war (default-war)
[DEBUG] Style: Regular
EDIT: After reading kriegaex's answer and about pluginManagement vs plugins, I changed my POM as below. Please note that my project is not multi-module it has only one POM.
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
<version>1.4</version>
<configuration>
<complianceLevel>1.8</complianceLevel>
<showWeaveInfo>true</showWeaveInfo>
<aspectLibraries>
<aspectLibrary>
<groupId>it.cvc.ciscocommerce.lps.lp-commons</groupId>
<artifactId>lp-commons</artifactId>
</aspectLibrary>
</aspectLibraries>
<source>1.8</source>
<target>1.8</target>
</configuration>
<executions>
<execution>
<phase>process-sources</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.4</version>
<configuration>
<warSourceDirectory>WebContent</warSourceDirectory>
<failOnMissingWebXml>false</failOnMissingWebXml>
<warName>listpriceservice</warName>
</configuration>
</plugin>
<!-- Plugin for sdaas deployment. For compressing war to tar.gz -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
<configuration>
<appendAssemblyId>false</appendAssemblyId>
<descriptors>
<descriptor>src/main/resources/assembly.xml</descriptor>
</descriptors>
</configuration>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.5.201505241946</version>
<executions>
<execution>
<id>default-prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>default-report</id>
<phase>prepare-package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
When I do this, I get the following error on execution tag under AspectJ executions
Plugin execution not covered by lifecycle configuration: org.codehaus.mojo:aspectj-maven-plugin:1.4:compile (execution: default, phase: process-sources)
UPDATE I am marking this question as answered as my original issue of AspectJ plugin not being invoked is solved. I will open a new question on my other issue. Thanks to kriegaex for pointing me to the right direction.
I think this one is a classic and no AspectJ problem at all but a beginners' error using Maven:
You have defined your plugins' default settings in the <pluginManagement> section but forgot to reference them later in a separate <plugins> section. Thus, Maven has no idea that you want to use them at all.
Update:
Okay, I will elaborate a bit more as you still seem to have problems understanding how to use <pluginManagement> vs.<plugins>: You use the former in order to define version, scope and default settings for your plugins. Then you use the latter in order to easily just reference the predefined (managed) plugin in whatever module of your (possibly multi-module) project you need them without copying / pasting the same version and configuration anymore. So it is not "use either this or that" but it is "use both and combine them in a smart way". Example:
<pluginManagement>
<plugins>
<plugin>
<groupId>my.group.id</groupId>
<artifactId>my-plugin-name</artifactId>
<version>1.2.3</version>
<configuration>
<something>foo</something>
</configuration>
</plugin>
<plugin>
<groupId>my.group.id</groupId>
<artifactId>my-other-plugin-name</artifactId>
<version>4.5</version>
<scope>test</scope>
<configuration>
<blah>xyz</blah>
</configuration>
</plugin>
</plugins>
</pluginManagement>
And then later in the same module or in another module having the former one as a parent or importing it as a BoM (Bill of Materials):
<plugins>
<plugin>
<groupId>my.group.id</groupId>
<artifactId>my-plugin-name</artifactId>
</plugin>
<plugin>
<groupId>my.group.id</groupId>
<artifactId>my-other-plugin-name</artifactId>
</plugin>
</plugins>
See? very clean and simple.
This is similar to the difference between <dependencyManagement> and <dependencies>, by the way.
You can also extend or override the configuration for a managed plugin in the <plugins> section, so you are not limited to what was preconfigured.
As for why some managed plugins worked without you explicitly mentioning them in the <plugins> section: They were configured either in your parent POM or in the Maven root POM, such as the dependency plugin, compile plugin and other predefined and preconfigured Maven base plugins. If you make Maven display the effective POM for your module, you will see them.
The AspectJ Maven plugin is of course not a Maven base plugin, thus you have to configure it by yourself, which is what you are trying to do.

maven install failed on a javafx application

I have created a basic javafx project in eclipse using a maven archetype. When I run a maven install I get the following error. When I run the application in the IDE it works. When I try to run from the target folder it does nothing. Here is the error:
"Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (unpack-dependencies) on project testjavafx: Command execution failed. Cannot run program "C:\Program Files\Java\jdk-10.0.2..\bin\javafxpackager" (in directory "C:\Users\Stephen\Documents\eclipse-workspace\testjavafx"): CreateProcess error=2, The system cannot find the file specified -> [Help 1]"
Here is my pom.xml generated from maven archetype:
http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
<groupId>com.stevie</groupId>
<artifactId>testjavafx</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>testjavafx</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<mainClass>com.stevie.testjavafx.MainApp</mainClass>
</properties>
<organization>
<!-- Used as the 'Vendor' for JNLP generation -->
<name>Your Organisation</name>
</organization>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.6</version>
<executions>
<execution>
<id>unpack-dependencies</id>
<phase>package</phase>
<goals>
<goal>unpack-dependencies</goal>
</goals>
<configuration>
<excludeScope>system</excludeScope>
<excludeGroupIds>junit,org.mockito,org.hamcrest</excludeGroupIds>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.2.1</version>
<executions>
<execution>
<id>unpack-dependencies</id>
<phase>package</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>${java.home}/../bin/javafxpackager</executable>
<arguments>
<argument>-createjar</argument>
<argument>-nocss2bin</argument>
<argument>-appclass</argument>
<argument>${mainClass}</argument>
<argument>-srcdir</argument>
<argument>${project.build.directory}/classes</argument>
<argument>-outdir</argument>
<argument>${project.build.directory}</argument>
<argument>-outfile</argument>
<argument>${project.build.finalName}.jar</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>default-cli</id>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>${java.home}/bin/java</executable>
<commandlineArgs>${runfx.args}</commandlineArgs>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>10</source>
<target>10</target>
<compilerArguments>
<bootclasspath>${sun.boot.class.path}${path.separator}${java.home}/lib/jfxrt.jar</bootclasspath>
</compilerArguments>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.16</version>
<configuration>
<additionalClasspathElements>
<additionalClasspathElement>${java.home}/lib/jfxrt.jar</additionalClasspathElement>
</additionalClasspathElements>
</configuration>
</plugin>
</plugins>
</build>
Thank you for your help.

How to generate xml report with scoverage maven plugin?

I'm trying to generate scoverage xml report to use it in Jenkins. But all I can get is the folder scoverage-classes with my .scala files. Here is a part of my pom.xml:
<build>
<plugins>
<plugin>
<groupId>org.scala-tools</groupId>
<artifactId>maven-scala-plugin</artifactId>
<version>2.15.2</version>
<executions>
<execution>
<id>scala-compile</id>
<goals>
<goal>compile</goal>
<goal>testCompile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.scalatest</groupId>
<artifactId>scalatest-maven-plugin</artifactId>
<version>${scalatest.plugin.version}</version>
<configuration>
<junitxml>surefire-reports</junitxml>
<stdout>W</stdout>
</configuration>
<executions>
<execution>
<id>test</id>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.scoverage</groupId>
<artifactId>scoverage-maven-plugin</artifactId>
<version>1.1.1</version>
<configuration>
<scalaVersion>${scala.version}</scalaVersion>
<aggregate>true</aggregate>
</configuration>
</plugin>
</plugins>
</build>
<reporting>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.9</version>
<reportSets>
<reportSet>
<reports>
<report>index</report>
</reports>
</reportSet>
</reportSets>
</plugin>
<plugin>
<groupId>org.scoverage</groupId>
<artifactId>scoverage-maven-plugin</artifactId>
<version>${scoverage.plugin.version}</version>
<reportSets>
<reportSet>
<reports>
<report>report
</report>
</reports>
</reportSet>
</reportSets>
</plugin>
</plugins>
</reporting>
Scalatest generates xml reports, but Scoverage does not. I've tried to run maven with different args like mvn scoverage:report, mvn scoverage:report site and so on. Nothing helps. What should I change in my pom to make it work?
It turned out that I have scala compiler plugin that is not supported by scoverage plugin. Also it looks like maven scala compiler plugin from org.scala-tools is outdated. Supported by scoverage plugins are:
net.alchim31.maven:scala-maven-plugin
com.google.code.sbt-compiler-maven-plugin:sbt-compiler-maven-plugin