Skip to main content

CallbackProcessExecutor

Trait CallbackProcessExecutor 

Source
pub trait CallbackProcessExecutor: Send + Sync {
    // Required methods
    fn start(
        &self,
        request: CallbackProcessRequest,
        responder: CallbackProcessResponder,
    );
    fn cancel(&self, request_id: String);
}
Expand description

Host callback interface for executing validated process actions asynchronously.

Required Methods§

Source

fn start( &self, request: CallbackProcessRequest, responder: CallbackProcessResponder, )

Starts executing request asynchronously and settles via responder.

Must return promptly without blocking the calling Tokio worker thread.

Source

fn cancel(&self, request_id: String)

Requests cooperative cancellation for an in-flight request_id (foreground interrupt, /tasks stop, or session teardown).

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§