backup_databases
Documentation for eth_defi.vault.duckdb_backup.backup_databases function.
- backup_databases(client, bucket, registry, now=None, maintenance_id=None)
Back up due, exclusively opened databases once per two days at most.
The gate precedes hashing, snapshotting, upload and compatibility copy. Snapshot keys are immutable. Unchanged due databases update the check receipt without transferring bytes. Errors are observable and throttled too; other registered databases are attempted independently. No local file is deleted.
- Parameters
client (Any) – Authenticated R2 client with conditional write support.
bucket (str) – Private data bucket only.
registry (list[eth_defi.vault.duckdb_backup.DuckDBBackup]) – Explicit logical database registry.
now (Optional[datetime.datetime]) – Optional injected naive UTC time for focused tests.
maintenance_id (Optional[str]) – Named reservation owner; routine exporters pass
None.
- Returns
Per-database
missing,deferred,unchanged,uploadedorfailed.- Return type