Module request

Source
Expand description

Utilities to generate or execute complex get requests without persisting to a store.

Any complex request can be executed with downloading to a store, using the crate::api::remote::Remote::execute_get method. But for some requests it is useful to just get the data without persisting it to a store.

In addition to these utilities, there are also constructors in crate::protocol::ChunkRangesSeq to construct complex requests.

Structs§

GetBlobResult
Result of a get_blob request.

Enums§

GetBlobItem
A single item in a GetBlobResult.

Functions§

get_blob
get_chunk_probe
Probe for a single chunk of a blob.
get_hash_seq_and_sizes
Given a hash of a hash seq, get the hash seq and the verified sizes of its children.
get_unverified_size
Get the claimed size of a blob from a peer.
get_verified_size
Get the verified size of a blob from a peer.
random_hash_seq_ranges
Given a sequence of sizes of children, generate a range spec that selects a random chunk of a random child.