Gate WAL checkpoint threshold behind SQLITE_TEST - #2534
Conversation
DOLTLITE_WAL_CHECKPOINT_THRESHOLD was a live getenv in production, so a process environment could disable checkpoints and force full WAL replay on open. Read it only in SQLITE_TEST / DOLTLITE_MECH_REPRO builds, same as the pending-drain injector. CLI still uses the 64MiB default. test/doltlite_checkpoint_threshold_env.sh sets the env to 1 byte on the CLI and checks that a small commit does not stamp a checkpoint. Co-Authored-By: Grok 4.6 <noreply@x.ai>
|
SummaryCoverage spans normal database writes and reopen flows, boundary and malformed configuration values, safe handling of failed or interrupted checkpoints, concurrent close-and-commit behavior, data recovery, and release-versus-diagnostic build behavior. Overall, the change preserves committed data and safe defaults across happy paths, edge cases, failure recovery, and concurrency scenarios. Safe to merge — the exercised behaviors are healthy across persistence, recovery, concurrency, configuration handling, and build-mode boundaries, with no PR-attributable regressions or unresolved failures. No merge blocker is indicated by this run. Tests run by Ito
Tip Reply with @itoqa to send us feedback on this test run. |
DoltLite performance vs PR base
blobpk details
compositepk details
int details
textpk details
vc details
All relative performance gates passed. |
DoltLite source coverage
Merged 202 pooled raw profiles from the distributed Linux correctness jobs. Per-file coverage (98 files)
|

Beta review item 5:
DOLTLITE_WAL_CHECKPOINT_THRESHOLDwas a livegetenvin production. A process environment could drop the checkpoint interval to 1 byte (or skip checkpoints) and force full WAL replay on every open.Match
DOLTLITE_CHUNK_PENDING_DRAIN_LIMIT: honor the env only underSQLITE_TESTorDOLTLITE_MECH_REPRO. Release CLI/libdoltlite stay on the 64MiB default.testfixturestill sees the knob (doltlite_recover_corruption.test).doltlite_checkpoint_perf.shuses the CLI with the same 64MiB default, so it is unchanged.test/doltlite_checkpoint_threshold_env.shfails on an ungated CLI (env=1 stamps a checkpoint on an 8KiB commit) and passes after the gate.Co-Authored-By: Grok 4.6 noreply@x.ai