You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Default file DBs to WAL + synchronous=NORMAL (3x to 18x autocommit writes) #13
Inside a transaction both modes are fast (83k to 167k/s), so this matters most for callers who do not batch.
Caveat: measured on an external drive; fsync cost depends on the drive.
Proposal
Default file-backed databases to journal_mode=WAL and synchronous=NORMAL, with an option to opt out ({ wal: false }). No effect on :memory: or readonly DBs.
Benchmark report: 2026-11-02, Apple M2 Pro, Node 22, at a7f9ea7.
Re-measured, 5 alternating runs of 2000 autocommit createNode each, medians: internal SSD 1,491/s without WAL vs 4,405/s with WAL (~3x, ranges do not overlap); external drive 1,202/s vs 21,277/s (~18x). The ~22x in the description is the external-drive case; expect ~3x on a fast internal SSD.
changed the title [-]Default file DBs to WAL + synchronous=NORMAL (~22x autocommit writes)[/-][+]Default file DBs to WAL + synchronous=NORMAL (3x to 18x autocommit writes)[/+]on Nov 2, 2026
Activity
michaeloboyle commentedon Nov 2, 2026
Re-measured, 5 alternating runs of 2000 autocommit createNode each, medians: internal SSD 1,491/s without WAL vs 4,405/s with WAL (~3x, ranges do not overlap); external drive 1,202/s vs 21,277/s (~18x). The ~22x in the description is the external-drive case; expect ~3x on a fast internal SSD.
[-]Default file DBs to WAL + synchronous=NORMAL (~22x autocommit writes)[/-][+]Default file DBs to WAL + synchronous=NORMAL (3x to 18x autocommit writes)[/+]