Skip to main content

RouteController

Trait RouteController 

Source
pub trait RouteController: Send + Sync {
    // Required methods
    fn start_route<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        route_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn stop_route<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        route_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn restart_route<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        route_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn suspend_route<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        route_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn resume_route<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        route_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn start_all_routes<'life0, 'async_trait>(
        &'life0 mut self,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             Self: 'async_trait;
    fn stop_all_routes<'life0, 'async_trait>(
        &'life0 mut self,
    ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             Self: 'async_trait;
}
Expand description

Trait for managing route lifecycle operations.

Implementations provide imperative execution operations only; canonical lifecycle state is exposed via runtime query APIs.

Required Methods§

Source

fn start_route<'life0, 'life1, 'async_trait>( &'life0 mut self, route_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Start a specific route by its ID.

§Errors

Returns a CamelError if the route cannot be started.

Source

fn stop_route<'life0, 'life1, 'async_trait>( &'life0 mut self, route_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Stop a specific route by its ID.

§Errors

Returns a CamelError if the route cannot be stopped.

Source

fn restart_route<'life0, 'life1, 'async_trait>( &'life0 mut self, route_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Restart a specific route by its ID.

§Errors

Returns a CamelError if the route cannot be restarted.

Source

fn suspend_route<'life0, 'life1, 'async_trait>( &'life0 mut self, route_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Suspend a specific route by its ID.

§Errors

Returns a CamelError if the route cannot be suspended.

Source

fn resume_route<'life0, 'life1, 'async_trait>( &'life0 mut self, route_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Resume a suspended route by its ID.

§Errors

Returns a CamelError if the route cannot be resumed.

Source

fn start_all_routes<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Start all routes in the context.

§Errors

Returns a CamelError if any route cannot be started.

Source

fn stop_all_routes<'life0, 'async_trait>( &'life0 mut self, ) -> Pin<Box<dyn Future<Output = Result<(), CamelError>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Stop all routes in the context.

§Errors

Returns a CamelError if any route cannot be stopped.

Implementors§