mirror of https://github.com/sbt/sbt.git
Rename cacheStoreFactory attribute
It references a CacheStoreFactoryFactory so it should have been named accordingly.
This commit is contained in:
parent
6865f32eae
commit
a7715e90a4
|
|
@ -2772,7 +2772,8 @@ object Classpaths {
|
||||||
|
|
||||||
import CacheStoreFactory.jvalueIsoString
|
import CacheStoreFactory.jvalueIsoString
|
||||||
val cacheStoreFactory: CacheStoreFactory = {
|
val cacheStoreFactory: CacheStoreFactory = {
|
||||||
val factory = state.value.get(Keys.cacheStoreFactory).getOrElse(InMemoryCacheStore.factory(0))
|
val factory =
|
||||||
|
state.value.get(Keys.cacheStoreFactoryFactory).getOrElse(InMemoryCacheStore.factory(0))
|
||||||
factory(cacheDirectory.toPath, Converter)
|
factory(cacheDirectory.toPath, Converter)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -491,7 +491,7 @@ object Keys {
|
||||||
val pluginData = taskKey[PluginData]("Information from the plugin build needed in the main build definition.").withRank(DTask)
|
val pluginData = taskKey[PluginData]("Information from the plugin build needed in the main build definition.").withRank(DTask)
|
||||||
val globalPluginUpdate = taskKey[UpdateReport]("A hook to get the UpdateReport of the global plugin.").withRank(DTask)
|
val globalPluginUpdate = taskKey[UpdateReport]("A hook to get the UpdateReport of the global plugin.").withRank(DTask)
|
||||||
private[sbt] val taskCancelStrategy = settingKey[State => TaskCancellationStrategy]("Experimental task cancellation handler.").withRank(DTask)
|
private[sbt] val taskCancelStrategy = settingKey[State => TaskCancellationStrategy]("Experimental task cancellation handler.").withRank(DTask)
|
||||||
private[sbt] val cacheStoreFactory = AttributeKey[CacheStoreFactoryFactory]("cache-store-factory")
|
private[sbt] val cacheStoreFactoryFactory = AttributeKey[CacheStoreFactoryFactory]("cache-store-factory-factory")
|
||||||
val fileCacheSize = settingKey[String]("The approximate maximum size in bytes of the cache used to store previous task results. For example, it could be set to \"256M\" to make the maximum size 256 megabytes.")
|
val fileCacheSize = settingKey[String]("The approximate maximum size in bytes of the cache used to store previous task results. For example, it could be set to \"256M\" to make the maximum size 256 megabytes.")
|
||||||
|
|
||||||
// Experimental in sbt 0.13.2 to enable grabbing semantic compile failures.
|
// Experimental in sbt 0.13.2 to enable grabbing semantic compile failures.
|
||||||
|
|
|
||||||
|
|
@ -852,8 +852,8 @@ object BuiltinCommands {
|
||||||
.getOpt(Keys.fileCacheSize)
|
.getOpt(Keys.fileCacheSize)
|
||||||
.flatMap(SizeParser(_))
|
.flatMap(SizeParser(_))
|
||||||
.getOrElse(SysProp.fileCacheSize)
|
.getOrElse(SysProp.fileCacheSize)
|
||||||
s.get(Keys.cacheStoreFactory).foreach(_.close())
|
s.get(Keys.cacheStoreFactoryFactory).foreach(_.close())
|
||||||
s.put(Keys.cacheStoreFactory, InMemoryCacheStore.factory(size))
|
s.put(Keys.cacheStoreFactoryFactory, InMemoryCacheStore.factory(size))
|
||||||
}
|
}
|
||||||
|
|
||||||
def registerCompilerCache(s: State): State = {
|
def registerCompilerCache(s: State): State = {
|
||||||
|
|
|
||||||
|
|
@ -308,7 +308,8 @@ object BuildStreams {
|
||||||
displayFull,
|
displayFull,
|
||||||
LogManager.construct(data, s),
|
LogManager.construct(data, s),
|
||||||
sjsonnew.support.scalajson.unsafe.Converter, {
|
sjsonnew.support.scalajson.unsafe.Converter, {
|
||||||
val factory = s.get(Keys.cacheStoreFactory).getOrElse(InMemoryCacheStore.factory(0))
|
val factory =
|
||||||
|
s.get(Keys.cacheStoreFactoryFactory).getOrElse(InMemoryCacheStore.factory(0))
|
||||||
(file, converter: SupportConverter[JValue]) => factory(file.toPath, converter)
|
(file, converter: SupportConverter[JValue]) => factory(file.toPath, converter)
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue