MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / database_open_wait

Function database_open_wait

libatomic/src/daemon/state.rs:31–33  ·  view source on GitHub ↗

The cross-process open grace: redb refuses any open while another process holds the database, so every daemon open — read or write, repository or change store — waits up to this budget for a short-lived writer (a recording agent turn in another process) to finish. The same budget the hook-side waits use; override with `ATOMIC_DB_LOCK_WAIT_MS`.

()

Source from the content-addressed store, hash-verified

29/// writer (a recording agent turn in another process) to finish. The same
30/// budget the hook-side waits use; override with `ATOMIC_DB_LOCK_WAIT_MS`.
31pub fn database_open_wait() -> std::time::Duration {
32 atomic_repository::database_lock_wait()
33}
34
35/// One registered repository: canonical root + the per-repository
36/// serialization gate. redb permits ONE handle per database file even

Callers 6

compute_ref_pair_diffFunction · 0.85
repositoryMethod · 0.85
repository_readonlyMethod · 0.85
change_storeMethod · 0.85
storeMethod · 0.85

Calls 1

database_lock_waitFunction · 0.85

Tested by

no test coverage detected