Trait MetaSnapshotStorage

Source
pub trait MetaSnapshotStorage:
    'static
    + Sync
    + Send {
    // Required methods
    fn create<'life0, 'life1, 'async_trait, S>(
        &'life0 self,
        snapshot: &'life1 MetaSnapshot<S>,
        remarks: Option<String>,
    ) -> Pin<Box<dyn Future<Output = BackupResult<()>> + Send + 'async_trait>>
       where S: 'async_trait + Metadata,
             Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn get<'life0, 'async_trait, S>(
        &'life0 self,
        id: MetaSnapshotId,
    ) -> Pin<Box<dyn Future<Output = BackupResult<MetaSnapshot<S>>> + Send + 'async_trait>>
       where S: 'async_trait + Metadata,
             Self: 'async_trait,
             'life0: 'async_trait;
    fn manifest(&self) -> Arc<MetaSnapshotManifest>;
    fn refresh_manifest<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = BackupResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn delete<'life0, 'life1, 'async_trait>(
        &'life0 self,
        ids: &'life1 [MetaSnapshotId],
    ) -> Pin<Box<dyn Future<Output = BackupResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}

Required Methods§

Source

fn create<'life0, 'life1, 'async_trait, S>( &'life0 self, snapshot: &'life1 MetaSnapshot<S>, remarks: Option<String>, ) -> Pin<Box<dyn Future<Output = BackupResult<()>> + Send + 'async_trait>>
where S: 'async_trait + Metadata, Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Creates a snapshot.

Source

fn get<'life0, 'async_trait, S>( &'life0 self, id: MetaSnapshotId, ) -> Pin<Box<dyn Future<Output = BackupResult<MetaSnapshot<S>>> + Send + 'async_trait>>
where S: 'async_trait + Metadata, Self: 'async_trait, 'life0: 'async_trait,

Gets a snapshot by id.

Source

fn manifest(&self) -> Arc<MetaSnapshotManifest>

Gets local snapshot manifest.

Source

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

Refreshes local snapshot manifest.

Source

fn delete<'life0, 'life1, 'async_trait>( &'life0 self, ids: &'life1 [MetaSnapshotId], ) -> Pin<Box<dyn Future<Output = BackupResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Deletes snapshots by ids.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§