Skip to content

Commit cefd18f

Browse files
committed
Reduce debug on all Batch* structs
1 parent 3f6ab07 commit cefd18f

2 files changed

Lines changed: 16 additions & 8 deletions

File tree

nativelink-proto/gen_protos_tool.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,10 @@ fn main() -> std::io::Result<()> {
3131
config.bytes(["."]);
3232

3333
let mut structs_with_data_to_ignore = HashMap::new();
34-
structs_with_data_to_ignore.insert("BatchReadBlobsResponse.Response", vec!["data"]);
35-
structs_with_data_to_ignore.insert("BatchUpdateBlobsRequest.Request", vec!["data"]);
34+
structs_with_data_to_ignore.insert("BatchReadBlobsRequest", vec!["digests"]);
35+
structs_with_data_to_ignore.insert("BatchReadBlobsResponse", vec!["responses"]);
36+
structs_with_data_to_ignore.insert("BatchUpdateBlobsRequest", vec!["requests"]);
37+
structs_with_data_to_ignore.insert("BatchUpdateBlobsResponse", vec!["responses"]);
3638
structs_with_data_to_ignore.insert("ReadResponse", vec!["data"]);
3739
structs_with_data_to_ignore.insert("WriteRequest", vec!["data"]);
3840
structs_with_data_to_ignore.insert("ActionResult", vec!["output_files"]);

nativelink-proto/genproto/build.bazel.remote.execution.v2.pb.rs

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1246,7 +1246,9 @@ pub struct FindMissingBlobsResponse {
12461246
}
12471247
/// A request message for
12481248
/// [ContentAddressableStorage.BatchUpdateBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchUpdateBlobs].
1249+
#[derive(::derive_more::Debug)]
12491250
#[derive(Clone, PartialEq, ::prost::Message)]
1251+
#[prost(skip_debug)]
12501252
pub struct BatchUpdateBlobsRequest {
12511253
/// The instance of the execution system to operate against. A server may
12521254
/// support multiple instances of the execution system (with their own workers,
@@ -1257,6 +1259,7 @@ pub struct BatchUpdateBlobsRequest {
12571259
pub instance_name: ::prost::alloc::string::String,
12581260
/// The individual upload requests.
12591261
#[prost(message, repeated, tag = "2")]
1262+
#[debug(ignore)]
12601263
pub requests: ::prost::alloc::vec::Vec<batch_update_blobs_request::Request>,
12611264
/// The digest function that was used to compute the digests of the
12621265
/// blobs being uploaded.
@@ -1272,17 +1275,14 @@ pub struct BatchUpdateBlobsRequest {
12721275
/// Nested message and enum types in `BatchUpdateBlobsRequest`.
12731276
pub mod batch_update_blobs_request {
12741277
/// A request corresponding to a single blob that the client wants to upload.
1275-
#[derive(::derive_more::Debug)]
12761278
#[derive(Clone, PartialEq, ::prost::Message)]
1277-
#[prost(skip_debug)]
12781279
pub struct Request {
12791280
/// The digest of the blob. This MUST be the digest of `data`. All
12801281
/// digests MUST use the same digest function.
12811282
#[prost(message, optional, tag = "1")]
12821283
pub digest: ::core::option::Option<super::Digest>,
12831284
/// The raw binary data.
12841285
#[prost(bytes = "bytes", tag = "2")]
1285-
#[debug(ignore)]
12861286
pub data: ::prost::bytes::Bytes,
12871287
/// The format of `data`. Must be `IDENTITY`/unspecified, or one of the
12881288
/// compressors advertised by the
@@ -1294,10 +1294,13 @@ pub mod batch_update_blobs_request {
12941294
}
12951295
/// A response message for
12961296
/// [ContentAddressableStorage.BatchUpdateBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchUpdateBlobs].
1297+
#[derive(::derive_more::Debug)]
12971298
#[derive(Clone, PartialEq, ::prost::Message)]
1299+
#[prost(skip_debug)]
12981300
pub struct BatchUpdateBlobsResponse {
12991301
/// The responses to the requests.
13001302
#[prost(message, repeated, tag = "1")]
1303+
#[debug(ignore)]
13011304
pub responses: ::prost::alloc::vec::Vec<batch_update_blobs_response::Response>,
13021305
}
13031306
/// Nested message and enum types in `BatchUpdateBlobsResponse`.
@@ -1317,7 +1320,9 @@ pub mod batch_update_blobs_response {
13171320
}
13181321
/// A request message for
13191322
/// [ContentAddressableStorage.BatchReadBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchReadBlobs].
1323+
#[derive(::derive_more::Debug)]
13201324
#[derive(Clone, PartialEq, ::prost::Message)]
1325+
#[prost(skip_debug)]
13211326
pub struct BatchReadBlobsRequest {
13221327
/// The instance of the execution system to operate against. A server may
13231328
/// support multiple instances of the execution system (with their own workers,
@@ -1329,6 +1334,7 @@ pub struct BatchReadBlobsRequest {
13291334
/// The individual blob digests. All digests MUST use the same digest
13301335
/// function.
13311336
#[prost(message, repeated, tag = "2")]
1337+
#[debug(ignore)]
13321338
pub digests: ::prost::alloc::vec::Vec<Digest>,
13331339
/// A list of acceptable encodings for the returned inlined data, in no
13341340
/// particular order. `IDENTITY` is always allowed even if not specified here.
@@ -1346,25 +1352,25 @@ pub struct BatchReadBlobsRequest {
13461352
}
13471353
/// A response message for
13481354
/// [ContentAddressableStorage.BatchReadBlobs][build.bazel.remote.execution.v2.ContentAddressableStorage.BatchReadBlobs].
1355+
#[derive(::derive_more::Debug)]
13491356
#[derive(Clone, PartialEq, ::prost::Message)]
1357+
#[prost(skip_debug)]
13501358
pub struct BatchReadBlobsResponse {
13511359
/// The responses to the requests.
13521360
#[prost(message, repeated, tag = "1")]
1361+
#[debug(ignore)]
13531362
pub responses: ::prost::alloc::vec::Vec<batch_read_blobs_response::Response>,
13541363
}
13551364
/// Nested message and enum types in `BatchReadBlobsResponse`.
13561365
pub mod batch_read_blobs_response {
13571366
/// A response corresponding to a single blob that the client tried to download.
1358-
#[derive(::derive_more::Debug)]
13591367
#[derive(Clone, PartialEq, ::prost::Message)]
1360-
#[prost(skip_debug)]
13611368
pub struct Response {
13621369
/// The digest to which this response corresponds.
13631370
#[prost(message, optional, tag = "1")]
13641371
pub digest: ::core::option::Option<super::Digest>,
13651372
/// The raw binary data.
13661373
#[prost(bytes = "bytes", tag = "2")]
1367-
#[debug(ignore)]
13681374
pub data: ::prost::bytes::Bytes,
13691375
/// The format the data is encoded in. MUST be `IDENTITY`/unspecified,
13701376
/// or one of the acceptable compressors specified in the `BatchReadBlobsRequest`.

0 commit comments

Comments
 (0)