BinaryCacheStore: Insert new paths into the disk cache
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#include "sync.hh"
|
||||
#include "worker-protocol.hh"
|
||||
#include "nar-accessor.hh"
|
||||
#include "nar-info-disk-cache.hh"
|
||||
|
||||
#include <chrono>
|
||||
|
||||
@@ -98,6 +99,9 @@ void BinaryCacheStore::addToCache(const ValidPathInfo & info,
|
||||
state_->pathInfoCache.upsert(narInfo->path, std::shared_ptr<NarInfo>(narInfo));
|
||||
}
|
||||
|
||||
if (diskCache)
|
||||
diskCache->upsertNarInfo(getUri(), std::shared_ptr<NarInfo>(narInfo));
|
||||
|
||||
stats.narInfoWrite++;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user