Skip to main content

SignalActuator

Struct SignalActuator 

Source
pub struct SignalActuator { /* private fields */ }

Implementations§

Source§

impl SignalActuator

Source

pub fn new() -> Self

Source

pub fn register_gentle(&mut self, s: &Snapshot)

Registers the gentle actions of every model server in the snapshot, keyed by its group.

Source

pub fn gentle_for(&self, group_id: &str) -> &[GentleAction]

The registered gentle actions of a group.

Trait Implementations§

Source§

impl Actuator for SignalActuator

Source§

fn graceful_for(&self, group_id: &str) -> Vec<String>

Graceful (adapter) actions that free a group’s memory without a signal, described for the user (e.g. “ollama: unload llama3:8b”). Empty when the group has none (SPEC §10, §13: try these first).
Source§

fn observe(&mut self, snapshot: &Snapshot)

Refreshes per-snapshot state (which model servers currently offer a graceful unload).
Source§

fn execute(&mut self, plan: &ActionPlan) -> Vec<ActionOutcome>

Source§

impl Debug for SignalActuator

Source§

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

Formats the value using the given formatter. Read more
Source§

impl Default for SignalActuator

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl Forget for SignalActuator

§

impl Freeze for SignalActuator
where *const LeafNode<String, Vec<GentleAction>> is !null: Freeze, PhantomData<(Owned, LeafOrInternal)>: Freeze, PhantomData<Box<(String, Vec<GentleAction>)>>: Freeze,

§

impl Move for SignalActuator

§

impl RefUnwindSafe for SignalActuator

§

impl Send for SignalActuator
where NodeRef<Owned, String, Vec<GentleAction>, LeafOrInternal>: Send, BoxRaw<(String, Vec<GentleAction>)>: Send,

§

impl Sync for SignalActuator
where NodeRef<Owned, String, Vec<GentleAction>, LeafOrInternal>: Sync, BoxRaw<(String, Vec<GentleAction>)>: Sync,

§

impl Unpin for SignalActuator
where *const LeafNode<String, Vec<GentleAction>> is !null: Unpin, Box<(String, Vec<GentleAction>)>: Unpin,

§

impl UnsafeUnpin for SignalActuator
where *const LeafNode<String, Vec<GentleAction>> is !null: UnsafeUnpin, PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin, PhantomData<Box<(String, Vec<GentleAction>)>>: UnsafeUnpin,

§

impl UnwindSafe for SignalActuator

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<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

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> 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.