pub struct BackupTarget<'a> {
pub store: &'a Store,
pub storage_key: Option<[u8; 32]>,
pub environment: BackupEnvironment,
}Expand description
The store a backup is read from, or a restore staged into, and how it is protected at rest.
Fields§
§store: &'a Store§storage_key: Option<[u8; 32]>The at-rest key every keyspace except bootstrap is encrypted under,
or None for a plain store.
environment: BackupEnvironmentImplementations§
Source§impl BackupTarget<'_>
impl BackupTarget<'_>
Sourcepub fn keyspace(&self, name: &str) -> Result<KeyspaceHandle, AppError>
pub fn keyspace(&self, name: &str) -> Result<KeyspaceHandle, AppError>
Open name the way the running VTA does: encrypted under
Self::storage_key when there is one.
Never use this for bootstrap, which is unencrypted in every
deployment — open that with store.keyspace directly.
Sourcepub fn bootstrap(&self) -> Result<KeyspaceHandle, AppError>
pub fn bootstrap(&self) -> Result<KeyspaceHandle, AppError>
The unencrypted bootstrap keyspace.
Trait Implementations§
Source§impl<'a> Clone for BackupTarget<'a>
impl<'a> Clone for BackupTarget<'a>
impl<'a> Copy for BackupTarget<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for BackupTarget<'a>
impl<'a> !UnwindSafe for BackupTarget<'a>
impl<'a> Freeze for BackupTarget<'a>
impl<'a> Send for BackupTarget<'a>
impl<'a> Sync for BackupTarget<'a>
impl<'a> Unpin for BackupTarget<'a>
impl<'a> UnsafeUnpin for BackupTarget<'a>
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