Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement disk-based DataCache with no eviction (#593)
* Implement disk-based DataCache with no checksums or eviction Signed-off-by: Daniel Carl Jones <[email protected]> * Fix typos Signed-off-by: Daniel Carl Jones <[email protected]> * Replace Base64URL encoding with Base64URLUnpadded encoding for data cache Signed-off-by: Daniel Carl Jones <[email protected]> * Ensure cached indicies are sorted in DiskDataCache Signed-off-by: Daniel Carl Jones <[email protected]> * Add trace message when creating block in cache Signed-off-by: Daniel Carl Jones <[email protected]> * WIP: Add checksums to on-disk cache Signed-off-by: Daniel Carl Jones <[email protected]> * Remove cached_block_indices implementation on DiskDataCache Signed-off-by: Daniel Carl Jones <[email protected]> * Move version identifier to constant Signed-off-by: Daniel Carl Jones <[email protected]> * Replace SerializableCrc32c with u32 Signed-off-by: Daniel Carl Jones <[email protected]> * Update DataBlock::new(..) to return Result Signed-off-by: Daniel Carl Jones <[email protected]> * Add verification of block metadata to unpack after reading Signed-off-by: Daniel Carl Jones <[email protected]> * Replace Base64 encoding with SHA256 hash Signed-off-by: Daniel Carl Jones <[email protected]> * Add TODO to split directories into sub-directories to avoid hitting any FS-specific max number of dir entries Signed-off-by: Daniel Carl Jones <[email protected]> * Remove intermediate buffers when (de)serializing DataBlock with bincode Signed-off-by: Daniel Carl Jones <[email protected]> * Add cache version identifer to the start of blocks written to disk Signed-off-by: Daniel Carl Jones <[email protected]> * Fix comment on ETag::into_inner Signed-off-by: Daniel Carl Jones <[email protected]> * Add rustdoc to DataBlock::new Signed-off-by: Daniel Carl Jones <[email protected]> * Fix typo in rustdoc for DataBlock::data Signed-off-by: Daniel Carl Jones <[email protected]> * Add expected version to data block read error message Signed-off-by: Daniel Carl Jones <[email protected]> * Split DataBlock header fields into BlockHeader Signed-off-by: Daniel Carl Jones <[email protected]> * Add checksum validation on on-disk cache DataBlock header contents Signed-off-by: Daniel Carl Jones <[email protected]> * Remove outdated TODO Signed-off-by: Daniel Carl Jones <[email protected]> * Add test for detecting when DataBlock requires version bump Signed-off-by: Daniel Carl Jones <[email protected]> * Refactor errors for DataBlock Signed-off-by: Daniel Carl Jones <[email protected]> * Rename DataBlock to DiskBlock Signed-off-by: Daniel Carl Jones <[email protected]> --------- Signed-off-by: Daniel Carl Jones <[email protected]>
- Loading branch information