Skip to main content

Ignition

Struct Ignition 

Source
pub struct Ignition<R = Unruntimed> { /* private fields */ }
Available on crate feature runtime only.
Expand description

THE IGNITION WALK over a wired deployment: engines under the bodies, and the sources last.

Begun with Assembly::ignite or ignite_on, which are the only doors — starting what nothing wired is not a thing to spell — and ended with into_app, which is where the sources start and what hands back the App world.

§R is the app’s runtime, and a thread-only graph never writes it

The parameter defaults to Unruntimed, which is what ignite hands back: a walk that can put THREAD engines under bodies and hand async bodies to whoever holds a runtime, and nothing else. Naming a runtime — ignite_on::<R>, once, for the whole deployment — is what adds spawn and moves the cadence clock onto that runtime’s own timers.

So the missing runtime is a COMPILE-TIME fact and not a start-up refusal: there is no method to call, and the diagnostic names the type that says why.

§Examples

use ingraph::{Context,
  Delivery, DriverKind, Effect, FanoutKind, GraphBuilder, NodeWiring, Operator, Plan,
};

struct Shout;

impl Operator for Shout {
  type Error = core::convert::Infallible;
  type In = String;
  type Out = String;

  fn accept(&mut self, ctx: &Context, delivery: Delivery<String>, emitter: &mut ingraph::Emitter<String>)
    -> Result<(), Self::Error> {
    for item in delivery.into_items() {
      emitter.emit(item.into_value().to_uppercase());
    }
    Ok(())
  }
}


let mut builder = GraphBuilder::new();
let shout = builder.source::<Shout>("shout", DriverKind::Thread);
let titles = builder.node::<Shout>("titles", DriverKind::Thread);
builder.edge(&shout, &titles, FanoutKind::Broadcast);
let wired = plan.validate().expect("the deployment checks out");
let mut wiring = wired.create().wire();
let head = wiring.inbox::<String>(shout.id()).unwrap().unwrap();
let leaf = wiring.inbox::<String>(titles.id()).unwrap().unwrap();
let (head, head_party) = wiring.resident(shout.id(), Shout, head).unwrap().unwrap();
let (leaf, leaf_party) = wiring.resident(titles.id(), Shout, leaf).unwrap().unwrap();

// Each body gets an engine, and nothing has started admitting yet.
let mut ignition = wiring.into_assembly().ignite();
ignition.resident(head, head_party).expect("the engine started");
ignition.resident(leaf, leaf_party).expect("the engine started");
let running = ignition.into_app::<()>();

// Nothing is feeding it, so winding down settles both bodies.
let stopped = running.shutdown(None);
assert_eq!(stopped.settled(), 2);
assert!(stopped.is_clean());

Implementations§

Source§

impl<R> Ignition<R>

Source

pub fn resident<O, W, A, L, C, S, I, M>( &mut self, resident: Resident<O, W, A, L, C, S, I, M>, enrolled: Enrolled, ) -> Result<(), LaunchError>
where Resident<O, W, A, L, C, S, I, M>: Drives + Send + 'static, O: Driven<M>, A: Attributes<<O as Driven<M>>::Out>,

Put the THREAD engine under resident, and fire enrolled when it is finished.

The thread is the node’s own for the process’s life: the operator was constructed by the caller, moves onto it here and never migrates, which is the residency ruling and what makes a !Send node an ordinary one.

§What the body does after the loop returns, and the order it does it in

The loop ends when every sender to its inbox is gone. Then the resident — and the operator inside it — is DROPPED, on the engine that owns it, because Drop is the shipped teardown for every value that enrols in no other. Only then does the party settle. So a node that settled has finished with its own value, and a value whose drop hangs is a party the shutdown’s deadline catches rather than a wait nothing bounds.

§Errors

LaunchError::Ignition where the operating system refuses the thread, carrying its own error under the node’s name — and whatever this ignition had already started is unwinded before that error is handed back, so a caller receiving one holds a deployment that has stopped rather than one still half-running.

Source

pub fn resident_declared<O, W, A, L, C, S, I, M>( &mut self, resident: Resident<O, W, A, L, C, S, I, M>, enrolled: Enrolled, ) -> Result<(), LaunchError>
where Resident<O, W, A, L, C, S, I, M>: Drives + Send + 'static, O: Driven<M> + Declared, A: Attributes<<O as Driven<M>>::Out>,

resident for a DECLARED node — the same engine, and the declaration’s teardown word honoured.

What the emitted launch walk calls, one line per mounted node, and the reason it is a second door rather than a bound added to the first: a hand-wired arrangement states no facts trait, and demanding one to start a thread would close a seam this crate keeps open on purpose.

§ONE call for the whole catalog, and a node that enrolled nothing pays nothing

The branch is on Declared::TEARDOWN, and the goodbye it reaches is Declared::goodbye — a defaulted method whose default DROPS. So the emitted walk writes the same line for every mount, a declaration without the word compiles to the body resident composes, and nothing anywhere has to name AsyncTeardown to walk a catalog where one node happens to have said it.

§The goodbye is said HERE, on this thread, when the chain says so

A thread-engine node exists for values that cannot cross a thread, so its goodbye cannot either. The body settles its party, PARKS, and runs the goodbye in place when the shutdown’s chain reaches its turn — see Enrolled::settle_parked, which is the whole of the protocol. The value never moves, the order is the chain’s, and the outcome is all that travels.

§Errors

resident’s, for the same reason and with the same unwind behind it.

Source

