Skip to content

Commit

Permalink
refactor(store)!: simplify store interface and improve tests (#104)
Browse files Browse the repository at this point in the history
BREAKING CHANGES:
- Remove `get_size()` method from IpldStore trait and replace with `get_block_count()`
- Remove PlaceholderStore implementation
- Make `is_empty()` a default implementation based on block count
- Rename MemoryStore::new to MemoryStore::with_chunker_and_layout

Changes:
- Improve test coverage for MemoryStore with more focused test cases
- Update ASCII diagram documentation for FlatLayout
- Add workspace-level tempfile dependency
- Update tempfile to 3.15.0
- Add hex and libipld dependencies to monofs
  • Loading branch information
appcypher authored Jan 12, 2025
1 parent 4e01f19 commit 722b112
Show file tree
Hide file tree
Showing 14 changed files with 743 additions and 163 deletions.
8 changes: 6 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ monoutils-store = { version = "0.2", path = "./monoutils-store" }
monoutils = { version = "0.2", path = "./monoutils" }
chrono = { version = "0.4", features = ["serde"] }
criterion = "0.5"
tempfile = "3.15"
test-log = "0.2"
typed-path = "0.10"
toml = "0.8"
Expand Down
2 changes: 1 addition & 1 deletion monocore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ serde_json.workspace = true
sha2.workspace = true
signal-hook = "0.3.17"
structstruck.workspace = true
tempfile = "3.14.0"
tempfile.workspace = true
thiserror.workspace = true
tokio.workspace = true
toml.workspace = true
Expand Down
3 changes: 3 additions & 0 deletions monofs/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ serde_json.workspace = true
monoutils.workspace = true
serde_ipld_dagcbor.workspace = true
pretty-error-debug.workspace = true
libipld.workspace = true
hex.workspace = true
tempfile.workspace = true
Loading

0 comments on commit 722b112

Please sign in to comment.