implement AsyncSeek for AsyncIndexReader
Requires updating the AsyncRead implementation to cope with byte-wise seeks to intra-chunk positions. Uses chunk_from_offset to get locations within chunks, but tries to avoid it for sequential read to not reduce performance from before. AsyncSeek needs to use the temporary seek_to_pos to avoid changing the position in case an invalid seek is given and it needs to error in poll_complete. Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
This commit is contained in:
committed by
Thomas Lamprecht
parent
d0463b67ca
commit
ec5f9d3525
@ -1,6 +1,7 @@
|
||||
use std::collections::HashMap;
|
||||
use std::ops::Range;
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct ChunkReadInfo {
|
||||
pub range: Range<u64>,
|
||||
pub digest: [u8; 32],
|
||||
|
Reference in New Issue
Block a user