[InterNetNews/inn] 5e8905: ovsqlite: Add runtime WAL checkpoint to prevent un...
Kevin Bowling
noreply at github.com
Thu May 21 22:00:21 UTC 2026
Branch: refs/heads/main
Home: https://github.com/InterNetNews/inn
Commit: 5e8905387d08d62606829d3c8f67405b08bca4f3
https://github.com/InterNetNews/inn/commit/5e8905387d08d62606829d3c8f67405b08bca4f3
Author: Kevin Bowling <kevin.bowling at kev009.com>
Date: 2026-05-21 (Thu, 21 May 2026)
Changed paths:
M doc/pod/ovsqlite.pod
M samples/ovsqlite.conf
M storage/ovsqlite/ovsqlite-server.c
M storage/ovsqlite/sql-main.sql
Log Message:
-----------
ovsqlite: Add runtime WAL checkpoint to prevent unbounded WAL growth
When WAL mode is enabled with direct readers, the WAL file can grow
without bound if checkpointing never occurs between commits. Add a
configurable walcheckpointthreshold (default 1000 pages) that triggers
a TRUNCATE checkpoint during the server's idle period.
The checkpoint temporarily lowers the busy_timeout to 10 seconds
(from ~31 years) so the server waits for readers to finish their
current queries but doesn't stall indefinitely. Readers use
autocommit with sub-millisecond snapshots, so the checkpoint
typically completes in milliseconds.
Also fix notice() messages being lost after daemon() by registering
message_handlers_notice, remove the unused checkpoint_wal prepared
statement from sql-main.sql, and update close_db() comment.
see #338
To unsubscribe from these emails, change your notification settings at https://github.com/InterNetNews/inn/settings/notifications
More information about the inn-committers
mailing list