Readers must check every count against its limit before allocating anything, and treat a violation as Corrupt. This table gathers the limits that the spec states.
| Limit |
Value |
Page |
varint length |
at most 10 bytes; a 10th byte that still carries continuation is Corrupt |
varint |
count(limit) |
the varint must be at most the limit |
count(limit) |
| Seal trailer |
32 bytes |
Seal trailer |
| Limit |
Value |
Page |
| Block size |
4096 bytes, payload at most 4048 |
WAL block |
Record payload len |
at most 16 MiB |
Record framing |
| Segment size |
default 64 MiB, a multiple of 4096, at least 4 blocks |
Segments |
Unflushed bytes before commit_relaxed falls back to commit |
8 MiB (UNFLUSHED_CAP) |
Durability modes |
| Relaxed flush window |
1 ms to 1 s, default 5 ms |
Durability modes |
| Batches in flight |
wal_flushers, default 3 |
Durability modes |
| Old segment cleanup |
after open and every 512 commits |
Recovery |
| Limit |
Value |
Page |
| File size |
a multiple of 4096 and at least 96 bytes |
SEAM data file |
Frame raw_len |
at most 64 MiB |
Frame |
| Footer revision |
1 to 5; above 5 is NewerFormat("sst footer") |
Footer |
| Block size |
writer target 16 KiB raw (64 KiB columnar, 128 KiB cold); never above 64 MiB |
Row block |
| Block alignment |
storage.block_align_kb, default 16 KiB |
SEAM data file |
| Row-block restart interval |
every 16th entry |
Row block |
| Bloom bits per key |
writers use 10 (SPEC V52 requires at least 10); readers do not check it |
Bloom filter |
| Bloom ranged prefixes |
at most 256, each 1 to 255 bytes |
Ranged tail |
| Stats revision |
1 or 2; above 2 is NewerFormat("block stats") |
Block stats frame |
| Stats columns per block |
count(1024) |
Block stats frame |
| Stats bytes bounds |
count(64) each |
Column stats |