api / org.gradle.caching.configuration / AbstractBuildCache

AbstractBuildCache

abstract class AbstractBuildCache : BuildCache

Base implementation for build cache service configuration.

Since
3.5

Constructors

<init>

AbstractBuildCache()

Base implementation for build cache service configuration.

Functions

isEnabled

open fun isEnabled(): Boolean

{@inheritDoc}

isPush

open fun isPush(): Boolean

{@inheritDoc}

setEnabled

open fun setEnabled(enabled: Boolean): Unit

{@inheritDoc}

setPush

open fun setPush(push: Boolean): Unit

{@inheritDoc}

Inheritors

DirectoryBuildCache

open class DirectoryBuildCache : AbstractBuildCache

Configuration object for the local directory build cache.

HttpBuildCache

open class HttpBuildCache : AbstractBuildCache

Configuration object for the HTTP build cache. The build cache only supports BASIC authentication currently.

Cache entries are loaded via GET and stored via PUT requests.

For a GET request we expect a 200 or 404 response and for PUT we expect any 2xx response. Other responses are treated as recoverable or non-recoverable errors, depending on the status code. E.g. we treat authentication failures (401 and 409) as non-recoverable while an internal server error (500) is recoverable.