After uploading a .narinfo, add it to the LRU cache
[?]
Feb 20, 2016, 9:35 AM
RITB7JRKWI5CLS5FKLMKEVYZX7UJ5BKOLLVD7YDKMBPFPYLQ37BQCDependencies
- [2]
SOB276BAKeep some statistics for the binary cache stores - [3]
MBZRPJTZFix log message - [4]
GTUZLZRHAdd an S3-backed binary cache store - [5]
73YR46NJhydra-queue-runner: Write directly to a binary cache - [6]
3FQ65IXOhydra-queue-runner: Compress binary cache NARs using xz - [7]
N2NKSKHSRefactor local binary cache code into a subclass - [8]
32HHP5CWhydra-queue-runner: Support generating a signed binary cache
Change contents
- replacement in src/hydra-queue-runner/binary-cache-store.cc at line 53
NarInfo narInfo(info);auto narInfo = make_ref<NarInfo>(info); - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 55
narInfo.narSize = nar.size();narInfo.narHash = hashString(htSHA256, nar);narInfo->narSize = nar.size();narInfo->narHash = hashString(htSHA256, nar); - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 58
if (info.narHash.type != htUnknown && info.narHash != narInfo.narHash)if (info.narHash.type != htUnknown && info.narHash != narInfo->narHash) - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 62
narInfo.compression = "xz";narInfo->compression = "xz"; - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 66
narInfo.fileHash = hashString(htSHA256, narXz);narInfo.fileSize = narXz.size();narInfo->fileHash = hashString(htSHA256, narXz);narInfo->fileSize = narXz.size(); - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 71
% narInfo.path % narInfo.narSize% narInfo->path % narInfo->narSize - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 76
narInfo.url = "nar/" + printHash32(narInfo.fileHash) + ".nar.xz";if (!fileExists(narInfo.url)) {narInfo->url = "nar/" + printHash32(narInfo->fileHash) + ".nar.xz";if (!fileExists(narInfo->url)) { - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 79
upsertFile(narInfo.url, narXz);upsertFile(narInfo->url, narXz); - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 88
if (secretKey) narInfo.sign(*secretKey);if (secretKey) narInfo->sign(*secretKey); - replacement in src/hydra-queue-runner/binary-cache-store.cc at line 90
upsertFile(narInfoFile, narInfo.to_string());upsertFile(narInfoFile, narInfo->to_string());{auto state_(state.lock());state_->narInfoCache.upsert(narInfo->path, narInfo);stats.narInfoCacheSize = state_->narInfoCache.size();}