GitHub user zentol opened a pull request:

    https://github.com/apache/flink/pull/5644

     [FLINK-8847][build] Prevent unnecessary recompilation

    ## What is the purpose of the change
    
    This PR contains 2 changes to prevent the `maven-compiler-plugin` from 
recompiling a module that doesn't require it.
    
    The `maven-compiler-plugin` will now always create `.class` files for 
`package-info.java` files. Previously this was only done if the `.java` file 
contained annotations.
    
    Having a `.java` file without a corresponding `.class` file throws of the 
`maven-compiler-plugin` stale source detection, as described in 
[MCOMPILER-205](https://issues.apache.org/jira/browse/MCOMPILER-205).
    
    Additionally, `useIncrementalCompilation` is set to false which actually 
enables incremental compilation, as described in 
[MCOMPILER-209](https://issues.apache.org/jira/browse/MCOMPILER-209).
    
    ## Brief change log
    
    * create `.class` files for all `package-info.java` files
    * set `useIncrementalCompilation` to false which actually enables 
incremental compilation
    
    ## Verifying this change
    
    Pick any module that contains a  `package-info.java` file (like 
`flink-optimizer`) and run `mvn package <speed options>` twice. The plugin 
should not recompile the module.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/zentol/flink 8847

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/5644.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #5644
    
----
commit 293795b5e5f57dba07e985be9e46ba2534e91eac
Author: zentol <chesnay@...>
Date:   2018-03-06T09:45:25Z

    [FLINK-8847][build] Always generate .class files for package-info.java

commit 92d17feab6cd604fd2bd2be96d6ed35485c13b80
Author: zentol <chesnay@...>
Date:   2018-03-06T10:04:42Z

    [hotfix][build] Enable incremental compilation

----


---

Reply via email to