You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Aljoscha Krettek (JIRA)" <ji...@apache.org> on 2017/07/06 09:45:00 UTC

[jira] [Commented] (FLINK-7111) flink-scala-shell fails on mvn verify

    [ https://issues.apache.org/jira/browse/FLINK-7111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16076256#comment-16076256 ] 

Aljoscha Krettek commented on FLINK-7111:
-----------------------------------------

Ok, the problem is this: both {{flink-tests}} and {{flink-scala-shell}} (with a recent change) have a pattern where test classes are compiled, then a jar is built from these using maven-assembly and then the compiled classes are deleted. Tests use these jars to test whether the user ClassLoader works. This means that after {{mvn clean install}} the class files that go into the jars are not present.

In {{flink-tests}}, apparently, the {{maven-compiler-plugin}} always detects that there are changes and recompiles the test classes:
{code}
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ flink-tests_2.11 ---
[INFO] Changes detected - recompiling the module!
{code}
this, means that the assembly plugin finds the classes and the jar can be built.

In {{flink-scala-shell}}, however, {{scala-maven-plugin}} does not think that we need another compilation:
{code}
[INFO] --- scala-maven-plugin:3.2.2:testCompile (scala-test-compile) @ flink-scala-shell_2.11 ---
[INFO] Nothing to compile - all classes are up to date
{code}
therefore, the class files are not there when the assembly plugin tries to re-generate that jar files.

By, the way, the jar files are still there after {{mvn clean install}} so {{mvn verify}} would not actually have to re-generate them.

Not sure how to fix this yet.

> flink-scala-shell fails on mvn verify
> -------------------------------------
>
>                 Key: FLINK-7111
>                 URL: https://issues.apache.org/jira/browse/FLINK-7111
>             Project: Flink
>          Issue Type: Bug
>          Components: Scala Shell, Tests
>    Affects Versions: 1.4.0
>            Reporter: Chesnay Schepler
>             Fix For: 1.4.0
>
>
> Running {{mvn verify}} after {{mvn clean install -DskipTests}} causes the build to fail in {{flink-scala-shell}} with
> {code}
> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-assembly-plugin:2.4:single (create-library-loading-jar) on project flink-scala-shell_2.11: Failed to create assembly: Error creating assembly archive test-jar: You must set at least one file. -> [Help 1]
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)