Expand description
This crate provides an encoder/decoder for Reed-Solomon erasure code.
Please note that erasure coding means errors are not directly detected or corrected, but missing data pieces (shards) can be reconstructed given that the configuration provides high enough redundancy.
You will have to implement error detection separately (e.g. via checksums) and simply leave out the corrupted shards when attempting to reconstruct the missing data.
Modules§
- galois_
8 - Implementation of GF(2^8): the finite field with 2^8 elements.
- galois_
16 - GF(2^16) implementation.
- stream
- Streaming encode/verify/reconstruct for large data.
Macros§
- convert_
2D_ slices - Makes it easier to work with 2D slices, arrays, etc.
- shards
- Constructs vector of shards.
Structs§
- Codec
Options - Configuration options for constructing a
ReedSolomoncodec. - Leopard
Gf8Profile Stats - Parallel
Decision - Parallel
Policy - Reconstruction
Cache Analysis - Reconstruction
Cache Stats - Reed
Solomon - Runtime
Profile Stats - Shard
ByShard - Bookkeeper for shard by shard encoding.
- Shard
Slot - A reusable shard container for reconstruction workflows.
- Verify
Workspace - Reusable parity scratch space for repeated verify calls.
Enums§
- Codec
Family - Selects the codec algorithm family for encoding and reconstruction.
- Error
- Leopard
Mode - Controls optional automatic selection of a Leopard codec when the requested
CodecFamilyisClassic. - Matrix
Mode - Selects the encoding matrix construction strategy for
CodecFamily::Classic. - SBSError
Constants§
- LEOPARD_
SHARD_ MULTIPLE - Required byte multiple (and cache-line alignment) of every Leopard shard.
- PARALLEL_
POLICY_ VERSION
Traits§
- Field
- A finite field to perform encoding over.
- Reconstruct
Shard - Something which might hold a shard.
Functions§
- leopard_
aligned_ shard_ len - Computes a per-shard length, in bytes, that Leopard will accept for a payload
of
data_lenbytes spread acrossdata_shardsdata shards. - leopard_
gf8_ profile_ stats - reset_
leopard_ gf8_ profile_ stats