Interface CleanupPolicy
public interface CleanupPolicy
Configures the cleanup policy of the local build cache.
The specified values will take precedence over the values defined in the develocity.xml
.
- Since:
- 1.21
-
Method Summary
Modifier and TypeMethodDescriptionGets the local build cache cleanup interval.Gets the local build cache retention period.boolean
Gets whether the local build cache cleanup is enabled.void
setCleanupInterval
(Duration cleanupInterval) Sets the local build cache cleanup interval.void
setEnabled
(boolean enabled) Sets whether to enable the local build cache cleanup.void
setRetentionPeriod
(Duration retentionPeriod) Sets the local build cache cleanup retention period.
-
Method Details
-
isEnabled
boolean isEnabled()Gets whether the local build cache cleanup is enabled.- Returns:
true
if the local build cache cleanup is enabled,false
otherwise
-
setEnabled
void setEnabled(boolean enabled) Sets whether to enable the local build cache cleanup.Configuration via the
develocity.cache.local.cleanup.enabled
system property will always take precedence.- Parameters:
enabled
- whether to enable the local build cache cleanup
-
getRetentionPeriod
Duration getRetentionPeriod()Gets the local build cache retention period.- Returns:
- the local build cache cleanup retention period
-
setRetentionPeriod
Sets the local build cache cleanup retention period.Configuration via the
develocity.cache.local.cleanup.retention
system property will always take precedence.- Parameters:
retentionPeriod
- the local build cache cleanup retention period
-
getCleanupInterval
Duration getCleanupInterval()Gets the local build cache cleanup interval.- Returns:
- the local build cache cleanup interval
-
setCleanupInterval
Sets the local build cache cleanup interval.Configuration via the
develocity.cache.local.cleanup.interval
system property will always take precedence.- Parameters:
cleanupInterval
- the local build cache cleanup interval
-