pub fn autonomous_declared<N>( &mut self, helm: Helm<N, <N as Declared>::Mode>, stopper: Stopper, enrolled: Enrolled, ) -> Result<(), LaunchError>
where N: Declared + Runs<<N as Declared>::Mode> + Send + 'static, <N as Runs<<N as Declared>::Mode>>::In: Send + 'static, <N as Runs<<N as Declared>::Mode>>::Out: Send + 'static, <N as Runs<<N as Declared>::Mode>>::Error: Error + Send + Sync + 'static,

PUT A THREAD UNDER AN AUTONOMOUS NODE — the engine a body that owns its own loop lives its whole life on — and join its stop line to the wind-down.

resident_declared’s counterpart at the third kind, and origin_declared’s shape at a node: this kind’s life is the ORIGIN’s shape rather than the resident’s — started once, running until it is spent, told to stop or dead — so what it is owed is a thread, a stop line the world can say something on, and somewhere for its ending to be reported.

§ONE DOOR FOR BOTH FACES, and the DECLARATION is what picks

Runs’s two rows collapse into one driver — the author’s run on the blocking row and the same run pinned by this layer’s own block_on on the awaited one — so a caller writes one line for either face and a declaration that lies about its face is E0277 where the cell is cashed rather than a mount that quietly does the other thing. The awaited face is NOT handed to spawn, for awaited_origin’s reason: that door demands Send, which would refuse the exact shape this face declines to bound.

§THE ENDING IS OBSERVED and the party SETTLES, whichever way it ended

observed is the one function, shared with the origin layer because the fact is the same one: two ordinary endings reach the taps as Processed carrying the Fin, and a DEATH reaches them as Failed carrying the node’s own error — and then settles like any other finished body. Nothing restarts it, and the deferral is the origin layer’s, recorded there.

§THE VALUE MOVES ONTO THIS THREAD AND DOES NOT COME BACK, which is the by-value contract

[Helm::run] consumes the node, because AutonomousOperator::run does: the value is MOVED into the call, its prologue takes it apart into workers of its own, and its epilogue winds them down. So this door settles the party and has nothing to hand a goodbye chain — an autonomous node’s TEARDOWN IS ITS OWN EPILOGUE, spelled inside run where the workers it has to join are, with Drop as the idempotent backstop under a panic. See AutonomousOperator’s lifecycle table, which is where the whole of that division is written.

The teardown word’s own chain therefore reaches this kind only BEFORE ignition, where the value still exists and Mount::stage can hand it over — which is the honest posture rather than a gap, because a node that never ran has nothing to wind down and a node that ran has already wound itself down.

§THE STOP LINE IS JOINED, and that is what makes the wind-down reach it

A body inside run never reads the party announcement App::shutdown broadcasts, so the launch keeps this node’s Stopper and says the stop through it. Without the join, an autonomous node whose upstreams never hang up would never be told anything and the wait would be a wait for a party with no way of finishing.

The join is made AFTER the engine, for origin_declared’s reason: a mount that could not spawn has already been unwound, and a half kept for a body that never ran would be a stop said to nobody.

§Errors

resident’s, for the same reason and with the same unwind behind it.

Source

pub fn origin<S>( &mut self, name: &str, source: S, giving: Feed<S::Yield>, eating: Control<<S::Mutation as MutationNode>::Command>, halt: ShutdownSignal, enrolled: Enrolled, ) -> Result<(), LaunchError>
where S: Source + Send + 'static, S::Yield: Send, <S::Mutation as MutationNode>::Command: Send, S::Error: Error + Send + Sync + 'static,

Put a thread under a BLOCKING ORIGIN — the engine a Source lives its whole life on.

The origin layer’s own door beside resident, and a separate one because an origin is a different SHAPE of life rather than a different body: it is started once and runs until it ends, so there is no per-item loop, no inbox, no ack window and no driving matrix to select a cell of. What it has instead is three seats and an ending.

NOT source, one name over. That door is for the light machinery a deployment stops by DROPPING a handle — a clock, a doorbell, a change feed — and it enrols no party and reports no failure. An origin answers Result<Fin, Self::Error> and has a real ending to tell the truth about, which is the whole of what this door adds.

§THE ENDING IS OBSERVED and the party SETTLES, whichever way it ended

observed is where the three outcomes are set beside each other. A DEATH reaches the taps as Failed carrying the origin’s own error, and then settles like any other finished body: a launch that left a died source unsettled would hold a shutdown open on a thread that had already returned.

Nothing restarts it, and the deferral is recorded rather than defaulted — see origin’s module note for the questions a restart policy would have to answer and why this layer does not answer them for everybody.

§Errors

resident’s, for the same reason and with the same unwind behind it.

Source

pub fn awaited_origin<S>( &mut self, name: &str, source: S, giving: Feed<S::Yield>, eating: Control<<S::Mutation as MutationNode>::Command>, halt: ShutdownSignal, enrolled: Enrolled, ) -> Result<(), LaunchError>
where S: AsyncSource + Send + 'static, S::Yield: Send, <S::Mutation as MutationNode>::Command: Send, S::Error: Error + Send + Sync + 'static,

origin for the AWAITED face — the same thread, with the origin’s future PINNED on it.

A second door rather than a bound on the first, because the two faces are two traits and an author implements exactly one: the face is inferred from the origin’s type here, exactly as it is at the declaration that named it.

The future is driven by [block_on] — the same driver the thread engine spends every other awaited seam through — and NOT by spawn. That door demands Send, which would refuse the exact shape AsyncSource dropped its own + Send bound to admit. The origin VALUE still crosses onto this thread, so it is Send; what need not be is everything its life holds between two awaits.

