Skip to content

feat(reborn): add memory document storage boundary#3078

Merged
serrrfirat merged 5 commits into
reborn-integrationfrom
reborn-land-07-memory-storage-filesystem
Apr 30, 2026
Merged

feat(reborn): add memory document storage boundary#3078
serrrfirat merged 5 commits into
reborn-integrationfrom
reborn-land-07-memory-storage-filesystem

Conversation

@serrrfirat
Copy link
Copy Markdown
Collaborator

Summary

Draft carve-out for PR7 from the existing Reborn memory branch material.

Adds the first memory storage/backend substrate:

crates/ironclaw_memory
docs/reborn/contracts/filesystem.md
docs/reborn/2026-04-25-storage-catalog-and-placement.md

Includes:

  • MemoryDocumentScope and MemoryDocumentPath for file-shaped memory documents;
  • virtual /memory/tenants/{tenant}/users/{user}/projects/{project}/{path} paths;
  • filesystem adapter that routes reads/writes/list/stat to a memory document repository;
  • repository/source-of-truth split so search/index state is derived, not primary;
  • in-memory repository/indexer fixtures for contract tests;
  • DB-backed document repository surfaces for libSQL/Postgres feature configurations;
  • tenant/user/project path isolation and traversal rejection.

Scope boundary

This intentionally does not wire production runtime memory behavior or expose user-visible behavior changes.

PR8 extends this branch with metadata/search/index/embedding/plugin seams and the agent-scoped path mapping that was present later in the old memory branch.

Verification

Passed locally:

cargo fmt --all -- --check
cargo test -p ironclaw_memory
cargo clippy -p ironclaw_memory --all-targets -- -D warnings
cargo test -p ironclaw_architecture
python3.11 scripts/check_no_panics.py --base origin/reborn-integration --head HEAD
bash scripts/pre-commit-safety.sh
git diff --check

Refs #2987.

@github-actions github-actions Bot added size: XL 500+ changed lines scope: docs Documentation scope: dependencies Dependency updates risk: medium Business logic, config, or moderate-risk modules contributor: core 20+ merged PRs labels Apr 29, 2026
@serrrfirat serrrfirat added the reborn IronClaw Reborn architecture and landing work label Apr 29, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the ironclaw_memory crate, which provides filesystem adapters for memory documents, enabling virtual path access to database-backed storage. It includes repository implementations for PostgreSQL and libSQL that maintain compatibility with existing document schemas while enforcing tenant and project isolation. The PR also adds comprehensive documentation for the storage catalog and filesystem contracts, integrates the new crate into the workspace, and performs extensive dependency updates. I have no feedback to provide.

…pr-3078

# Conflicts:
#	Cargo.lock
#	Cargo.toml
Address paranoid review findings in the Reborn memory storage PR:

- scope DB-backed memory rows by tenant/user/project owner key instead of encoding project scope into the relative path
- preserve top-level projects/ documents for no-project memory scopes
- reject file/directory prefix conflicts through the filesystem write path
- treat index refresh as best-effort derived state after committed repository writes
- use partial unique indexes and atomic upserts for DB-backed document writes
- keep Cargo.lock diff scoped to the new ironclaw_memory package entry after merging latest reborn-integration

Verification:
- cargo fmt --check
- cargo test -p ironclaw_memory --features libsql
- cargo test -p ironclaw_memory
- cargo check -p ironclaw_memory --features postgres --locked
- cargo check -p ironclaw_memory --all-features --locked
- cargo clippy -p ironclaw_memory --all-targets --all-features -- -D warnings
- git diff --check
@serrrfirat serrrfirat marked this pull request as ready for review April 30, 2026 12:13
@serrrfirat serrrfirat merged commit 7a6a807 into reborn-integration Apr 30, 2026
18 checks passed
@serrrfirat serrrfirat deleted the reborn-land-07-memory-storage-filesystem branch April 30, 2026 12:30
This was referenced May 7, 2026
@ironclaw-ci ironclaw-ci Bot mentioned this pull request May 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor: core 20+ merged PRs reborn IronClaw Reborn architecture and landing work risk: medium Business logic, config, or moderate-risk modules scope: dependencies Dependency updates scope: docs Documentation size: XL 500+ changed lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant