Expand description
Wire types for the swarm-ready artifact piece protocol (ADR-099 section 6, mesh-placement-11).
An artifact is identified by the root hash over its ordered piece list
(ArtifactDescriptor::id), not by the node it came from. Pieces are
fixed-size (64 MiB placeholder) and pinned by BLAKE3. Pieces travel in
blocks, because a piece is larger than one frame.
Frame 0x0B (FrameType::ArtifactRequest) carries control messages
(meta_request, announce, request); frame 0x0C
(FrameType::ArtifactResponse) carries data (meta, piece,
no_piece, reject). Every frame is capped at MAX_ARTIFACT_FRAME
payload bytes; there is no ceiling on the artifact’s total size.
The encoding is a small, strict binary layout (big-endian integers, 32-byte hashes, no trailing bytes) so piece data is never re-encoded.
Re-exports§
pub use crate::mesh_artifact_types::ArtifactDescriptor;pub use crate::mesh_artifact_types::ArtifactId;pub use crate::mesh_artifact_types::ArtifactKey;pub use crate::mesh_artifact_types::Bitfield;pub use crate::mesh_artifact_types::DEFAULT_BLOCK_SIZE;pub use crate::mesh_artifact_types::DEFAULT_PIECE_SIZE;pub use crate::mesh_artifact_types::MAX_ARTIFACT_FRAME;pub use crate::mesh_artifact_types::MAX_PIECE_SIZE;pub use crate::mesh_artifact_types::MAX_REASON_BYTES;pub use crate::mesh_artifact_types::MAX_REQUEST_PIECES;pub use crate::mesh_artifact_types::MIN_PIECE_SIZE;pub use crate::mesh_artifact_types::WireError;
Enums§
- Artifact
Msg - One artifact-protocol message.