Skip to main content

SlotWorker

Struct SlotWorker 

Source
pub struct SlotWorker<PosTable, BP, BCI, CSS> { /* private fields */ }
Expand description

Slot worker responsible for block production

Implementations§

Source§

impl<PosTable, BP, BCI, CSS> SlotWorker<PosTable, BP, BCI, CSS>
where PosTable: Table, BP: BlockProducer, BCI: ChainInfo<OwnedBeaconChainBlock>, CSS: ChainSyncStatus,

Source

pub fn new(_: SlotWorkerOptions<BP, BCI, CSS>) -> Self

Create a new slot worker

Source

pub async fn run(self, slot_info_stream: PotSlotInfoStream)

Run slot worker

Trait Implementations§

Source§

impl<PosTable: Debug, BP: Debug, BCI: Debug, CSS: Debug> Debug for SlotWorker<PosTable, BP, BCI, CSS>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<PosTable, BP, BCI, CSS> !RefUnwindSafe for SlotWorker<PosTable, BP, BCI, CSS>

§

impl<PosTable, BP, BCI, CSS> !UnwindSafe for SlotWorker<PosTable, BP, BCI, CSS>

§

impl<PosTable, BP, BCI, CSS> Forget for SlotWorker<PosTable, BP, BCI, CSS>

§

impl<PosTable, BP, BCI, CSS> Freeze for SlotWorker<PosTable, BP, BCI, CSS>
where BP: Freeze, BCI: Freeze, CSS: Freeze, *const ArcInner<BoundedInner<NewSlotNotification>> is !null: Freeze, PhantomData<ArcInner<BoundedInner<NewSlotNotification>>>: Freeze, *const ArcInner<Mutex<SenderTask>> is !null: Freeze, PhantomData<ArcInner<Mutex<SenderTask>>>: Freeze, *const ArcInner<BoundedInner<BlockSealNotification>> is !null: Freeze, PhantomData<ArcInner<BoundedInner<BlockSealNotification>>>: Freeze, *const LeafNode<SlotNumber, (SolutionParameters, Receiver<Solution>)> is !null: Freeze, PhantomData<(Owned, LeafOrInternal)>: Freeze, PhantomData<Box<(SlotNumber, (SolutionParameters, Receiver<Solution>))>>: Freeze, *const LeafNode<SlotNumber, PotCheckpoints> is !null: Freeze, PhantomData<Box<(SlotNumber, PotCheckpoints)>>: Freeze, NonZero<u8>: Freeze, *const ArcInner<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>> is !null: Freeze, PhantomData<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>>: Freeze, PhantomData<PosTable>: Freeze,

§

impl<PosTable, BP, BCI, CSS> Move for SlotWorker<PosTable, BP, BCI, CSS>

§

impl<PosTable, BP, BCI, CSS> Send for SlotWorker<PosTable, BP, BCI, CSS>
where CSS: Send, BCI: Send, BP: Send, PosTable: Send, Arc<BoundedInner<NewSlotNotification>>: Send, Arc<Mutex<SenderTask>>: Send, Arc<BoundedInner<BlockSealNotification>>: Send, NodeRef<Owned, SlotNumber, (SolutionParameters, Receiver<Solution>), LeafOrInternal>: Send, BoxRaw<(SlotNumber, (SolutionParameters, Receiver<Solution>))>: Send, NodeRef<Owned, SlotNumber, PotCheckpoints, LeafOrInternal>: Send, BoxRaw<(SlotNumber, PotCheckpoints)>: Send, NonZero<u8>: Send, Arc<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>>: Send,

§

impl<PosTable, BP, BCI, CSS> Sync for SlotWorker<PosTable, BP, BCI, CSS>
where CSS: Sync, BCI: Sync, BP: Sync, PosTable: Sync, Arc<BoundedInner<NewSlotNotification>>: Sync, Arc<Mutex<SenderTask>>: Sync, Arc<BoundedInner<BlockSealNotification>>: Sync, NodeRef<Owned, SlotNumber, (SolutionParameters, Receiver<Solution>), LeafOrInternal>: Sync, BoxRaw<(SlotNumber, (SolutionParameters, Receiver<Solution>))>: Sync, NodeRef<Owned, SlotNumber, PotCheckpoints, LeafOrInternal>: Sync, BoxRaw<(SlotNumber, PotCheckpoints)>: Sync, NonZero<u8>: Sync, Arc<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>>: Sync,

§

impl<PosTable, BP, BCI, CSS> Unpin for SlotWorker<PosTable, BP, BCI, CSS>
where CSS: Unpin, BCI: Unpin, BP: Unpin, PosTable: Unpin, BoundedSenderInner<NewSlotNotification>: Unpin, BoundedSenderInner<BlockSealNotification>: Unpin, *const LeafNode<SlotNumber, (SolutionParameters, Receiver<Solution>)> is !null: Unpin, Box<(SlotNumber, (SolutionParameters, Receiver<Solution>))>: Unpin, *const LeafNode<SlotNumber, PotCheckpoints> is !null: Unpin, Box<(SlotNumber, PotCheckpoints)>: Unpin, NonZero<u8>: Unpin, *const ArcInner<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>> is !null: Unpin, Align1<u8>: Unpin, *const u8 is !null: Unpin, NonZero<u32>: Unpin, *const ArcInner<Mutex<RawMutex, Option<PotCheckpoints>>> is !null: Unpin, u32: Unpin,

§

impl<PosTable, BP, BCI, CSS> UnsafeUnpin for SlotWorker<PosTable, BP, BCI, CSS>
where BP: UnsafeUnpin, BCI: UnsafeUnpin, CSS: UnsafeUnpin, *const ArcInner<BoundedInner<NewSlotNotification>> is !null: UnsafeUnpin, PhantomData<ArcInner<BoundedInner<NewSlotNotification>>>: UnsafeUnpin, *const ArcInner<Mutex<SenderTask>> is !null: UnsafeUnpin, PhantomData<ArcInner<Mutex<SenderTask>>>: UnsafeUnpin, *const ArcInner<BoundedInner<BlockSealNotification>> is !null: UnsafeUnpin, PhantomData<ArcInner<BoundedInner<BlockSealNotification>>>: UnsafeUnpin, *const LeafNode<SlotNumber, (SolutionParameters, Receiver<Solution>)> is !null: UnsafeUnpin, PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin, PhantomData<Box<(SlotNumber, (SolutionParameters, Receiver<Solution>))>>: UnsafeUnpin, *const LeafNode<SlotNumber, PotCheckpoints> is !null: UnsafeUnpin, PhantomData<Box<(SlotNumber, PotCheckpoints)>>: UnsafeUnpin, NonZeroU8Inner: UnsafeUnpin, *const ArcInner<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>> is !null: UnsafeUnpin, PhantomData<Mutex<RawMutex, LruMap<CacheKey, CacheValue>>>: UnsafeUnpin, PhantomData<PosTable>: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more