Repository navigation
feat(jsonlstore): support read-only access to existing stores - #2031
Merged
Merged
Conversation
Relates to #2027 Co-authored-by: Mecatl <[email protected]>
This branch was successfully deployed
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
jsonlstore.OpenReaderand a separate read-onlyReaderfor discovery, snapshots and usage, prepared-catalog metadata pagination, lineage, and event replay/follow.Relates to #2027.
Scope and limitations
JSONL adapter only: no server endpoints, UI, Redis, dependencies, storage-format migration, or engine API changes. The operator explicitly waived the separate acceptance-plan spine in this conversation after it was recommended.
Metadata pagination requires a prepared, current catalog at the same canonical path. A concurrent save invalidates it until its writable owner refreshes it; readers report unavailability rather than rebuilding or returning an empty inventory. Reader metadata cursors are returned to Reader, not Store. Missing synchronization files fail explicitly. The owning guide documents source preparation and limitations; the adapter changelog classifies the public API addition as Added.
Documentation reader need: inspect an existing store without write access. Owner:
user-docs/building/extension-points/session-store.md.Verification
Candidate base:
6473fa34100cee15353c29c0cbd72c580d5c3069.Passed:
task test(all modules)go test -race ./adapters/jsonlstore -run '^TestOpenReader' -count=1go test -race ./internal/app -run '^TestJSONLReaderPersistenceRelay$' -count=1task docstask site:buildgo run ./cmd/mecademo(tool call, permission ask/approval, result)git diff --checkWhy draft
task test:racefails inTestJSONLStoreLineageConformance:jsonlstore: lineage partition is incomplete. The identical full-suite failure was reproduced on pristine HEAD. This change does not alter the writer's lock-free lineage-read contract to hide it.task linttimed out after 600 seconds duringintegration/microvm. Earlier module checks, including root and adapters, reported zero issues. Separate scoped JSONL lint reports three constructor G703 findings also reproduced on baseline.The OS-denied-write tests ran as the current unprivileged process and probe create, existing-file write/truncate, rename and unlink denial. The privileged subprocess drops DAC bypass capabilities with
setpriv; that privileged branch was not separately exercised here. This is not a read-only-mount proof.Local detailed logs and baseline evidence are retained in
.scratch/issue-2027/results.mdinside the worktree. Aggregate gates and independent review must be resolved before marking ready. Do not merge as-is.