ARROW-6331: [Java] Incorporate ErrorProne into the java build#5263
ARROW-6331: [Java] Incorporate ErrorProne into the java build#5263tianchen92 wants to merge 3 commits intoapache:masterfrom
Conversation
|
cc @emkornfield |
java/memory/src/main/java/org/apache/arrow/memory/Accountant.java
Outdated
Show resolved
Hide resolved
| </profile> | ||
|
|
||
| <!-- using github.com/google/error-prone-javac is required when running on JDK 8 --> | ||
| <profile> |
There was a problem hiding this comment.
i would request this to be the default please :)
There was a problem hiding this comment.
@tianchen92
I was asking if anyone building arrow now needs to do so using java9 for this to work?
(or) can we continue using jdk8.
If we can continue running using jdk8, the change looks good.
If consumers need java9 to build - then i would request running error prone only if a specific profile is used (for e.g. in the example you have given using profile jdk1.8 activates the check with some special javac properties, meaning you would use a command like mvn -P jdk-18 to activate the profile) This way existing consumers will not be forced to upgrade their entire build chain to java9 to use arrow java.
There was a problem hiding this comment.
I see, thanks for clarify, now it works fine with jdk8 :)
There was a problem hiding this comment.
awesome..do we also want to modify ci to run this profile, so that it catches further bugs?
There was a problem hiding this comment.
We don't need do anything, just use 'mvn clean install' will trigger error prone :)
Codecov Report
@@ Coverage Diff @@
## master #5263 +/- ##
=========================================
Coverage ? 89.7%
=========================================
Files ? 693
Lines ? 104695
Branches ? 0
=========================================
Hits ? 93919
Misses ? 10776
Partials ? 0Continue to review full report at Codecov.
|
|
cc @emkornfield for comments since you opened this issue. |
|
Looks OK to me, I'm not an expert on setting this up, so if it looks ok to @praveenbingo I think we can merge |
|
CI on master is red since this merge: https://travis-ci.org/apache/arrow/builds/582523345 |
|
Does the following message related to this merge? |
|
@kou Looks like it is related, will put a patch to resolve the same. |
Thanks for pointing, I guess yes, before this PR merged, there is another PR merged before, so error phone didn't catch the error, I'll take a look and provide a fix. |
|
@tianchen92 - ah looks like you are already on it..pls ping me to merge the same when its ready |
I just see that, I will fix this soon :) |
|
Thanks! |
Related to [ARROW-6331](https://issues.apache.org/jira/browse/ARROW-6331). Using https://github.com/google/error-prone seems like it would be a good idea to automatically catch more errors. Closes apache#5263 from tianchen92/ARROW-6331 and squashes the following commits: 9cb3a86 <tianchen> fix pom properties bf66186 <tianchen> fix 3cbc00c <tianchen> Incorporate ErrorProne into the java build Authored-by: tianchen <niki.lj@alibaba-inc.com> Signed-off-by: Praveen <praveen@dremio.com>
Related to ARROW-6331.
Using https://github.com/google/error-prone seems like it would be a good idea to automatically catch more errors.