feat: bootstrap durable server store

This commit is contained in:
2026-08-31 09:11:58 +00:00
parent 392129c253
commit 8a88a72e62
13 changed files with 822 additions and 12 deletions
+1
View File
@@ -12,3 +12,4 @@ All versions are exact in `go.mod`, generated code, or the toolchain image.
| google/uuid 1.6.0 | Parse canonical UUIDs and verify RFC variant/version bits | Stable maintained package; RVBox owns the monotonic UUIDv7 generator so clock and ordering behavior remain directly testable. |
| go-toml/v2 2.3.1 | Strict configuration decoding | Last maintained release line before TOML 1.1 parsing was enabled; RVBox v1 intentionally accepts TOML 1.0 only. |
| klauspost/compress 1.19.0 | Zstandard command-output compression | Maintained pure-Go codec with decoder memory controls; RVBox additionally limits streamed decoded output before allocation. |
| modernc.org/sqlite 1.57.0 | Durable server/client metadata | Maintained CGO-free SQLite driver with Linux/Windows support and defensive-mode DSN support; its exact generated-code-matched libc version is pinned by `go.mod`. |
+15 -4
View File
@@ -15,9 +15,10 @@ Run focused unit tests with:
scripts/test-unit --package ./internal/domain --run UUIDv7 --race
```
The integration harness currently provides the Phase 0 `sample` suite. It
proves run isolation and the durable lifecycle without starting an RVBox
service that has not been implemented yet:
The integration harness provides the Phase 0 `sample` suite and the incremental
Phase 2 `store` suite. The latter uses a real temporary SQLite database in WAL
mode and a real segment/audit filesystem; it does not mock the persistence
boundary:
```sh
scripts/test-env doctor
@@ -29,8 +30,19 @@ scripts/test-env reuse --run-id my-sample
scripts/test-integration --suite sample --run-id my-sample --resume
scripts/test-env reset --run-id my-sample
scripts/test-env purge --run-id my-sample
scripts/test-integration --suite store --run-id store-smoke
scripts/test-env logs --run-id store-smoke
scripts/test-env collect --run-id store-smoke
scripts/test-env reset --run-id store-smoke
scripts/test-env purge --run-id store-smoke
```
Suite output is capped at 1 MiB and stored as `artifacts/suite.log`. A failed
run remains inspectable and can be moved back to `ready` with `recover`, then
resumed with the same run ID and deterministic shuffle seed. Test-run cleanup
never removes the shared Go module or build-cache volumes.
Each run owns only `.test-runs/<run-id>` and resources explicitly recorded in
that run's versioned manifest. The journal is append-only and fsynced. `purge`
validates the run ID and manifest identity, refuses symlink targets or manifests
@@ -43,4 +55,3 @@ cleanup.
test reference against source. Native Windows integration/E2E entries remain
explicitly blocked until the resettable Windows host is available; Wine or a
protocol stub is not treated as equivalent coverage.