§Errors

origin’s, unchanged.

Source

pub fn origin_declared<S>( &mut self, name: &str, origin: S, depth: usize, enrolled: Enrolled, ) -> Result<Mounted<Ordered<S>, Produced<S>>, LaunchError>
where S: DeclaredOrigin + Lived<<S as DeclaredOrigin>::Mode> + Send + 'static, Produced<S>: Send, Ordered<S>: Send, Died<S>: Error + Send + Sync + 'static,

MOUNT A DECLARED ORIGIN: the walk mints its three lines, puts it on the engine its own declaration chose, and hands back the ends a deployment holds.

ⓘ
let watch = ignition.origin_declared::<Watch>("watch", Watch, 16, enrolled)?;
let schema = Schema::build(query, WatchOpsMutations, EmptySubscription)
  .data(watch.commands().clone())
  .finish();
§ONE DOOR FOR BOTH FACES, and the DECLARATION is what picks

origin and awaited_origin are the HAND-WIRED pair: a caller that already holds three lines and knows which face it is holding names the door itself. This one asks nothing — DeclaredOrigin::Mode selects the Lived row and the row carries the driver — so a caller cannot pick the wrong one, and a declaration that lies about its face is E0277 at this line rather than a mount that quietly does the other thing.

§WHAT IT MINTS, and what it does not

The three lines, at depth, and the party’s engine. What it does NOT do is BUILD the origin: construction from a declaration’s Options is the create walk’s own step, and this stage runs after it. So a caller hands over a value, exactly as it does for a resident.

§THE STOP HAS TWO HALVES, and the second one is JOINED TO THE WIND-DOWN

The Stopper comes back in the handle, so stopping one origin early stays the deployment’s — that is what a controllable source exists to be, and dropping the handle says the same thing (see Mounted).

And the launch keeps a half of its own, which is what makes an infinite origin windable-down. An origin’s body is inside run for its whole life, so it never reads the party announcement App::shutdown broadcasts — the wind-down reaches it on the one road it listens to instead, which is its ShutdownSignal. Without the join a deployment holding a handle would be waiting for a party that had never been told anything, on a stop no bound covers.

The two halves do not fight: the message coalesces, both roads latch the same fact, and an origin already stopped hears the second word as the no-op it is. What a deployment that wants a FINITE origin’s last item takes is App::until_stopped before the shutdown — an origin cut short by the wind-down ends [Fin::Stopped], which is an ordinary ending and not a loss.

§Errors

resident’s, for the same reason and with the same unwind behind it.

Source

pub fn origin_bridged<S>( &mut self, name: &str, origin: S, consumer: Outbox<ItemId, Produced<S>>, depth: usize, enrolled: Enrolled, ) -> Result<Bridged<Ordered<S>>, LaunchError>
where S: DeclaredOrigin + Lived<<S as DeclaredOrigin>::Mode> + Send + 'static, Produced<S>: Send, Ordered<S>: Send, Died<S>: Error + Send + Sync + 'static,

MOUNT A DECLARED ORIGIN ONTO A GRAPH EDGE — origin_declared with the feed’s far end being a CONSUMER’S INBOX rather than a line the deployment drains.

ⓘ
let ledger = plan.node("ledger");
let inbox = wiring.outbox::<Beat>(ledger)?.expect("this deployment launches the consumer");
let watch = ignition.origin_bridged::<Watch>("watch", Watch, inbox, 16, enrolled)?;
§WHICH WALK OPENS THE EDGE, and why it is this one

The consumer’s inbox is minted at WIRING and an origin is mounted a stage later, so either the wiring walk keeps a sending half for an edge whose producer is not a node, or the MOUNT takes one from it. This is the second, and it is the only one of the two that can be typed: here S’s Yield is still a type rather than a TypeId, so Wiring::outbox answers the edge under the very projection this signature spells, and a consumer whose input is something else is refused THERE, by name, with both types in the sentence.

WHICH SLOT is the caller’s to name, and Wiring::outbox is only the common case of it. A consumer with ONE upstream draws through slot zero, which is what that door answers; a consumer with a FAN-IN has one edge per declared upstream, and the origin’s is whichever position its own row sits at — Wiring::source_of reads that off the declaration and Wiring::source_outbox opens it. Nothing about fan-in is special to a bridge: an origin is one producer among a consumer’s several, on its own edge, with its own capacity.

§WHAT IT MINTS, and the one seat it does not

The control line at depth, the stop, and the engine — and NOT the yield line, which is the whole of what a bridge is. depth therefore governs the COMMAND line alone here, where origin_declared spends it on both: a bridged feed is bounded by the EDGE, resolved from the declaration and the deployment’s document like every other edge, and a second number would be a second bound in series — see Feed::bridging.

§THE ENDING IS THIS ORIGIN’S HALF OF THE EDGE, and nothing new says so

The feed is taken BY VALUE into Lived::live and this walk keeps no second half on the origin’s behalf, so run returning drops it. All three endings do it: Spent, Stopped and a DEATH close this half alike, because what closed it is the body being over rather than which way it was over. Which way it was over is what the TAPS are told, unchanged — see observed.

The edge itself ends when every sender is gone, and the launch holds one of its own until Assembly::close releases it — so from the wind-down’s first domino a bridged origin is the only thing holding its consumer’s inbox open, and the consumer drains and returns when this origin’s life ends. An origin that never ends holds it open for as long as it runs, which is not an oversight: an fs-watch origin has no last item, and a bridge that invented an end for it would be inventing the one fact the arrangement is built to deny.

