BinaryCacheStore: Insert new paths into the disk cache

This commit is contained in:
Eelco Dolstra 2016-04-20 15:27:48 +02:00
parent 451ebf24ce
commit c0c4ddcd9c

View file

@ -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++;
}