Hacker News new | ask | show | jobs
by mshenfield 1942 days ago
One trick of `pragma journal_mode = WAL` is that even with synchronous normal, SQLite syncs when you close the last connection [1]. So re-using a connection is key to getting the full benefits if you're executing commands from a single thread/process.

[1] https://sqlite.com/wal.html#the_wal_file