pub struct Pipeline {
pub routing: RoutingConfig,
pub providers: HashMap<String, Arc<dyn Provider>>,
}Expand description
The part of a client that a config reload replaces: the routing rules and the providers they name. Swapped as one unit, so a signal never sees new routes with old providers.
Fields§
§routing: RoutingConfig§providers: HashMap<String, Arc<dyn Provider>>Implementations§
Source§impl Pipeline
impl Pipeline
Sourcepub fn from_config(config: &Config) -> Self
pub fn from_config(config: &Config) -> Self
Registers the configured providers. console is always present
because routing falls back to it.
Sourcepub fn preview(
&self,
signal: &Signal,
only: Option<&str>,
) -> Result<Vec<(String, Option<Value>)>, SignalError>
pub fn preview( &self, signal: &Signal, only: Option<&str>, ) -> Result<Vec<(String, Option<Value>)>, SignalError>
What each provider signal routes to would be sent, in plan
order, without sending anything or recording the signal; with
only, just that provider whether or not a route picks it. A
provider that can’t show its payload has None.
Auto Trait Implementations§
impl !RefUnwindSafe for Pipeline
impl !UnwindSafe for Pipeline
impl Freeze for Pipeline
impl Send for Pipeline
impl Sync for Pipeline
impl Unpin for Pipeline
impl UnsafeUnpin for Pipeline
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