pub struct BlockDownloaderConfig {
pub buffer_bytes: usize,
pub in_progress_queue_bytes: usize,
pub check_client_pool_interval: Duration,
pub target_batch_bytes: usize,
pub initial_batch_len: usize,
}Expand description
The block downloader config.
Fields§
§buffer_bytes: usizeThe size in bytes of the buffer between the block downloader and the place which is consuming the downloaded blocks.
in_progress_queue_bytes: usizeThe size of the in progress queue (in bytes) at which we stop requesting more blocks.
check_client_pool_interval: DurationThe Duration between checking the client pool for free peers.
target_batch_bytes: usizeThe target size of a single batch of blocks (in bytes).
initial_batch_len: usizeThe initial amount of blocks to request (in number of blocks)
Trait Implementations§
Source§impl Clone for BlockDownloaderConfig
impl Clone for BlockDownloaderConfig
Source§fn clone(&self) -> BlockDownloaderConfig
fn clone(&self) -> BlockDownloaderConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for BlockDownloaderConfig
Source§impl Debug for BlockDownloaderConfig
impl Debug for BlockDownloaderConfig
impl Eq for BlockDownloaderConfig
Source§impl Ord for BlockDownloaderConfig
impl Ord for BlockDownloaderConfig
Source§fn cmp(&self, other: &BlockDownloaderConfig) -> Ordering
fn cmp(&self, other: &BlockDownloaderConfig) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for BlockDownloaderConfig
impl PartialEq for BlockDownloaderConfig
Source§impl PartialOrd for BlockDownloaderConfig
impl PartialOrd for BlockDownloaderConfig
impl StructuralPartialEq for BlockDownloaderConfig
Auto Trait Implementations§
impl Freeze for BlockDownloaderConfig
impl RefUnwindSafe for BlockDownloaderConfig
impl Send for BlockDownloaderConfig
impl Sync for BlockDownloaderConfig
impl Unpin for BlockDownloaderConfig
impl UnsafeUnpin for BlockDownloaderConfig
impl UnwindSafe for BlockDownloaderConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
§fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 48 bytes