ActionCache

sbt.util.ActionCache
object ActionCache

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def cache[I : HashWriter, O : ClassTag](key: I, codeContentHash: Digest, extraHash: Digest, tags: List[CacheLevelTag])(action: I => (O, Seq[VirtualFile]))(config: BuildWideCacheConfiguration): O

This is a key function that drives remote caching. This is intended to be called from the cached task macro for the most part.

This is a key function that drives remote caching. This is intended to be called from the cached task macro for the most part.

  • key: This represents the input key for this action, typically consists of all the input into the action. For the purpose of caching, all we need from the input is to generate some hash value.
  • codeContentHash: This hash represents the Scala code of the task. Even if the input tasks are the same, the code part needs to be tracked.
  • extraHash: Reserved for later, which we might use to invalidate the cache.
  • tags: Tags to track cache level.
  • action: The actual action to be cached.
  • config: The configuration that's used to store where the cache backends are.

Attributes