Skip to main content

WorkflowProvider

Trait WorkflowProvider 

Source
pub trait WorkflowProvider:
    Send
    + Sync
    + 'static {
Show 21 methods // Provided methods fn configure<'life0, 'life1, 'async_trait>( &'life0 self, _name: &'life1 str, _config: Map<String, Value>, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn metadata(&self) -> Option<RuntimeMetadata> { ... } fn warnings(&self) -> Vec<String> { ... } fn health_check<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn start<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn close<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn apply_definition<'life0, 'async_trait>( &'life0 self, _request: ApplyWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn get_definition<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn list_definitions<'life0, 'async_trait>( &'life0 self, _request: ListWorkflowProviderDefinitionsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<ListWorkflowProviderDefinitionsResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn set_definition_paused<'life0, 'async_trait>( &'life0 self, _request: SetWorkflowProviderDefinitionPausedRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn set_activation_paused<'life0, 'async_trait>( &'life0 self, _request: SetWorkflowProviderActivationPausedRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn delete_definition<'life0, 'async_trait>( &'life0 self, _request: DeleteWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn start_run<'life0, 'async_trait>( &'life0 self, _request: StartWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn list_runs<'life0, 'async_trait>( &'life0 self, _request: ListWorkflowProviderRunsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<ListWorkflowProviderRunsResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn get_run<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn get_run_events<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunEventsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<GetWorkflowProviderRunEventsResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn get_run_output<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunOutputRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<GetWorkflowProviderRunOutputResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn cancel_run<'life0, 'async_trait>( &'life0 self, _request: CancelWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn signal_run<'life0, 'async_trait>( &'life0 self, _request: SignalWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<SignalWorkflowRunResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn signal_or_start_run<'life0, 'async_trait>( &'life0 self, _request: SignalOrStartWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<SignalWorkflowRunResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn deliver_event<'life0, 'async_trait>( &'life0 self, _request: DeliverWorkflowProviderEventRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowEvent>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... }
}
Expand description

Provider trait for serving the Gestalt workflow-provider protocol.

Provided Methods§

Source

fn configure<'life0, 'life1, 'async_trait>( &'life0 self, _name: &'life1 str, _config: Map<String, Value>, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Configures the provider before it starts serving requests.

Source

fn metadata(&self) -> Option<RuntimeMetadata>

Returns runtime metadata that should augment the static manifest.

Source

fn warnings(&self) -> Vec<String>

Returns non-fatal warnings the host should surface to users.

Source

fn health_check<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Performs an optional health check.

Source

fn start<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Starts provider-owned background work after configuration.

Source

fn close<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Shuts the provider down before the runtime exits.

Source

fn apply_definition<'life0, 'async_trait>( &'life0 self, _request: ApplyWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Applies a workflow definition, creating or updating it.

Source

fn get_definition<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Fetches one workflow definition.

Source

fn list_definitions<'life0, 'async_trait>( &'life0 self, _request: ListWorkflowProviderDefinitionsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<ListWorkflowProviderDefinitionsResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Lists workflow definitions.

Source

fn set_definition_paused<'life0, 'async_trait>( &'life0 self, _request: SetWorkflowProviderDefinitionPausedRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Pauses or resumes a workflow definition.

Source

fn set_activation_paused<'life0, 'async_trait>( &'life0 self, _request: SetWorkflowProviderActivationPausedRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowDefinition>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Pauses or resumes one activation.

Source

fn delete_definition<'life0, 'async_trait>( &'life0 self, _request: DeleteWorkflowProviderDefinitionRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Deletes a workflow definition.

Source

fn start_run<'life0, 'async_trait>( &'life0 self, _request: StartWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Starts a workflow run.

Source

fn list_runs<'life0, 'async_trait>( &'life0 self, _request: ListWorkflowProviderRunsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<ListWorkflowProviderRunsResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Lists workflow runs.

Source

fn get_run<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Fetches one workflow run.

Source

fn get_run_events<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunEventsRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<GetWorkflowProviderRunEventsResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Fetches the events of a workflow run.

Source

fn get_run_output<'life0, 'async_trait>( &'life0 self, _request: GetWorkflowProviderRunOutputRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<GetWorkflowProviderRunOutputResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Fetches the output value of a workflow run.

Source

fn cancel_run<'life0, 'async_trait>( &'life0 self, _request: CancelWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowRun>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Cancels a workflow run.

Source

fn signal_run<'life0, 'async_trait>( &'life0 self, _request: SignalWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<SignalWorkflowRunResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Signals an existing workflow run.

Source

fn signal_or_start_run<'life0, 'async_trait>( &'life0 self, _request: SignalOrStartWorkflowProviderRunRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<SignalWorkflowRunResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Signals a run, starting it first when absent.

Source

fn deliver_event<'life0, 'async_trait>( &'life0 self, _request: DeliverWorkflowProviderEventRequest, ) -> Pin<Box<dyn Future<Output = ProviderResult<WorkflowEvent>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Delivers an external event to the workflow engine.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§