Repository navigation
Description
Context
Phase 1 (#147-#149-#151) shipped in eb2bf1c: BowireUserContext.GetWorkspacePath(workspaceId, storageRoot?, relative) resolver, bowire workspace init <path> CLI, per-entity layout + .gitignore template with the secret-separation convention. Workbench runtime still routes through ~/.bowire/workspaces/<id>/; this issue tracks the actual swap to the git-backed storage.
Architecture — separate optional NuGet package
The runtime side of the git-backed workspace ships as a dedicated NuGet package, NOT in core Kuestenlogik.Bowire. Embedded hosts MUST be able to opt out: file watchers, per-entity reader/writers, lockfile machinery, and secret-overlay merging are real dependencies that don't belong in every ASP.NET app that mounts Bowire.
Package: Kuestenlogik.Bowire.Workspace.Git
The Workspace.<backend> namespace leaves room for future storage backends (Workspace.S3, Workspace.Sql, …) under the same shape.
Contents:
- Per-entity file reader/writer (replaces the bundle store when storageRoot is set).
FileSystemWatcher+ debounced SSE producer on/api/workspace/events.- Workspace lockfile (
.bowire.lock) machinery for concurrent-writer guard. - Secret-overlay merge (
<env>.json+<env>.secrets.json). - Migration helper (legacy bundle → per-entity layout, surfaced as the CLI's
migrate-format). IBowireExtension-style registration so the workbench discovers it when present and falls back to the legacy store cleanly when it isn't.
Core Kuestenlogik.Bowire stays unchanged: the GetWorkspacePath seam is enough for the extension to plug in; without the package referenced, the seam returns the legacy per-user path and no FS-watch / lockfile / secret-merge runs.
Standalone Kuestenlogik.Bowire.Tool references the package so the CLI ships with the git-workspace runtime bundled. Embedded hosts add the package explicitly when they want the surface.
Phase 2 acceptance
- Package scaffolding —
src/Kuestenlogik.Bowire.Workspace.Git/with the.csproj,IBowireExtension-style registration, MSBuild plumbing to publish a NuGet, and a smoke test that the package loads when referenced + no-ops when not. - Git-backed workspace storage — composes with #144 storage modes + #58 #147 —
workspace.storageRootfield surfaced in the Workspaces rail settings; setting it routes every per-workspace read/write through the new resolver. Backend endpoints (/api/recordings,/api/collections,/api/workspace) accept?storageRoot=…next to?workspaceId=…. - Per-entity file storage format for git-backed workspaces (envs / collections / scripts) #148 — Per-entity file reader/writer for environments, collections (incl. per-request
.req.jsonfiles), recordings, scripts, flows. Migration path from the existing bundle store:bowire workspace migrate-formatproduces the per-entity layout from a legacy folder; the bundle is renamed.legacyfor the operator to rm. - Workspace CLI — bowire workspace init / export / import / migrate-format #149 —
bowire workspace export [--from <wsId>] <path>+bowire workspace import <path>. Round-trips the workspace state without touching~/.bowire/; useful in CI / scripted setup. - Filesystem-watch + reconcile UI for externally-edited workspace files #150 —
FileSystemWatcheron the active workspace'sstorageRootdebounced to 300 ms; emits SSE events on/api/workspace/events(file-changed/file-created/file-deleted). Workbench subscribes and surfaces a "files changed externally — reload?" toast. - Secret-file separation + workspace lock file for safe team-shared git workspaces #151 — Reading
<env>.jsonmerges<env>.secrets.jsonoverlay (when present) at resolve time so{{API_KEY}}works from either file. Workspace lockfile (.bowire.lock) prevents concurrent writers (workbench +bowire runin the same workspace root); each writer takes the lock for the duration of a transaction, second writer surfaces a friendly "another process is editing this workspace" hint instead of corrupting state. - Embedded-mode regression test — adding
Kuestenlogik.Bowireto a stock ASP.NET app without the package must not pullSystem.IO.FileSystemWatcher-class deps and must not start any background watcher.
Composes with
- Workspace: complete the Git-native story (.bww file) #58 / Workspace .bww Phase 2 — UI wiring + plugin-pin check + scope split #193 (.bww bundle format) — the
.bwwimport path should accept a per-entity workspace too, so a team can hand someone a single file OR point them at a checked-out workspace folder.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
docs(workspace): mandate separate optional NuGet for the Phase 2 runtime
[-]Git-backed workspaces Phase 2 — runtime wiring, FS-watch, secret merge, lockfile[/-][+]Git-backed workspaces Phase 2 — Kuestenlogik.Bowire.Workspace.Git runtime + FS-watch + secret merge[/+]refactor(packages): rename Extension.Telemetry -> Telemetry; plan Wor…
feat(workbench): #212 Phase 0 — workspace.storage as the single stora…
feat(workspace): #196 Phase 2.1 — Kuestenlogik.Bowire.Workspace.Git s…
feat(workspace): #196 Phase 2.3 — add storageRoot to workspace model
feat(workspace): #196 Phase 2.3 — surface Storage root field in works…
feat(workspace): #196 Phase 2.3 — thread storageRoot through recordin…
1 remaining item
docs(roadmap): mark #196 Phase 2.3 shipped — workspace.storageRoot fi…
feat(workspace): plugin pin-check banner on workspace open (#193 item 2)
feat(workspace-git): FileSystemWatcher fanout + SSE producer (#196 Ph…
feat(workspace-git): workbench reload toast on FS-watch events (#196 …
feat(workspace-git): secret-overlay merge + lockfile (#196 Phase 2.5)
thomas-stegemann commentedon Jun 16, 2026
All seven acceptance items shipped across five phases:
Embedded-mode regression test landed alongside Phase 2.4 in WorkspaceGitEventsEndpointTests — proves the endpoint surfaces 501 + 'AddBowireGitWorkspace not called' hint when the runtime is not wired, so stock embedded ASP.NET hosts don't get a silent FileSystemWatcher leak.
Closes #196.