pub struct DbGraphStore { /* private fields */ }Expand description
Database-backed implementation of RawGraphStore.
Implementations§
Source§impl DbGraphStore
impl DbGraphStore
Sourcepub fn new(pool: DbPool) -> Self
pub fn new(pool: DbPool) -> Self
Create a new DbGraphStore backed by the given pool.
Trait Implementations§
Source§impl Clone for DbGraphStore
impl Clone for DbGraphStore
Source§fn clone(&self) -> DbGraphStore
fn clone(&self) -> DbGraphStore
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DbGraphStore
impl Debug for DbGraphStore
Source§impl RawGraphStore for DbGraphStore
impl RawGraphStore for DbGraphStore
Source§async fn save_graph(
&self,
id: &str,
goal: &str,
status: &str,
graph_json: &str,
created_at: &str,
finished_at: Option<&str>,
) -> Result<(), MemoryError>
async fn save_graph( &self, id: &str, goal: &str, status: &str, graph_json: &str, created_at: &str, finished_at: Option<&str>, ) -> Result<(), MemoryError>
Persist a graph (upsert by
id). Read moreSource§async fn load_graph(&self, id: &str) -> Result<Option<String>, MemoryError>
async fn load_graph(&self, id: &str) -> Result<Option<String>, MemoryError>
Load a graph by its string UUID. Read more
Source§async fn list_graphs(
&self,
limit: u32,
) -> Result<Vec<GraphSummary>, MemoryError>
async fn list_graphs( &self, limit: u32, ) -> Result<Vec<GraphSummary>, MemoryError>
Source§async fn delete_graph(&self, id: &str) -> Result<bool, MemoryError>
async fn delete_graph(&self, id: &str) -> Result<bool, MemoryError>
Delete a graph by its string UUID. Read more
Auto Trait Implementations§
impl Freeze for DbGraphStore
impl !RefUnwindSafe for DbGraphStore
impl Send for DbGraphStore
impl Sync for DbGraphStore
impl Unpin for DbGraphStore
impl UnsafeUnpin for DbGraphStore
impl !UnwindSafe for DbGraphStore
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request