pub struct BackupOptions {
pub lock: LockMode,
pub indexes: bool,
pub exclude_tables: Vec<String>,
pub encryption: Option<CipherOptions>,
}Fields§
§lock: LockModeHow the writer lock is taken for the length of the copy. LockMode::Skip copies a database
a writer may be appending to, which can capture a half-written last line (the engine cuts
such a tail off on the next writable open) — but nothing worse.
indexes: boolAlso copy the <table>.idx snapshots. Off by default: they are caches the engine rebuilds
from the logs, so leaving them out makes a backup smaller and no less complete.
exclude_tables: Vec<String>Tables whose data (log files, partitions, images, snapshot) is left out; their declarations stay in the metadata document, so the copy opens with them empty. A name the database does not declare is refused.
encryption: Option<CipherOptions>The keys of an encrypted database: the files are copied as they are (still sealed), but the metadata document has to be opened to know which files the database owns.