§Errors

resident’s, for the same reason and with the same unwind behind it.

Source

pub fn origin_kept<S>( &mut self, name: &str, origin: S, consumer: Outbox<ItemId, Produced<S>>, depth: usize, enrolled: Enrolled, ) -> Result<(), LaunchError>
where S: DeclaredOrigin + Lived<<S as DeclaredOrigin>::Mode> + Send + 'static, Produced<S>: Send, Ordered<S>: Send, Died<S>: Error + Send + Sync + 'static,

MOUNT A DECLARED ORIGIN ONTO A GRAPH EDGE AND KEEP ITS HANDLE — origin_bridged with the two ends held by the world rather than handed back.

The EMITTED launch’s door, and a second one rather than a bound added to the first for a reason a reader should not have to reconstruct: a Bridged owns a Stopper, and a stopper SAYS THE STOP AS IT GOES. An expansion has nowhere to put a returned handle — <Root>::launch answers an App, not a tuple whose arity depends on how many origins a root happens to declare — so a walk that called origin_bridged and dropped what it answered would tell every origin it had just started to wind down. This is the same mount with the handle put where the running world can keep it alive and a deployment can still reach it.

§It is KEYED BY THE ORIGIN’S TYPE, exactly as an intake door is

App::origin is the far end and asks by the same key, for intake’s reason: a caller holds the origin’s type and never the deployment’s word for it. A second mount of one type REPLACES the first, and dropping the first says its stop — which is the honest reading of an arrangement that mounted one origin twice.

§Errors

origin_bridged’s, unchanged.

Source

pub fn source<F, S>(&mut self, start: F)
where F: FnOnce() -> S + Send + 'static, S: Send + 'static,

Start start LAST — after every body has its engine — and hold what it answers.

The handle it answers is what STOPS it, and the ignition never calls anything on one: dropping it is the shutdown’s first act, and the order the drops happen in is the reverse of the order the sources were registered in. So a source registered later stops earlier, which is the LIFO symmetry the whole stage is arranged around.

Source

pub fn feeder<N>(&mut self, feeder: Outbox<ItemId, <Cell<N> as Mount<N>>::In>)
where N: Declared, Cell<N>: Mount<N>,

Offer feeder as the intake door onto the head node N.

What the running world hands back through App::feeder. One per head, and a second call for the same node REPLACES the first: an arrangement that opened two doors onto one inbox has two halves of one edge, and holding both would keep that edge open past the point either caller let go.

Nothing calls this for an interior node, and nothing needs to be stopped from: a node the graph itself feeds has an upstream, and the door a caller would want onto it is that upstream’s.

BOTH WORDS are derived from N’s own declaration, exactly as they are at the far end — see App::feeder for what a face parameter cost. The two ends have to agree on the boxed type for the downcast there to answer at all, so they read ONE rule: the Cell this node’s pair and mode words name. Deriving it by one rule here and asking by another there would be the one arrangement that could put the wrong type in the map.

Reading the cell is also what makes this door serve all three kinds. A streaming head has no Driven row, so a door spelled through that trait was one a stream declaration could not go through at all; intake stays beside it for the case where the message is already NAMED, which is what a Mount cell spends from inside itself.

Source

pub fn intake<N, T>(&mut self, feeder: Outbox<ItemId, T>)
where N: Declared, T: Send + 'static,

feeder with the head’s INPUT named rather than derived — the door a Mount cell spends.

feeder PROJECTS the message through the cell, and a cell spending the door from inside itself already holds the answer — it IS the pair the declaration wears — so what it needs is a door that takes the message and keys the map by the node, which is the whole of what the map ever needed. Spelling the projection there would be asking the compiler to re-derive, inside the impl, the very row that impl is.

The far end still has to agree on the boxed type for the downcast to answer at all, and it does: App::feeder asks through the same cell.

Source

pub fn lane_declared<N, X>( &mut self, mount: LaneMount<N, X, <N as Declared>::Mode>, enrolled: Enrolled, )
where N: Declared + Streams<<N as Declared>::Mode> + Send, <N as Streams<<N as Declared>::Mode>>::In: Send + 'static, <N as Streams<<N as Declared>::Mode>>::Out: Send + 'static, X: Send + 'static,

HOLD THE MOUNTED LANE for the declared streaming node N, for the party that will drive it.

resident_declared’s counterpart at the streaming pair, and the asymmetry between them is the streaming contract’s own: a resident is handed an ENGINE here and a lane is handed to whoever asks for it, because no ignition door runs the admit / tend loop. So this starts nothing, can fail at nothing, and the party it enrolled settles when the party that took the lane is finished with it.

What is held is the ACT of building the lane rather than the lane — Wiring::lane_mount carries the argument.

Source

pub fn teardown<T>(&mut self, name: &str, value: T)
where T: AsyncTeardown + Send + 'static,

Enrol value’s goodbye under name — the AsyncTeardown opt-in for a value the LAUNCH holds.

Said at the END of an orderly shutdown, after every party has settled, LAST ENROLLED FIRST. A value that enrols in none is torn down by its own Drop, which is the shipped posture and the right one for nearly everything.

It is the door for what this walk is still holding, and a NODE’s value is not that: it moved onto an engine and it does not migrate, so its goodbye enters the same chain through its own settlement instead — see resident_declared and task_saying_goodbye, which are the two roads it takes. A resource’s enters through Resources::insert_goodbye, which is what puts it at the chain’s LAST step rather than beside the nodes.

Enrolments here are made after the wiring registered the parties, so they are said FIRST — the same LIFO the whole launch is arranged around, read at its innermost turn.

