Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ pass its own paths.
<name>.log.trunk the data — chunked zstd frames
<name>.log.rings the write-time index (per-chunk time bounds)
<name>.log.grain optional token index (present with --index)
<name>.log.grain.commit where the grain ends; a hint, safe to delete
<name>.log.bark JSON manifest: durable identity + retention
<name>.log.sap optional write-ahead sidecar (present with --wal;
always, for the acking network intakes)
Expand Down
8 changes: 8 additions & 0 deletions docs/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,14 @@ append-only entry per chunk. Three rules:
source and re-check it after loading the grain, dropping the grain (and
scanning) rather than trusting a mismatched pair.

The grain states neither how many records it holds nor where the last one
ends, so a write that had to find out would read it whole. `<name>.grain.commit`
records both after each completed write, bound to the grain's inode and the
bytes at its two ends, so a grain replaced or rebased by anyone else is walked
once instead of trusted. Whatever lies past the committed end is a torn write
and is cut before the next append. It is a hint under rule 1: delete it and the
next write walks the grain once.

Consequences worth knowing: chunk size is an index-selectivity knob
(smaller chunks → sharper lookups, more overhead), the grain trails a live
writer by at most its once-a-second maintenance tick (lagging entries just
Expand Down
2 changes: 2 additions & 0 deletions packaging/timberfs.1
Original file line number Diff line number Diff line change
Expand Up @@ -3069,6 +3069,8 @@ nothing says so.
.TP
.BR .grain ", " .rings ", " .trunk " and " .sap
are derived or are the data itself.
.B .grain.commit
beside the grain is a hint about where it ends; deleting it costs one walk.
.B reindex
rebuilds the first;
.B identity
Expand Down
Loading