Implement listener for serving repairs through Repairman protocol (#4306)

* Make listener for serving repairs through Repairman protocol
This commit is contained in:
carllin
2019-05-23 03:10:16 -07:00
committed by GitHub
parent 2ed77b040a
commit 591fd72e0b
5 changed files with 908 additions and 6 deletions

View File

@@ -203,7 +203,7 @@ impl Blocktree {
pub fn slot_data_iterator(
&self,
slot: u64,
) -> Result<impl Iterator<Item = ((u64, u64), Vec<u8>)>> {
) -> Result<impl Iterator<Item = ((u64, u64), Box<[u8]>)>> {
let slot_iterator = self.db.iter::<cf::Data>(Some((slot, 0)))?;
Ok(slot_iterator.take_while(move |((blob_slot, _), _)| *blob_slot == slot))
}