about summary refs log tree commit diff
path: root/src/libstore/s3-binary-cache-store.cc
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2016-06-01T12·49+0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2016-06-01T14·24+0200
commit7850d3d27910c30232dd09dd86ee8afdaad26b90 (patch)
treeda539f14d98d815e89b6ad60ed8e1e1ab9981cbf /src/libstore/s3-binary-cache-store.cc
parent1b5b654fe25cf7f2219ebe96a943397d683bfa0e (diff)
Make the store directory a member variable of Store
Diffstat (limited to 'src/libstore/s3-binary-cache-store.cc')
-rw-r--r--src/libstore/s3-binary-cache-store.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstore/s3-binary-cache-store.cc b/src/libstore/s3-binary-cache-store.cc
index 371bf24fd419..33cc9659a0cd 100644
--- a/src/libstore/s3-binary-cache-store.cc
+++ b/src/libstore/s3-binary-cache-store.cc
@@ -47,7 +47,7 @@ struct S3BinaryCacheStoreImpl : public S3BinaryCacheStore
     Stats stats;
 
     S3BinaryCacheStoreImpl(
-        const StoreParams & params, const std::string & bucketName)
+        const Params & params, const std::string & bucketName)
         : S3BinaryCacheStore(params)
         , bucketName(bucketName)
         , config(makeConfig())
@@ -95,7 +95,7 @@ struct S3BinaryCacheStoreImpl : public S3BinaryCacheStore
 
             BinaryCacheStore::init();
 
-            diskCache->createCache(getUri(), wantMassQuery_, priority);
+            diskCache->createCache(getUri(), storeDir, wantMassQuery_, priority);
         }
     }
 
@@ -232,7 +232,7 @@ struct S3BinaryCacheStoreImpl : public S3BinaryCacheStore
             for (auto object : contents) {
                 auto & key = object.GetKey();
                 if (key.size() != 40 || !hasSuffix(key, ".narinfo")) continue;
-                paths.insert(settings.nixStore + "/" + key.substr(0, key.size() - 8));
+                paths.insert(storeDir + "/" + key.substr(0, key.size() - 8));
             }
 
             marker = res.GetNextMarker();
@@ -244,7 +244,7 @@ struct S3BinaryCacheStoreImpl : public S3BinaryCacheStore
 };
 
 static RegisterStoreImplementation regStore([](
-    const std::string & uri, const StoreParams & params)
+    const std::string & uri, const Store::Params & params)
     -> std::shared_ptr<Store>
 {
     if (std::string(uri, 0, 5) != "s3://") return 0;