pub struct SqliteOutputStore { /* private fields */ }Expand description
SQLite-backed OutputStore.
Implementations§
Source§impl SqliteOutputStore
impl SqliteOutputStore
Sourcepub async fn open(
path: impl AsRef<Path>,
) -> Result<(Self, AsyncIsleDriver), OutputStoreError>
pub async fn open( path: impl AsRef<Path>, ) -> Result<(Self, AsyncIsleDriver), OutputStoreError>
Open (or create) a SQLite file and apply the schema.
Sourcepub async fn open_in_memory() -> Result<(Self, AsyncIsleDriver), OutputStoreError>
pub async fn open_in_memory() -> Result<(Self, AsyncIsleDriver), OutputStoreError>
Open an ephemeral in-memory database (tests).
Trait Implementations§
Source§impl OutputStore for SqliteOutputStore
impl OutputStore for SqliteOutputStore
Source§fn append<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
attempt: u32,
producer_agent: &'life2 str,
event: OutputEvent,
parent_refs: Vec<OutputRef>,
) -> Pin<Box<dyn Future<Output = Result<OutputRef, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn append<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
attempt: u32,
producer_agent: &'life2 str,
event: OutputEvent,
parent_refs: Vec<OutputRef>,
) -> Pin<Box<dyn Future<Output = Result<OutputRef, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Intake an event, allocate an id, and register the record. Returns the
freshly allocated ref.
Source§fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 OutputRef,
) -> Pin<Box<dyn Future<Output = Result<OutputRecord, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 OutputRef,
) -> Pin<Box<dyn Future<Output = Result<OutputRecord, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Look up a record by id (LC2
IN_REFS resolution — the value handed
to the next spawn on handoff).Source§fn get_latest_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<OutputRecord, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_latest_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<OutputRecord, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Look up the latest record emitted under the given producer name
(
out_name addressing — the logical, agent-based sibling of get).
Names are producer-scoped, not task-scoped: the newest emit wins.Source§fn list_for_attempt<'life0, 'life1, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
attempt: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<OutputRecord>, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_for_attempt<'life0, 'life1, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
attempt: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<OutputRecord>, OutputStoreError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List every record for a given
(task_id, attempt) pair. Used where
the dispatch path pulls the verdict view.Auto Trait Implementations§
impl Freeze for SqliteOutputStore
impl RefUnwindSafe for SqliteOutputStore
impl Send for SqliteOutputStore
impl Sync for SqliteOutputStore
impl Unpin for SqliteOutputStore
impl UnsafeUnpin for SqliteOutputStore
impl UnwindSafe for SqliteOutputStore
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more