0021666Delete empty parent dirs of deleted cache entries
Prior to this commit parent directories of deleted cache entries were not checked whether they're eligible for deletion. Now, parent directories that are now empty are checked up to the base directory. For the artifact transforms cache the following directories marked with (+) are now also deleted once all subdirectories (*) have been deleted: - files-1.1 - artifact-a (+) - hash 1 (*) - hash 1.1 - ... - hash 2 (*) - ... - ... (+) For the artifact cache: - modules-2 - files-2.1 - groupId (+) - artifactId (+) - version (+) - hash1 (*) - file - hash2 (*) - file - resources-2.1 - 0 (+) - hash 1 (*) - hash 2 (*) - ... - ... (+) Resolves gradle/gradle-private#1339. 584b91cDelete access times for deleted files from journal
When a file is deleted by the LeastRecentlyUsedCacheCleanup action, the corresponding entry is now removed from the used FileAccessTimeJournal in order to avoid storing obsolete entries that would never get removed. |
![]() |