mpackdb
All repositories: gitoria
1.2 KB
# Changelog## 1.0.8- Index recovery hardening (einicherai#6). Indexes are no longer trusted blindly on open: the index files arechecked against the data file (every line parses, ends inside the data file / covered range, and a sample ofentries points at a record whose size header matches). A stale, torn or foreign index is rebuilt from the data file.- Index files are written atomically (tmp + rename); a crash while persisting can no longer leave a torn index.- Compaction removes the index state file *before* swapping the data file, so a crash between the swap and theindex rebuild forces a rebuild on the next open.- Regression tests: `tests/index-recovery.test.js` (+ `tests/repro-bug1-compaction-pk.mjs`, `tests/repro-bug2-hardkill.mjs`).- Stores written by 1.0.6 (wrong pk offsets after compaction -> "Data read, but end of buffer not reached";indexes not persisted after a hard kill) open and are repaired automatically; no record is lost.- Note: 1.0.7 already fixed both reported symptoms for stores it rebuilt (index rebuild after compaction, `idxstate.json`catch-up of the unpersisted data tail). Upgrade from 1.0.6 is the actual fix for the report.## 1.0.7- Multi-process safety, index catch-up (`idxstate.json`), stale lock takeover, index hints.
Branches
- mastermain branch
Latest commits
- cde6b2751.0.8: validate indexes against the data file on open, atomic index writes, invalidate index state before compaction; tests for pk find after compaction and hard killmre
- 87888725release 1.0.7caramboleyo
- c4cdb9b6node: import prefixes (Deno compat) + pre-existing index-state WIPcaramboleyo
- 0afb8f4bupdate now must be a callbackcaramboleyo
- cde73eb4release 1.0.6caramboleyo
- d01dda02add index hints, intersection, boundingBox; remove findByIndexcaramboleyo
- b8ffc1a0release 1.0.5caramboleyo
- d47876a1reimplemented lost features like indexed find and more testscaramboleyo
- 7f08da9afixed insert ignoring model definitioncaramboleyo
- 705774a9added flush before findcaramboleyo
- b4db6391initial commitcaramboleyo