aboutsummaryrefslogtreecommitdiffstats
path: root/src/transport/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/transport/mod.rs')
-rw-r--r--src/transport/mod.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/transport/mod.rs b/src/transport/mod.rs
index 1e9e5a9..eeb9d34 100644
--- a/src/transport/mod.rs
+++ b/src/transport/mod.rs
@@ -322,6 +322,13 @@ pub(crate) enum BlobBody {
},
/// The sender doesn't have the blob.
Missing,
+ /// A chunk, deflated (`compress`): the receiver inflates it to the chunk, which the
+ /// manifest's hash is of, whoever sent it.
+ DeflatedChunk {
+ index: u32,
+ #[serde(with = "crate::transport::wire::codec::shared_bytes")]
+ data: bytes::Bytes,
+ },
}
/// Sizes instead of contents: logged messages stay short.
@@ -349,6 +356,11 @@ impl std::fmt::Debug for BlobBody {
.field("bytes", &data.len())
.finish(),
BlobBody::Missing => f.write_str("Missing"),
+ BlobBody::DeflatedChunk { index, data } => f
+ .debug_struct("DeflatedChunk")
+ .field("index", index)
+ .field("bytes", &data.len())
+ .finish(),
}
}
}