cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Podkowinski (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-13175) Integrate "Error Prone" Code Analyzer
Date Thu, 07 Sep 2017 13:10:00 GMT


Stefan Podkowinski commented on CASSANDRA-13175:

The javac error that causes ant to fail is the following. Everything else is just a warning.

    [javac] /home/ubuntu/cassandra/src/java/org/apache/cassandra/utils/
error: unreported exception Exception; must be caught or declared to be thrown
    [javac]         perform(Stream.of(actions));
    [javac]                ^

Seems like javac isn't able to infer the types. Using an explicit declaration for the Stream.of()
value will fix this. But now I'm getting [another issue|]
saying that {{MoreExecutors.sameThreadExecutor())}} cannot be found. This seems to be due
to [#492|]. Again, the newer guava version
used by errorprone breaks the build. Why this isn't the case on my local machine is still
beyond me; classpath issues I guess..

> Integrate "Error Prone" Code Analyzer
> -------------------------------------
>                 Key: CASSANDRA-13175
>                 URL:
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Stefan Podkowinski
>            Assignee: Stefan Podkowinski
>         Attachments: 0001-Add-Error-Prone-code-analyzer.patch, checks-2_2.out, checks-3_0.out,
> I've been playing with [Error Prone|] by integrating it into the
build process and to see what kind of warnings it would produce. So far I'm positively impressed
by the coverage and usefulness of some of the implemented checks. See attachments for results.
> Unfortunately there are still some issues on how the analyzer is effecting generated
code and used guava versions, see [#492|].
In case those issues have been solved and the resulting code isn't affected by the analyzer,
I'd suggest to add it to trunk with warn only behaviour and some less useful checks disabled.
Alternatively a new ant target could be added, maybe with build breaking checks and CI integration.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message