pub struct FileSystemStateStore { /* private fields */ }Expand description
File system implementation of StateStore.
Stores states as JSON files organized by partition in a directory structure:
base_path/
├── 2024-01-14/
│ ├── size.json
│ ├── completeness_col1.json
│ └── mean_col2.json
└── 2024-01-15/
└── ...Implementations§
Trait Implementations§
Source§impl StateStore for FileSystemStateStore
impl StateStore for FileSystemStateStore
Source§fn load_state<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<StateMap>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_state<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<StateMap>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Loads the state for a specific partition. Read more
Source§fn save_state<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
state: StateMap,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_state<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
state: StateMap,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Saves the state for a specific partition. Read more
Source§fn list_partitions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_partitions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Lists all known partitions. Read more
Source§fn delete_partition<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_partition<'life0, 'life1, 'async_trait>(
&'life0 self,
partition: &'life1 str,
) -> Pin<Box<dyn Future<Output = AnalyzerResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Deletes the state for a specific partition. Read more
Source§fn load_states_batch<'life0, 'life1, 'async_trait>(
&'life0 self,
partitions: &'life1 [String],
) -> Pin<Box<dyn Future<Output = AnalyzerResult<HashMap<String, StateMap>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_states_batch<'life0, 'life1, 'async_trait>(
&'life0 self,
partitions: &'life1 [String],
) -> Pin<Box<dyn Future<Output = AnalyzerResult<HashMap<String, StateMap>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Loads states for multiple partitions. Read more
Auto Trait Implementations§
impl Freeze for FileSystemStateStore
impl RefUnwindSafe for FileSystemStateStore
impl Send for FileSystemStateStore
impl Sync for FileSystemStateStore
impl Unpin for FileSystemStateStore
impl UnwindSafe for FileSystemStateStore
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> 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