GraphObserver

Trait GraphObserver 

Source
pub trait GraphObserver: Send + Sync {
    // Required methods
    fn on_execution_start<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        graph_id: &'life1 str,
        context: &'life2 ExecutionContext,
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn on_execution_end<'life0, 'life1, 'async_trait>(
        &'life0 self,
        graph_id: &'life1 str,
        success: bool,
        duration: Duration,
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn on_node_start<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        node_id: &'life1 NodeId,
        context: &'life2 ExecutionContext,
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn on_node_end<'life0, 'life1, 'async_trait>(
        &'life0 self,
        node_id: &'life1 NodeId,
        success: bool,
        duration: Duration,
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn on_state_change<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        key: &'life1 str,
        old_value: Option<&'life2 str>,
        new_value: &'life3 str,
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait;
}
Expand description

Graph execution observer

Required Methods§

Source

fn on_execution_start<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, graph_id: &'life1 str, context: &'life2 ExecutionContext, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Called when graph execution starts

Source

fn on_execution_end<'life0, 'life1, 'async_trait>( &'life0 self, graph_id: &'life1 str, success: bool, duration: Duration, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Called when graph execution ends

Source

fn on_node_start<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, node_id: &'life1 NodeId, context: &'life2 ExecutionContext, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Called when node execution starts

Source

fn on_node_end<'life0, 'life1, 'async_trait>( &'life0 self, node_id: &'life1 NodeId, success: bool, duration: Duration, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Called when node execution ends

Source

fn on_state_change<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, key: &'life1 str, old_value: Option<&'life2 str>, new_value: &'life3 str, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Called when state changes

Implementors§