Source

pub fn context(&self) -> &Resources

The shared resources the create walk built.

Source

pub const fn shutdown(&self) -> &Shutdown

Who the shutdown waits for.

Source

pub fn bodies(&self) -> usize

How many bodies have an engine so far.

Threads and tasks together, because what the number answers is how much of the deployment this stage has actually started — and a body the framework spawned onto the app’s runtime is started in exactly the sense a body on its own thread is. A body handed back by task is NOT counted, and that is the same rule read the other way: this stage did not start it and does not hold its join.

Source

pub fn sources(&self) -> usize

How many sources are waiting to be started.

Source

pub fn unwind(&mut self, error: LaunchError) -> LaunchError

Wind down whatever already has an engine, and hand error back UNCHANGED — the failed launch’s own duty, and the other way out of this walk.

resident spends it for the one failure the ignition itself can have. This is the same duty for the failures it cannot: a walk is DRIVEN by the party that can name the operators’ types, and that party’s own step — a file it could not open, a handle it could not take — can refuse after the first body is already running. Bailing there would strand engines, which is exactly what this stage must not leave behind.

§It takes the error, and that is the point

The caller’s error is the ORIGINAL one, always: the unwind is a duty rather than a second failure, so nothing here can invent a refusal — it holds no way to spell one — and nothing at the call site has to remember to keep the first. Err(ignition.unwind(error)) is the whole idiom, and how the unwind ITSELF went rides the Taps instead: one observation per ignited party under its own name, Processed where it settled and Failed where the patience ran out first — the same seam a refused goodbye is reported through.

§The sequence
  1. every REGISTERED party hears wind down, and every MOUNTED ORIGIN hears it on its own stop line — the one road a body that is inside run listens to;
  2. the light sources need no stopping, which is the safety property this whole stage is ordered around: they start last, so the unspent starts are dropped unrun and nothing is admitting. An ORIGIN is the exception the step above answers, because a mount STARTS it — the walk hands back the handle to a life that is already running, so a failure after one is a failure with an origin admitting;
  3. the framework releases its own halves of the edges — the wave’s first domino, exactly as at App::shutdown;
  4. the wait — for the IGNITED parties only — bounded by PATIENCE;
  5. the outcome reaches the taps;
  6. and where everybody settled, THE GOODBYES are said and the resources released — the same chain App::shutdown walks, spent for the second of its two ruled occasions — after which the engines are joined.
§Announced to everyone, waited for by the set that BEGAN

The two sets differ on purpose, and the asymmetry is the whole of it. An announcement is free and a party that never started never reads one, while a WAIT for a party that never started is a wait for something that will not happen — and mid-walk the registry is full of those, every enrolment still in the caller’s hands belonging to a body this failure means will never be built.

Announcing narrowly would also be announcing to nobody who reads it: a resident is told by its EDGES rather than by the registry, so the parties that actually watch for a wind-down are the ones the caller runs itself — an intake it enrolled at wiring and started by hand, a query arm. Such a party is still ADMITTING, so telling it is not a courtesy: it is what lets the wave reach the bodies that are waiting on it, and skipping it would turn every unwind of that arrangement into an overrun.

§The goodbyes are the SAME chain, and an abandonment is what silences them

A launch that failed after its first engine started has values that RAN, and the ruling gives them the same ending an orderly shutdown gives: every ignited party settles, hands its goodbye back through its own settlement seat, and the chain says them in reverse enrolment order with the resources released last. Nothing here is a second teardown mechanism — it is farewell, the one the shutdown spends.

A party that did not answer in time is ABANDONED where it stands — the ruled abort posture — and that silences the whole chain: a teardown that flushes a store while the node writing to it is still running is a worse ending than an un-torn value. The goodbyes then go unsaid and the values are left to their own Drop, exactly as App::abort leaves them.

§What this walk does NOT reach, and it is exactly one thing

The residents the CALLER is still holding when one of these engines refuses. This stage is handed one body at a time, so the ones after the failing call have never been here — and by the time the caller sees the refusal, this unwind has already run, so a chain said afterwards would speak after the resources were released. They are left to their own Drop, which is the shipped teardown for every value that enrols in no other.

A launch that refuses BEFORE this stage has no such gap: ownership never left the walk, and Creation::unwind and Wiring::unwind say every staged value’s goodbye through this very chain.

An ignition that has started nothing is the identity: nothing is running, so this hands the error straight back rather than announcing a wind-down to a world that never woke. Spending it twice announces to a set that has already finished, waits for nobody, and says the same thing to the taps a second time.

Source

pub fn into_app<I>(self) -> App<I>

Start every source, and hand back the running App.

The registered starts are spent in registration order and the framework’s own cadence clock LAST of all — one clock over the cadences the wiring walk collected, and none at all where it collected none. Last on, first off: it is the first thing the shutdown stops.

WHICH clock was decided at the door: an app that named a runtime gets an AfterClock on that runtime’s own timers, and one that named none gets the Sweeper thread. Both answer the handle that stops them, so this line reads the same either way.

I is the GENERATED ROOT the world belongs to, and nothing here reads it: an emitted Media::launch spends this as into_app::<Media>, and a deployment wired by hand — which has no generated root to name — writes into_app::<()>.

Source§

impl Ignition<Unruntimed>

The surface a reader reaches WITHOUT naming a runtime.

Both members are there for the same reason and it is not a technicality: an inherent item on Ignition<R> cannot be named as Ignition::… at all — there is nothing to infer R from — so the two things a deployment spells before it has decided on an engine live on the default form, and everything a runtime unlocks lives on the impl that has one.

