pub struct Flow {
pub id: FlowId,
pub vm: Vm,
pub mailbox: Arc<Mailbox>,
pub metrics: Arc<FlowMetrics>,
pub restart_policy: RestartPolicy,
pub pending_message: Option<Value>,
pub last_receive_dest: Option<u8>,
/* private fields */
}Expand description
A single flow: VM state, mailbox, and bookkeeping.
This is the unit of work moved by the scheduler — pushed onto worker
deques, stolen, parked inside a Mailbox on Receive, or held by
the timer wheel while sleeping. Flows talk only via Atomic Hops
(crate::Value::Message on Send).
Fields§
§id: FlowId§vm: Vm§mailbox: Arc<Mailbox>§metrics: Arc<FlowMetrics>§restart_policy: RestartPolicy§pending_message: Option<Value>Set by Mailbox::park when a hop wins the park race.
last_receive_dest: Option<u8>Destination register of the most recent Receive / ReceiveTimeout.
Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Flow
impl !UnwindSafe for Flow
impl Freeze for Flow
impl Send for Flow
impl Sync for Flow
impl Unpin for Flow
impl UnsafeUnpin for Flow
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