about summary refs log tree commit diff
path: root/third_party/nix/src/proto
diff options
context:
space:
mode:
authorGriffin Smith <grfn@gws.fyi>2020-08-06T02·46-0400
committerglittershark <grfn@gws.fyi>2020-08-08T17·51+0000
commit7db734afad313b8669623138130797fad797daa7 (patch)
tree7acf1dd3f641e47513d6beafe68344909d3115c7 /third_party/nix/src/proto
parentcc01059d405e982e3a7de78e318374c3dbace48b (diff)
feat(tvix): Implement AddToStoreNar r/1615
Implement both the client and server sides of AddToStoreNar, using a
templated generalization of the sources and sinks we were using for
AddToStore on both ends.

Change-Id: I73d0ed34118c711b125851dff99a7518ced4af35
Reviewed-on: https://cl.tvl.fyi/c/depot/+/1686
Tested-by: BuildkiteCI
Reviewed-by: kanepyork <rikingcoding@gmail.com>
Diffstat (limited to 'third_party/nix/src/proto')
-rw-r--r--third_party/nix/src/proto/worker.proto10
1 files changed, 8 insertions, 2 deletions
diff --git a/third_party/nix/src/proto/worker.proto b/third_party/nix/src/proto/worker.proto
index abe8f622c9f2..cc5be46d6ba7 100644
--- a/third_party/nix/src/proto/worker.proto
+++ b/third_party/nix/src/proto/worker.proto
@@ -33,6 +33,8 @@ service WorkerService {
   rpc EnsurePath(StorePath) returns (google.protobuf.Empty);
 
   // TODO: What does this do?
+  // TODO(grfn): This should not actually take a StorePath, as it's not a
+  // StorePath
   rpc AddTempRoot(StorePath) returns (google.protobuf.Empty);
 
   // TODO: What does this do?
@@ -260,6 +262,10 @@ message PathInfo {
   repeated string sigs = 7;
   // If non-empty, an assertion that the path is content-addressed
   string ca = 8;
+
+  // Only used for AddToStoreNarRequest
+  bool repair = 12;
+  bool check_sigs = 13;
 }
 
 message SubstitutablePathInfos {
@@ -318,9 +324,9 @@ message AddSignaturesRequest {
 }
 
 message AddToStoreNarRequest {
-  oneof add_oneoff {
+  oneof add_oneof {
     PathInfo path_info = 1;
-    bytes chunk = 2;
+    bytes data = 2;
   }
 }