-
Notifications
You must be signed in to change notification settings - Fork 7.6k
1.x: add AnimalSniffer to the build process, fix and suppress violations #4092
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Flaky tests:
|
To be merged after #4091 in case there is a conflict. |
Current coverage is 80.28%@@ 1.x #4092 diff @@
==========================================
Files 259 259
Lines 16821 16821
Methods 0 0
Messages 0 0
Branches 2554 2554
==========================================
+ Hits 13500 13504 +4
+ Misses 2408 2402 -6
- Partials 913 915 +2
|
@@ -98,6 +98,7 @@ public static void deregisterExecutor(ScheduledExecutorService service) { | |||
} | |||
|
|||
/** Purges each registered executor and eagerly evicts shutdown executors. */ | |||
@SuppressAnimalSniffer // CHM.keySet returns KeySetView in Java 8+; false positive here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If possible please report an issue back to animalsniffer
Does it really fail the build if you try to use Java7+ APIs? |
That AssertionError initialization did fail locally, but can't really post a PR that demonstrates failure, right? |
Sure sure, I mean have you checked that it really fails build that we perform on CI in case of using Java7+ APIs? (you can execute commands from buildViaTravis.sh locally to check that). |
That's annoying, we seem to get shot down by out-of-memory checkers, maybe due to extensive thread usage? Or we have a leak somewhere. |
👍 I see ~similar instability of CI regarding memory usage in other projects I work on, solution I currently stick to is to divide build into separate steps like: ./gradlew --no-daemon clean
./gradlew --no-daemon assemble
./gradlew --no-daemon test
// etc Either it's leak in Gradle (or some plugin) or CI under load gives us less memory. |
👍 |
This PR adds the AnimalSniffer plugin to check for Java 6 API violations.
Related issue: #4067.