Source

pub const PATIENCE: Duration = UNWIND_PATIENCE

How long the failed-launch unwind waits for the already-ignited to settle.

The one number this stage ships, and the ruled bound on a wait that would otherwise be a hang: a party that will not settle is ABANDONED where it stands rather than waited on forever, which is the same posture App::shutdown takes past its own deadline. It is the walk’s own budget whatever engine a body took — the form it is named on is a spelling, not a scope.

Five seconds because of what is actually being waited for. No source is running — they start last, so a launch that failed has admitted nothing — and the edges are bounded, so the drain itself is a queue’s worth of items and takes milliseconds. What the budget is really for is the values: a node’s own Drop runs on its engine before its party settles, and a value that closes a model or a connection pool as it goes is entitled to a moment. Long enough that such a value is not abandoned mid-goodbye, short enough that a failed start-up still reports its refusal while somebody is watching a boot rather than looking like a hang.

Source

pub fn task<O, W, A, L, C, S, I, M>( resident: Resident<O, W, A, L, C, S, I, M>, enrolled: Enrolled, ) -> impl Future<Output = ()>
where Resident<O, W, A, L, C, S, I, M>: Drives + Send + 'static, O: Driven<M>, A: Attributes<<O as Driven<M>>::Out>,

The ASYNC engine’s body for resident, composed and ready for whoever holds a runtime — the R-LESS FALLBACK.

It is handed back rather than spawned because this walk has no runtime to spawn it on, which is what Unruntimed says: a deployment that named one hands the body straight to spawn.

§The Send promise is the CALL SITE’s, and that is the whole design

This signature makes none. An accept carries no Send bound on EITHER face — mobility belongs to the engines, not to the author’s contract — so no generic function over O can promise that the body it composes crosses threads. What it CAN do is leak: the composed future’s auto traits are computed per instantiation, so at a concrete operator the body is provably Send or provably not, and spawn is where that is checked. A !Send unit put on the async engine is therefore E0277 at the spawning door — the compile-time refusal engine-follows-mobility asks for — while the same body is an ordinary citizen on a LocalSet or on this walk’s own thread engine.

What is the same either way is what the body DOES, and that is what this composes: the loop, then the value’s own drop, then the party’s settlement — the same three steps in the same order the thread engine takes them in.

Spawn it BEFORE into_app, which is when the sources start. A body nobody spawns is a party that never settles, and the shutdown will wait for it exactly as it waits for a node that hung — as will unwind, which is what marks this party ignited as the body is COMPOSED. Composing is the last moment this walk sees, the runtime being somebody else’s, so it is the moment the mark can be set at.

It is an associated function on the R-less form for exactly that reason, and the boundary is worth reading as a promise: this stage holds no join for a body it did not spawn, so the app that spawns one owns its handle, and the shutdown still counts the party through the registry it was enrolled in.

Source

pub fn task_saying_goodbye<O, W, A, L, C, S, I, M, G>( resident: Resident<O, W, A, L, C, S, I, M>, enrolled: Enrolled, goodbye: G, ) -> impl Future<Output = ()>
where G: FnOnce(O) -> Posted, Resident<O, W, A, L, C, S, I, M>: Drives + Send + 'static, O: Driven<M>, A: Attributes<<O as Driven<M>>::Out>,

task for a value with a GOODBYE to say — the async engine’s road, and the one the ruled hand-back describes exactly.

The loop, then the rest of the resident’s own drop, then the goodbye BOXED and handed to the chain, then the party’s settlement. What travels is a Pin<Box<dyn Future … + Send>> — see Posted — created at the one place that still knows the operator’s type, so the chain the handle walks holds (name, future) pairs and no generics whatsoever.

§The BOXING is the caller’s, and that is what asks for Send at the right place

goodbye turns the operator into the future the chain will await, and the whole idiom is |value| Box::pin(value.teardown()). Written that way at a CONCRETE operator, the coercion to Posted is where a goodbye that cannot cross a thread becomes E0277 — under the author’s own eyes, at the node they wrote it for.

It is a closure rather than a AsyncTeardown bound because that bound could not ask the question: teardown returns an opaque future whose auto traits are known only per instantiation, and a generic walk over O can promise nothing about one. The same reason spawn is where the BODY’s mobility is checked rather than Operator.

There is no parked road on this engine and there cannot be one: parking means blocking the thread the value lives on, and a task does not own the thread it happens to be polled by. So the two roads are the two engines, which is the ruled shape read from the other end.

§Examples

See AsyncTeardown for what a goodbye is; the line that spends it here reads

ⓘ
ignition.spawn(Ignition::task_saying_goodbye(body, party, |camera| {
  Box::pin(camera.teardown())
}));
Source

pub fn registry_driver<Root>( &mut self, registry: Arc<Registry<Root>>, keys: Yielded<Root>, head: Outbox<ItemId, Root>, )
where Root: RootKey,

PUT THE ROOT-KEY REGISTRY’s DRIVER UNDER A THREAD — the R-LESS road, and the Sweeper fork read one seat over.

Ignition<R>::registry_driver’s twin for the world that named no runtime, and it differs in exactly what the cadence clock’s two doors differ in: a task where there is a runtime to spawn one on, one thread where there is not. Everything above the engine — the quiet window, the batch, the count held across the head’s ack, what a stop does with a pending batch — is the same machine, and its whole contract is RegistryDriver’s.

See that type for the arguments, and for why the head is taken as an Outbox rather than as a Feed.

