feat(server): the server keeps its sequences' projects, pushed and pulled like a PC's archive

Owner review 2, phase 5b (R8): a server is a project home. A workspace can
list a sequence's projects, make, rename and delete them, read their
versions and push new ones through /api/v1/sequences/{sid}/projects. The
endpoints run on the archive's ProjectService exactly as a desktop's archive
does (sidecars first, then the index, under the sequence's lease), so no
version is stored apart and a desktop sharing the archive sees the same
projects.

- Protocol: project, version, create, rename, version page, push answer
  (outcome, stored version, head, plus code and message on 409/422) and
  home frames DTOs, the projectChanged event, the "projects" capability and
  the ChronosClient calls; a push returns its outcome without throwing on
  409 or 422. ProjectWire maps them to and from the model for both sides.
- Server: Read lists and reads, Edit makes, renames and pushes, Delete (the
  sequence's owner, the project's maker or an admin) deletes; refusals with
  stable codes, 503 while the sequence is busy, offline or moved; the
  pushing account becomes the version's author; creations, renames and
  deletions audited, pushes logged.
- ProjectService tells the host what each call changed, compared under the
  lease, so projectChanged also follows Main's external versions; a Main
  version mirrored into the settings sends sequenceChanged too, for older
  clients. ProjectCatchUp takes settings a PATCH, an analysis or a
  conversion wrote into Main at once, for sequences that have a Main.
- Renders of a project version: POST /jobs checks the project and version
  against the sequence and pins a project alone to its head; render nodes
  get the version's settings placed on the frames they claim; the render
  records the project and version.
- Admin panel: the sequence page lists its projects (Main marked, head,
  last change, versions on demand) with Rename and Delete for the others,
  live on projectChanged. It edits no settings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Alby96andClaude Opus 5.5 committed 2026-11-04 11:15:19 +01:00
1 parent 917cddde41
commit e2ecc409a3
30 files changed
+2261 -35

No files matched your search

@@ -62,6 +62,15 @@ public sealed record ArchiveServiceOptions
/// </summary>
public Func<Guid, string, CancellationToken, Task>? SequenceChanged { get; init; }
/// <summary>
/// Told after a call of <see cref="Projects.ProjectService"/> changed a sequence's projects (owner review 2, R8): a project
/// made, renamed or deleted, a new head (a push, settings another path wrote taken as Main's external version, a merge, the
/// versions another program sharing the archive wrote found in the sidecars), and whether the call wrote Main's head into
/// the sequence's settings. Told once per call, after the sequence's lease is let go. A server tells its connected clients
/// (BRIEF §14.3); a failure is logged and never fails the call.
/// </summary>
public Func<Projects.ProjectChangeSet, CancellationToken, Task>? ProjectsChanged { get; init; }
/// <summary>
/// The free bytes a write under a folder of an archive (its root, its staging folder) may count on, as the host counts
/// them: a server takes the tighter of its space volume (owner review 2, R2) and the folder's own volume, the desktop asks