CompositeCleanupActionTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Report deleted and skipped cache entries

This commit introduces `CleanupProgressMonitor` and a default

`ProgressLogger`-based implementation that tracks the total number of

deleted and skipped cache entries. `CleanupAction.clean()` now takes a

monitor as an additional argument. `DefaultPersistentDirectoryStore`

creates the default implementation and passes it to its `CleanupAction`.

  1. … 14 more files in changeset.
Make cache cleanup non-incremental

    • -29
    • +3
    ./CompositeCleanupActionTest.groovy
  1. … 14 more files in changeset.
Implement cleanup of shared versioned caches

`UnusedVersionsCacheCleanup` now extends `AbstractCacheCleanup` to reuse

its timeout checking and to make it usable as a `CleanupAction` for a

`PersistentCache`. `CompositeCleanupAction` now allows to use multiple

top-level `CleanupActions`.

    • -10
    • +9
    ./CompositeCleanupActionTest.groovy
  1. … 9 more files in changeset.
Enable incremental cache cleanup

Instead of computing the complete list of eligible files at once,

SingleDepthFileFinder now returns an Iterable that creates an

Iterator that will incrementally walk the file tree.

In addition, the CleanupAction.clean() operation now takes a

CountdownTimer and implementations periodically check whether the timer

has expired. If so, the current cleanup will be aborted.

DefaultPersistentDirectoryCache now uses a timeout of 20 seconds which

is well below the file locking timeout of 60 seconds.

The marker file (gc.properties) will only be updated if the complete

cleanup was able to finish without expiring the timeout.

    • -0
    • +81
    ./CompositeCleanupActionTest.groovy
  1. … 13 more files in changeset.