§It rides the SOURCE list, and that is where its place in the wind-down comes from

The handle is registered through source, so the driver starts LAST with every other source and is released at STEP 2 of App::shutdown — after every mounted origin has been told to wind down and before the framework lets go of the edges. On this road the release also JOINS: the thread has actually stopped by the time the step returns.

§Panics

RegistryDriver::spawn’s, where the operating system refuses the thread — and it happens at into_app, where the sources start, rather than here.

Source§

impl<R> Ignition<R>
where R: RuntimeLite,

Source

pub fn spawn(&mut self, body: impl Future<Output = ()> + Send + 'static)

Put the ASYNC engine under body — on the runtime this deployment named — and hold its join.

resident’s twin, over the body task composes: the loop, then the value’s own drop, then the party’s settlement, in that order. What differs is the machine underneath — a task the app’s runtime schedules rather than a thread this stage asks the operating system for — and, with it, the failure that cannot happen: a spawn onto a runtime answers no error, so this returns nothing where the thread engine returns a Result.

The join is HELD, unlike a body the app spawns itself: the handle the spawn answers goes into this walk and is awaited at the end of an orderly shutdown, so a stopped world means the tasks are gone rather than merely finished.

§The !Send law lives on THIS door’s bound

A task may be stolen by another worker thread, so what rides this engine must be Send — and this parameter is the only place that can say so. An accept takes no Send bound on either face (mobility belongs to the engines), so a generic walk over the operator cannot promise it and the check has to happen where the concrete type is known: right here, at the door that names the runtime. A node whose body cannot cross a thread — a model context, an FFI session — is E0277 at this call and an ordinary citizen on resident, where it is constructed on its own thread and never migrates.

There is no local lane, and that is deliberate. AsyncLocalSpawner is the NAMED SEAT a !Send async body would sit in, and it is refused until there is something to measure it against: a local spawn needs an ambient thread-local executor that not every runtime has — smol has none at all, embassy’s spawner is Send-only, tokio’s panics outside a LocalSet — so a lane built on it would work on one backend and panic on the next. The seat is named so the widening has an address; the thread engine is the !Send home until it is taken.

Source

pub fn registry_driver<Root>( &mut self, registry: Arc<Registry<Root>>, keys: Yielded<Root>, head: Outbox<ItemId, Root>, )
where Root: RootKey,

PUT THE ROOT-KEY REGISTRY’s DRIVER ON THE RUNTIME — one long-lived task per family, timed by R’s own sleep.

The cadence clock’s fork, at the other machine this layer drives: an app that named a runtime gets its coalescer as a TASK on that runtime, exactly as it gets its cadences on an AfterClock rather than on a Sweeper thread. No thread is asked for on this road, and RegistryDriver::engine is the value that says so.

registry is the family’s own table (Registries::open), keys is the far end of the LOOSE feed origins push through, and head is the head node’s own inbox — see RegistryDriver for the intake roads and for why the head is an Outbox here.

§TWO SEATS, and each holds the half it can

The body goes to spawn, which HOLDS its join — so a stopped world means the driver’s task is gone rather than merely told. The STOP goes to source, which is what puts it at STEP 2 of App::shutdown: after every mounted origin has been told to wind down, and before the framework lets go of the edges and the nodes drain.

The task is spawned HERE rather than at into_app, where the sources start, and the safety property survives it: a driver with nothing pushed to it parks, and what pushes is an origin, which does start there.

Source

pub fn retired_ledger<Root>( &mut self, registry: &Arc<Registry<Root>>, store: Arc<dyn RetiredStore<Root>>, mirror: Arc<RetiredMirror<Root>>, ) -> bool
where Root: RootKey,

SEAT THE RETIRED LEDGER ON A FAMILY AND PUT ITS BODY ON THE RUNTIME — the durable half of every retirement this family earns.

false where a ledger is already seated, which is Registry::installing’s refusal forwarded whole: a second writer for one family’s rows is two parties disagreeing about what a retirement means. Nothing is spawned in that case.

§It is ASYNC-ONLY, and that is a fact about the stores rather than a gap

registry_driver has a thread twin one impl up, and this has none. The intake driver’s work is arithmetic over two machines this crate wrote; a ledger’s work is I/O through somebody else’s driver, and every store the framework ships — sqlx’s three, the MongoDB client — needs a reactor to be polled on. Blocking one of those futures on a bare thread does not merely park: sqlx panics with this functionality requires a Tokio context before a statement is sent. So a world that named no runtime cannot host a shipped ledger, and a door offering it one would be a door that panics at the first retirement.

A deployment on the thread engine that wants a durable ledger writes a RetiredStore whose futures need no reactor — a file, an embedded key-value store — and drives KeeperBody::run itself. The seam is open; only this convenience is not.

§NO STOP OF ITS OWN, and the line’s own ending is why

Unlike the intake driver this registers nothing on the source list, because the body has a better ending than an announcement: it stops when every Keeper onto its line is gone, and the only one that exists lives in registry’s own seat. So the body ends when the family’s table does — which is when every resident counting into it has finished — and it drains whatever was queued on the way out, a disconnected receiver still yielding what was already sent.

The join is HELD, spawn’s own promise: a stopped world is one whose last retirement has actually been written rather than one that was told to write it.

Trait Implementations§

Source§

impl<R> Debug for Ignition<R>

Source§

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

Arities, for Assembly’s reason one stage on: what it holds is erased handles, somebody else’s resources and a list of closures, none of which has a Debug worth demanding.

Written rather than derived also because of R: a derived impl would bound it, and the runtime is a NAME here rather than a value — a runtime marker that could not print itself would make the whole walk unprintable for the sake of a marker nothing reads.

Auto Trait Implementations§

§

impl<R = Unruntimed> !RefUnwindSafe for Ignition<R>

§

impl<R = Unruntimed> !Sync for Ignition<R>

§

impl<R = Unruntimed> !UnwindSafe for Ignition<R>

§

impl<R> Freeze for Ignition<R>
where PhantomData<fn() -> R>: Freeze,

§

impl<R> Send for Ignition<R>
where PhantomData<fn() -> R>: Send,

§

impl<R> Unpin for Ignition<R>
where PhantomData<fn() -> R>: Unpin,

§

impl<R> UnsafeUnpin for Ignition<R>
where PhantomData<fn() -> R>: 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
Source§

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

Source§

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

Source§

impl<T> Conv for T

Source§

fn conv<T>(self) -> T
where Self: Into<T>,

Converts self into T using Into<T>. Read more
Source§

impl<T> Downcast for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Converts Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.
Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Converts Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Converts &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Converts &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
Source§

impl<T> DowncastSend for T
where T: Any + Send,

Source§

fn into_any_send(self: Box<T>) -> Box<dyn Any + Send>

Converts Box<Trait> (where Trait: DowncastSend) to Box<dyn Any + Send>, which can then be downcast into Box<ConcreteType> where ConcreteType implements Trait.
Source§

impl<T> FmtForward for T

Source§

fn fmt_binary(self) -> FmtBinary<Self>
where Self: Binary,

Causes self to use its Binary implementation when Debug-formatted.
Source§

fn fmt_display(self) -> FmtDisplay<Self>
where Self: Display,

Causes self to use its Display implementation when Debug-formatted.
Source§

fn fmt_lower_exp(self) -> FmtLowerExp<Self>
where Self: LowerExp,

Causes self to use its LowerExp implementation when Debug-formatted.
Source§

fn fmt_lower_hex(self) -> FmtLowerHex<Self>
where Self: LowerHex,

Causes self to use its LowerHex implementation when Debug-formatted.
Source§

fn fmt_octal(self) -> FmtOctal<Self>
where Self: Octal,

Causes self to use its Octal implementation when Debug-formatted.
Source§

fn fmt_pointer(self) -> FmtPointer<Self>
where Self: Pointer,

Causes self to use its Pointer implementation when Debug-formatted.
Source§

fn fmt_upper_exp(self) -> FmtUpperExp<Self>
where Self: UpperExp,

Causes self to use its UpperExp implementation when Debug-formatted.
Source§

fn fmt_upper_hex(self) -> FmtUpperHex<Self>
where Self: UpperHex,

Causes self to use its UpperHex implementation when Debug-formatted.
Source§

fn fmt_list(self) -> FmtList<Self>
where &'a Self: for<'a> IntoIterator,

Formats each item in a sequence. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Fruit for T
where T: Send + Downcast,

Source§

impl<T> Instrument for T

Source§

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

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

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

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

Source§

fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> R
where Self: Sized,

Pipes by value. This is generally the method you want to use. Read more
Source§

fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> R
where R: 'a,

Borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> R
where R: 'a,

Mutably borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
where Self: Borrow<B>, B: 'a + ?Sized, R: 'a,

Borrows self, then passes self.borrow() into the pipe function. Read more
Source§

fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
where Self: BorrowMut<B>, B: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.borrow_mut() into the pipe function. Read more
Source§

fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
where Self: AsRef<U>, U: 'a + ?Sized, R: 'a,

Borrows self, then passes self.as_ref() into the pipe function.
Source§

fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
where Self: AsMut<U>, U: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.as_mut() into the pipe function.
Source§

fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
where Self: Deref<Target = T>, T: 'a + ?Sized, R: 'a,

Borrows self, then passes self.deref() into the pipe function.
Source§

fn pipe_deref_mut<'a, T, R>( &'a mut self, func: impl FnOnce(&'a mut T) -> R, ) -> R
where Self: DerefMut<Target = T> + Deref, T: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.deref_mut() into the pipe function.
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

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

Initializes a with the given initializer. Read more
Source§

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

Dereferences the given pointer. Read more
Source§

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

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

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

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> State<Identity> for T

Source§

type Output = T

The type Self projects to.
Source§

impl<T> Tap for T

Source§

fn tap(self, func: impl FnOnce(&Self)) -> Self

Immutable access to a value. Read more
Source§

fn tap_mut(self, func: impl FnOnce(&mut Self)) -> Self

Mutable access to a value. Read more
Source§

fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Immutable access to the Borrow<B> of a value. Read more
Source§

fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Mutable access to the BorrowMut<B> of a value. Read more
Source§

fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Immutable access to the AsRef<R> view of a value. Read more
Source§

fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Mutable access to the AsMut<R> view of a value. Read more
Source§

fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Immutable access to the Deref::Target of a value. Read more
Source§

fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Mutable access to the Deref::Target of a value. Read more
Source§

fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self

Calls .tap() only in debug builds, and is erased in release builds.
Source§

fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self

Calls .tap_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Calls .tap_borrow() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Calls .tap_borrow_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Calls .tap_ref() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Calls .tap_ref_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Calls .tap_deref() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_mut_dbg<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Calls .tap_deref_mut() only in debug builds, and is erased in release builds.
Source§

impl<T> TryConv for T

Source§

fn try_conv<T>(self) -> Result<T, Self::Error>
where Self: TryInto<T>,

Attempts to convert self into T using TryInto<T>. Read more
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.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

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

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

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