feat(store): add filesystem backends (DirectFile, JSONMutexDB, CAS)#824
Merged
feat(store): add filesystem backends (DirectFile, JSONMutexDB, CAS)#824
Conversation
Signed-off-by: Xe Iaso <xe@tigrisdata.com>
Add design document for three filesystem-based store backends: - DirectFile: simple key→file mapping - JSONMutexDB: JSON index with mutex locking - CAS: content-addressable storage with BoltDB index Assisted-by: GLM 4.7 via Claude Code Reviewbot-request: yes Signed-off-by: Xe Iaso <xe@tigrisdata.com>
Prepare for git worktree-based isolated development. Assisted-by: GLM 4.7 via Claude Code Reviewbot-request: yes Signed-off-by: Xe Iaso <xe@tigrisdata.com>
Add three filesystem-based implementations of the store Interface: - DirectFile: simple key→file mapping with nested directory support - Keys like "foo/bar/baz" create file at baseDir/foo/bar/baz - Validates keys to prevent path traversal (.. segments) - Uses filepath.WalkDir for prefix-based listing - JSONMutexDB: JSON index with mutex-protected concurrent access - In-memory index persisted to index.json - Data files stored in data/ subdirectory - RWMutex for concurrent read safety - Suitable for small-medium datasets - CAS: content-addressable storage with BoltDB index - Deduplicates data by SHA-256 hash - Objects sharded as objects/aa/bb/<hash> - BoltDB for key→hash mappings - Implements Closer for explicit cleanup Also add Closer interface and Close() helper function for optional cleanup of store backends. Assisted-by: GLM 4.7 via Claude Code Reviewbot-request: yes Signed-off-by: Xe Iaso <xe@tigrisdata.com>
Contributor
|
The latest Buf updates on your PR. Results from workflow Go / build (pull_request).
|
Xe
pushed a commit
that referenced
this pull request
Feb 16, 2026
# [1.30.0](v1.29.0...v1.30.0) (2026-02-16) ### Bug Fixes * **falin:** resolve npm ci dependency conflict ([#835](#835)) ([683bff8](683bff8)) * **mi:** use blog post summary in Bluesky embed description ([#848](#848)) ([7491810](7491810)) * **nguh:** return error for unsupported tokens ([d1a50e7](d1a50e7)) * **skills/xe-writing-style:** update details about successive paragraph starting letter rule ([5808b2b](5808b2b)) * **skills/xe-writing-style:** wumbofy this with Opus ([cea6609](cea6609)) * **useragent:** use filepath.Base for os.Args[0] in GenUserAgent ([#830](#830)) ([3ef21d9](3ef21d9)) * **web:** replace deprecated io/ioutil with io ([#829](#829)) ([fee5e4f](fee5e4f)) ### Features * **cmd/x:** add ai-add-provider and ai-list-models subcommands ([#850](#850)) ([bba7f41](bba7f41)) * **python:** accept io/fs.FS as root filesystem parameter ([#813](#813)) ([87b97e8](87b97e8)) * **reviewbot:** add Python interpreter with repo filesystem ([#814](#814)) ([b40ff1c](b40ff1c)) * **sakurajima:** add HTTP request timeouts to prevent hanging connections ([#837](#837)) ([d50a792](d50a792)) * **sakurajima:** add request size limits to prevent DoS attacks ([#838](#838)) ([f207855](f207855)) * **sakurajima:** add request size limits to prevent DoS attacks ([#839](#839)) ([80dd84a](80dd84a)) * **sakurajima:** production readiness fixes and enhancements ([#834](#834)) ([4368e6f](4368e6f)) * **sapientwindex:** add state to prevent double-posts ([#825](#825)) ([6ba9223](6ba9223)) * **skills:** add experimental Xe writing style skill ([baed3bd](baed3bd)) * **skills:** add Go table-driven tests skill ([#817](#817)) ([a2e35ea](a2e35ea)) * **store:** add filesystem backends (DirectFile, JSONMutexDB, CAS) ([#824](#824)) ([4f694cf](4f694cf)) * **totpgen:** add TOTP code generator command ([#833](#833)) ([d0a556d](d0a556d)) ### BREAKING CHANGES * **python:** llm/codeinterpreter/python.Run() now takes fs.FS as first parameter Assisted-by: GLM 4.6 via Claude Code Reviewbot-request: yes Signed-off-by: Xe Iaso <me@xeiaso.net> Signed-off-by: Mimi Yasomi <mimi@techaro.lol>
Owner
Author
|
🎉 This PR is included in version 1.30.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
storepackage with a genericInterfacefor key-value storage operationsChanges
storepackage with:store.go- Core Interface, Closer, and helpersdirectfile.go- Direct key→file mapping backendjsonmutex.go- JSON-based index backendcas.go- Content-addressable storage backends3api.go)Backend Details
DirectFile
JSONMutexDB
CAS
Test plan
Assisted-by: GLM 4.7 via Claude Code
Reviewbot-request: yes
Signed-off-by: Xe Iaso xe@tigrisdata.com