Skip to content

feat: file-backed blob store + multi-process IPC integration test#88

Merged
transfix merged 2 commits into
masterfrom
feature/file-blob-store-and-ipc-integration
May 23, 2026
Merged

feat: file-backed blob store + multi-process IPC integration test#88
transfix merged 2 commits into
masterfrom
feature/file-blob-store-and-ipc-integration

Conversation

@transfix
Copy link
Copy Markdown
Owner

Summary

Add two new capabilities to the distributed state infrastructure:

File-backed blob store (file_state_blob_store)

  • Filesystem-backed content-addressed blob store using a git-style 2-char prefix directory layout (<root>/ab/cdef01...)
  • Atomic writes via temp-file + rename(2)
  • SHA-256 deduplication
  • Directory scanning on construction to rebuild in-memory index
  • Thread-safe with mutex protection
  • 13 tests covering CRUD, persistence across instances, git-style layout verification, 1 MiB large blobs, 50-thread concurrent writes, empty blobs, file cleanup on erase

Multi-process IPC integration test (state_multiprocess_ipc_test)

  • Tests that fork() two OS processes and replicate state over a real Unix domain socket connection
  • ValueReplication: parent writes value, child receives via IPC
  • BidirectionalReplication: both processes write, each receives the other's value
  • MetadataReplication: parent sets value + comment, child receives both
  • POSIX-only (#ifndef _WIN32)

Test results

  • 13 file blob store tests: all pass
  • 3 multi-process IPC tests: all pass

transfix added 2 commits May 22, 2026 16:03
Add file_state_blob_store: a filesystem-backed content-addressed blob
store using a git-style 2-char prefix directory layout.  Blobs are
written atomically via temp-file + rename(2) and deduplicated by
SHA-256 digest.  The store scans the root directory on construction to
rebuild its in-memory index.

Add state_multiprocess_ipc_test: three integration tests that fork()
two processes and replicate state mutations over a real Unix domain
socket connection.  Tests cover unidirectional value replication,
bidirectional replication, and metadata (comment) replication.

- 13 file blob store tests (CRUD, persistence, concurrency, layout)
- 3 multi-process IPC tests (POSIX-only, guarded by #ifndef _WIN32)
- All 16 tests pass locally
@transfix transfix merged commit 263b8c7 into master May 23, 2026
14 checks passed
@transfix transfix deleted the feature/file-blob-store-and-ipc-integration branch May 23, 2026 04:29
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