atproto_repo/limits
Resource bounds for untrusted repository data. default is safe for a
getRecord proof and a modest full-repo CAR; raise a bound with the
builder functions when you know your input is larger.
- CAR bytes: 64 MiB, roughly a 100k-record repository.
- Blocks: 500,000 sections, record blocks plus the MST nodes above them.
- Block bytes: 1,000,000, the record size limit the sync spec states.
- MST entries per node: 256. Keys reach a deeper layer with probability 1/4, so a node of that width has odds near 0.75^256 for honest data; the repository spec asks for exactly such a “statistically unlikely maximum”.
Types
Limits
opaquepub opaque type Limits
Values
pub fn block_bytes(limits: Limits) -> Int
pub fn node_entries(limits: Limits) -> Int