feat(3p/nix): Add proto for QueryPathInfo

Change-Id: I10ec338ef2d5360954abdc5bb3d4789f34b031fc
Reviewed-on: https://cl.tvl.fyi/c/depot/+/1200
Reviewed-by: tazjin <mail@tazj.in>
Tested-by: BuildkiteCI
This commit is contained in:
Griffin Smith 2020-07-15 21:42:34 -04:00 committed by glittershark
parent 0386fad78f
commit 17c0962802

View file

@ -1,6 +1,7 @@
syntax = "proto3";
import "google/protobuf/empty.proto";
import "google/protobuf/timestamp.proto";
package nix.proto;
@ -58,6 +59,9 @@ service Worker {
// Query all valid paths in the store
rpc QueryAllValidPaths(google.protobuf.Empty) returns (StorePaths);
// TODO: What does this do?
rpc QueryPathInfo(StorePath) returns (QueryPathInfoResponse);
}
enum HashType {
@ -194,3 +198,17 @@ message SubstitutablePathInfos {
repeated PathInfo path_infos = 1;
}
message QueryPathInfoResponse {
StorePath deriver = 1;
string nar_hash = 2;
repeated string references = 3;
google.protobuf.Timestamp registration_time = 4;
uint64 nar_size = 5;
// Whether the path is ultimately trusted, that is, it's a derivation
// output that was built locally.
bool ultimate = 6;
repeated string sigs = 7;
// If non-empty, an assertion that the path is content-addressed
string ca = 8;
};