Corrupted Cache Causes Build Failures


(Ethan Hall) #1

Hey All,

I have noticed an issue with Gradle where the cache gets currupted, but it doesn’t get pruned correctly when Gradle recognizes it.

Here is the output of a build we had. The Gradle version was 2.13.

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option PermSize=256m; support was removed in 8.0
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=1024m; support was removed in 8.0
cache module-metadata.bin (/export/home/tester/.gradle/caches/modules-2/metadata-2.16/module-metadata.bin) is corrupt. Discarding.
cache artifact-at-repository.bin (/export/home/tester/.gradle/caches/modules-2/metadata-2.16/artifact-at-repository.bin) is corrupt. Discarding.
Parallel execution with configuration on demand is an incubating feature.
:buildSrc:compileJava UP-TO-DATE
:buildSrc:compileGroovy UP-TO-DATE
:buildSrc:processResources UP-TO-DATE
:buildSrc:classes UP-TO-DATE
:buildSrc:jar UP-TO-DATE
:buildSrc:assemble UP-TO-DATE
:buildSrc:compileTestJava UP-TO-DATE
:buildSrc:compileTestGroovy UP-TO-DATE
:buildSrc:processTestResources UP-TO-DATE
:buildSrc:testClasses UP-TO-DATE
:buildSrc:test UP-TO-DATE
:buildSrc:check UP-TO-DATE
:buildSrc:build UP-TO-DATE
Compiler fork uses up to: 0.25G (total memory: 0.95G, thread count: 24)
Default heap size of forked processes [Xms - Xmx]: Test - [250m - 484m], JavaExec - [100m - 484m], Javadoc - [100m - 484m], FindBugs - 484m
:checkDependencyConstraints
:growthrel-member-features-constants:checkDependencyConstraints
:growthrel-member-features-java:checkDependencyConstraints
:growthrel-member-features:checkDependencyConstraints
cache module-metadata.bin (/export/home/tester/.gradle/caches/modules-2/metadata-2.16/module-metadata.bin) is corrupt. Discarding.
:growthrel-member-features-constants:checkNetworkDependencyConstraints SKIPPED
:growthrel-member-features-constants:compileJava
:checkNetworkDependencyConstraints SKIPPED
:growthrel-member-features-constants:compileJava UP-TO-DATE
:validateResolveHighest
:growthrel-member-features-constants:processResources UP-TO-DATE
:growthrel-member-features-constants:classes UP-TO-DATE
:growthrel-member-features-constants:checkForDuplicates
:check
:gatherArchiveMetadata
:growthrel-member-features-constants:confDepCombCheck
:growthrel-member-features-constants:compileTestJava UP-TO-DATE
:codeQualityConfig
:growthrel-member-features-constants:jar
:growthrel-member-features-constants:forkedCheckstyleMain UP-TO-DATE
:growthrel-member-features-constants:checkstyleMain SKIPPED
:growthrel-member-features-constants:checkstyle UP-TO-DATE
:growthrel-member-features-constants:findbugsMain
FAILURE: Build failed with an exception.

* What went wrong:
Could not resolve all dependencies for configuration ':growthrel-member-features-constants:findbugs'.
> Could not download findbugs.jar (com.google.code.findbugs:findbugs:3.0.0)
   > Could not read entry '3248e4200c3b5742954944552253fa8d:findbugs.jar (com.google.code.findbugs:findbugs:3.0.0)' from cache artifact-at-repository.bin (/export/home/tester/.gradle/caches/modules-2/metadata-2.16/artifact-at-repository.bin).

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.


BUILD FAILED

Total time: 32.402 secs