Skip to content

docs(storage): decide CompactStore v5 mapped layout - #6

Open
jarmen423 wants to merge 3 commits into
fix/e0-1-compact-store-v4-stringsfrom
feature/g-em0-r0-mapped-layout-decision
Open

docs(storage): decide CompactStore v5 mapped layout#6
jarmen423 wants to merge 3 commits into
fix/e0-1-compact-store-v4-stringsfrom
feature/g-em0-r0-mapped-layout-decision

Conversation

@jarmen423

Copy link
Copy Markdown

Summary

  • record the G-EM0.R0 decision that v4 is not disk-native
  • specify a single CompactStore v5 payload with checked in-payload ranges
  • add the v4 reopen allocation inventory diagnostic at 1,024/8,192 nodes
  • preserve v1-v4 compatibility and define G-EM0.1/G-EM0.2 source contracts

Verification

  • cargo test -p grafeo-core --lib --features compact-store graph::compact::section:: -- --nocapture
  • cargo test -p grafeo-engine --features compact-store --test compact_store_allocation_inventory -- --nocapture
  • cargo test -p grafeo-engine --features compact-store --test compact_store_large_string_persistence -- --nocapture
  • git diff --check

cargo fmt --all -- --check reports pre-existing formatting differences in unrelated vector/index files on the accepted base.

… wire contract

Repair all independent-review blockers in the R0 decision artifact:

- Correct stale ownership path to database/section_consumer.rs
- Make current-vs-selected reader compatibility wording consistent
  (current E-0 reader supports v1-v4; v5 selected but not emitted/read
  until G-EM0.1)
- Replace coarse/deferred retained-allocation inventory with R0-complete
  source-backed accounting: exact source ranges for every retained owner
  created by deserialize_compact_store, representation/scaling, measured
  production count where evidence exists (4,531,909-edge source-backed
  lower bound), retained bytes/capacity, required operations, and
  unambiguous mapped/eliminated/bounded owner
- Reconcile fresh-process measurements to the field inventory with a
  declared executable tolerance (overhead ratio must stay below payload
  ratio); strengthen the diagnostic test with reconcile_to_inventory
- Enumerate every required operation from packet line 59 with an explicit
  mapped algorithm and complexity bound
- Make the v5 wire contract implementer-ready: exact 48-byte directory
  entry offsets/widths, record widths/padding, offset/length/count rules,
  alignment, three-layer checksum domains (outer section CRC, directory
  CRC, per-segment CRC), conditional required segments, corruption/unknown/
  reserved fail-closed behavior, old-reader behavior; resolve the
  StringOffsets raw-UTF-8 contradiction; assign DictionaryCodeIndex an
  explicit segment kind and encoding; no native struct layout/unsafe casts
- Correct R0 completion language to accept the decision/inventory/RED
  contract, not future G-EM0.1/G-EM0.2 implementation
- Preserve the selected direction: one CompactStore payload v5 with checked
  in-payload range directory; no separate outer ID-index section

Verification: allocation inventory 3x stable (overhead_ratio 6.25-6.67 <
payload_ratio 8.02), section tests 27 passed, large-string persistence
2 passed, rustfmt clean, git diff --check clean.
Name reserved/pad fields with explicit LE byte offsets so NodeTableDirectory,
RelTableDirectory, NodeIdLookup, and EdgeIdLookup each arithmetic-exactly
total element_width 24. Closes G-EM0.R0 repair blocker.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant