pub trait StateBackendCore: Send + Sync {
// Required methods
fn upsert_invocation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation: &'life1 InvocationDTO,
call: &'life2 CallDTO,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn get_invocation<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<InvocationDTO>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_call<'life0, 'life1, 'async_trait>(
&'life0 self,
call_id: &'life1 CallId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<CallDTO>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn store_result<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
result: &'life2 str,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn get_result<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<String>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn store_error<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
error: &'life2 TaskError,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn get_error<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<TaskError>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn add_history<'life0, 'life1, 'async_trait>(
&'life0 self,
history: &'life1 InvocationHistory,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_history<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Vec<InvocationHistory>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn purge<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
// Provided methods
fn backend_name(&self) -> &'static str { ... }
fn usage_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Vec<(&'static str, String)>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
}Expand description
Core state persistence — invocation storage, results, history, and cleanup.
All methods in this sub-trait are required (no defaults).
Required Methods§
Sourcefn upsert_invocation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation: &'life1 InvocationDTO,
call: &'life2 CallDTO,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn upsert_invocation<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation: &'life1 InvocationDTO,
call: &'life2 CallDTO,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Store or update an invocation and its associated call.
Sourcefn get_invocation<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<InvocationDTO>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_invocation<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<InvocationDTO>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Retrieve an invocation by ID.
Sourcefn get_call<'life0, 'life1, 'async_trait>(
&'life0 self,
call_id: &'life1 CallId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<CallDTO>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_call<'life0, 'life1, 'async_trait>(
&'life0 self,
call_id: &'life1 CallId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<CallDTO>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Retrieve a call by ID.
Sourcefn store_result<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
result: &'life2 str,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn store_result<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
result: &'life2 str,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Store the result of a successful invocation.
Sourcefn get_result<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_result<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Retrieve the result of a completed invocation.
Sourcefn store_error<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
error: &'life2 TaskError,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn store_error<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
error: &'life2 TaskError,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Store error information for a failed invocation.
Sourcefn get_error<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<TaskError>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_error<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Option<TaskError>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Retrieve error information for a failed invocation.
Sourcefn add_history<'life0, 'life1, 'async_trait>(
&'life0 self,
history: &'life1 InvocationHistory,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn add_history<'life0, 'life1, 'async_trait>(
&'life0 self,
history: &'life1 InvocationHistory,
) -> Pin<Box<dyn Future<Output = RustvelloResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Record a status change in the audit log.
Sourcefn get_history<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Vec<InvocationHistory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_history<'life0, 'life1, 'async_trait>(
&'life0 self,
invocation_id: &'life1 InvocationId,
) -> Pin<Box<dyn Future<Output = RustvelloResult<Vec<InvocationHistory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get the full status history for an invocation.
Provided Methods§
Sourcefn backend_name(&self) -> &'static str
fn backend_name(&self) -> &'static str
Human-readable name of this backend implementation.