Skip to content

Commit

Permalink
Add support for inlined compressed data in batch CAS operations
Browse files Browse the repository at this point in the history
This is a small API change which allows for inlined data to be
compressed form in BatchReadBlobs and BatchUpdateBlobs calls.

Refers to bazelbuild#201.
  • Loading branch information
mostynb committed Aug 12, 2021
1 parent 3e81645 commit d28535e
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions build/bazel/remote/execution/v2/remote_execution.proto
Original file line number Diff line number Diff line change
Expand Up @@ -1510,6 +1510,11 @@ message BatchUpdateBlobsRequest {

// The raw binary data.
bytes data = 2;

// The format of `data`. Must be `IDENTITY` (or unspecified), or one of the
// compressors advertised by the `CacheCapabilities.supported_compressor` if
// `CacheCapabilities.inlined_compressed_blobs` is true.
Compressor.Value compressor = 3;
}

// The instance of the execution system to operate against. A server may
Expand Down Expand Up @@ -1551,6 +1556,10 @@ message BatchReadBlobsRequest {

// The individual blob digests.
repeated Digest digests = 2;

// A list of acceptable encodings to used for inlined data. `IDENTITY`
// is always allowed even if not specified here.
repeated Compressor.Value acceptable_compressors = 3;
}

// A response message for
Expand All @@ -1564,6 +1573,10 @@ message BatchReadBlobsResponse {
// The raw binary data.
bytes data = 2;

// The format the data is encoded in. MUST be `IDENTITY` (or unspecified),
// or one of the acceptable compressors specified in the `BatchReadBlobsRequest`.
Compressor.Value compressor = 4;

// The result of attempting to download that blob.
google.rpc.Status status = 3;
}
Expand Down Expand Up @@ -1765,6 +1778,13 @@ message CacheCapabilities {
// Note that this does not imply which if any compressors are supported by
// the server at the gRPC level.
repeated Compressor.Value supported_compressors = 6;

// Compressors supported for inlined data in
// [BatchUpdateBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchUpdateBlobs]
// and
// [BatchReadBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchReadBlobs]
// requests and responses.
repeated Compressor.Value supported_batch_compressors = 7;
}

// Capabilities of the remote execution system.
Expand Down

0 comments on commit d28535e

Please sign in to comment.