[GRADLE-462] Gradle doesn't clean up temp files Created: 27/Apr/09 Updated: 04/Jan/13 Resolved: 22/Aug/09 |
|
Status: | Resolved |
Project: | Gradle |
Affects Version/s: | None |
Fix Version/s: | 0.8 |
Type: | Bug | ||
Reporter: | Steve Appling | Assignee: | Steve Appling |
Resolution: | Fixed | Votes: | 0 |
Description |
After normal operations, Gradle leaves a large number of files in the user's temp directory. One of our developers had over 22,000 gradle_ivy_cache* directories. These are being created by DefaultResolverFactory.createTmpDir, but it wasn't obvious to me when it was safe to delete them. There are also a large number of groovy-generated-*-java-source directories that seem to be generated during gradle builds, but it is not obvious where this is being done. |
Comments |
Comment by Hans Dockter [ 01/May/09 ] |
The groovy-generated-*-java directories are produced by the Groovy's Ant Groovyc task. This means at the moment this is not in our hands (in the long term we want to get rid of all the internally used ant tasks). I'm not sure yet what to do about the gradle_ivy_cache dirs. Anyway, all of the dirs (including groovy-generated-...) can be deleted after a build. |
Comment by Steve Appling [ 29/Jun/09 ] |
I think this is causing us some performance issues over time. I had over 50,000 of these in my temp directory after about a month. This starts making creation of new temp files slower. It will not be obvious to people to manually clean this up. Can't the gradle_ivy_cache dirs be marked as delete on exit if you can't figure out when you are done with them? Is there any information we can read from the ant groovyc task with the new AntTaskAccess listener to know what directories to delete? I would like to see this fixed in 0.7 if possible. |
Comment by Steve Appling [ 30/Jul/09 ] |
There are 4 different types of garbage left in the temp directory:
|
Comment by Steve Appling [ 04/Aug/09 ] |
After some investigation:
|
Comment by Steve Appling [ 22/Aug/09 ] |
Removed the dumpCommand option from the TestNG samples. |
Comment by Steve Appling [ 22/Aug/09 ] |
The only issue left is the groovy-generated-* dirs. These are only caused by the GroovyProjectSampleIntegrationTest.groovy1_5_6Sample. In 1.5.6, these directories were not cleaned up correctly, but it isn't an issue any more. I'm closing this bug. |