From 817956e7191dfef51781567ecc117b4375d4220c Mon Sep 17 00:00:00 2001 From: Alberto Balbo Date: Sun, 15 Nov 2026 15:24:55 +0100 Subject: [PATCH] fix: wire the owner review 5 parcels together; docs The six parcels of owner review 5 merged into or5-v1.1 need a few joins that no single parcel owned: - The workspace copy and send jobs compare a project's home server through WorkspaceJobOptions.SameServer, so a job queued under a server's 1.0 address still runs once its home is re-keyed to the server id (plan step S3), with a test against a real server. - The sample data gives its running and paused jobs a progress detail (SampleJobDetails), so the captures show the status line. - The Windows service strings (Server.Service.*) went with the service hosting; they are removed line by line from all 38 cultures. - The VS Code launch and build task start Chronos.Server.Host, now that Chronos.Server is a library. Docs: CHANGELOG [Unreleased], DECISIONS rows, BRIEF amendments and the section 24 rows for R1-R4, ARCHITECTURE, the deploy guides (Chronos Server in Docker only; on Windows Chronos Desktop shares its library), both READMEs and STATUS (owner review 5 in progress for v1.1.0). Refs #64 #65 #66 #67 Co-Authored-By: Claude Opus 5.5 --- .vscode/launch.json | 4 +- .vscode/tasks.json | 4 +- README.md | 25 +- deploy/releases-repo/README.md | 59 ++--- docs/ARCHITECTURE.md | 48 ++-- docs/BRIEF.md | 219 ++++++++++++++++-- docs/CHANGELOG.md | 107 +++++++++ docs/DECISIONS.md | 84 +++++++ docs/STATUS.md | 19 +- docs/deploy/README.md | 13 +- docs/deploy/desktop.md | 80 ++++--- docs/deploy/docker.md | 7 +- i18n/ar/Server.ar.resx | 3 - i18n/bg/Server.bg.resx | 3 - i18n/cs/Server.cs.resx | 3 - i18n/da/Server.da.resx | 3 - i18n/de/Server.de.resx | 3 - i18n/el/Server.el.resx | 3 - i18n/en/Server.resx | 3 - i18n/es/Server.es.resx | 3 - i18n/et/Server.et.resx | 3 - i18n/fi/Server.fi.resx | 3 - i18n/fr/Server.fr.resx | 3 - i18n/he/Server.he.resx | 3 - i18n/hi/Server.hi.resx | 3 - i18n/hr/Server.hr.resx | 3 - i18n/hu/Server.hu.resx | 3 - i18n/id/Server.id.resx | 3 - i18n/it/Server.it.resx | 3 - i18n/ja/Server.ja.resx | 3 - i18n/ko/Server.ko.resx | 3 - i18n/lt/Server.lt.resx | 3 - i18n/lv/Server.lv.resx | 3 - i18n/ms/Server.ms.resx | 3 - i18n/nb/Server.nb.resx | 3 - i18n/nl/Server.nl.resx | 3 - i18n/pl/Server.pl.resx | 3 - i18n/pt-BR/Server.pt-BR.resx | 3 - i18n/pt-PT/Server.pt-PT.resx | 3 - i18n/ro/Server.ro.resx | 3 - i18n/ru/Server.ru.resx | 3 - i18n/sk/Server.sk.resx | 3 - i18n/sl/Server.sl.resx | 3 - i18n/sv/Server.sv.resx | 3 - i18n/th/Server.th.resx | 3 - i18n/tr/Server.tr.resx | 3 - i18n/uk/Server.uk.resx | 3 - i18n/vi/Server.vi.resx | 3 - i18n/zh-Hans/Server.zh-Hans.resx | 3 - i18n/zh-Hant/Server.zh-Hant.resx | 3 - src/Chronos.App/DesignTime/SampleData.cs | 10 +- .../Workspaces/WorkspaceCopyJobHandler.cs | 2 +- .../Workspaces/WorkspaceSendJobHandler.cs | 2 +- .../Workspaces/ServerWorkspaceTests.cs | 31 ++- 54 files changed, 578 insertions(+), 250 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index 85572196..7b06b910 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -31,14 +31,14 @@ } }, { - // SQLite, as on any Windows server, with the data and the archive in out/debug/server instead of + // SQLite, as Chronos.Server.Host defaults to on Windows, with the data and the archive in out/debug/server instead of // %ProgramData%\Chronos Server and C:\ChronosArchive. The first administrator's temporary password is in // out/debug/server/data/initial-admin-password.txt. "name": "Chronos Server", "type": "coreclr", "request": "launch", "preLaunchTask": "build: Chronos Server", - "program": "${workspaceFolder}/src/Chronos.Server/bin/Debug/net10.0/Chronos.Server.exe", + "program": "${workspaceFolder}/src/Chronos.Server.Host/bin/Debug/net10.0/Chronos.Server.Host.exe", "cwd": "${workspaceFolder}", "env": { "CHRONOS_DATA_PATH": "${workspaceFolder}\\out\\debug\\server\\data", diff --git a/.vscode/tasks.json b/.vscode/tasks.json index b6e51484..f85d5675 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -69,12 +69,12 @@ }, { "label": "build: Chronos Server", - "detail": "src/Chronos.Server, Debug", + "detail": "src/Chronos.Server.Host, Debug", "type": "process", "command": "dotnet", "args": [ "build", - "${workspaceFolder}/src/Chronos.Server/Chronos.Server.csproj", + "${workspaceFolder}/src/Chronos.Server.Host/Chronos.Server.Host.csproj", "-c", "Debug", "-tl:off", diff --git a/README.md b/README.md index c00d571e..c93e6e88 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Chronos (development repository) -Time-lapse ecosystem: **Chronos** (Windows desktop client), **Chronos Server** (Linux/Docker and Windows) and -**Chronos Uploader** (Windows), sharing one C#/.NET 10 engine with zero third-party packages. This repository is +Time-lapse ecosystem: **Chronos Desktop** (Windows desktop client, which can also share its library on the LAN), +**Chronos Server** (Linux/Docker) and **Chronos Uploader** (Windows), sharing one C#/.NET 10 engine with zero third-party packages. This repository is `BalboSoft/Chronos` on the owner's Gitea (); users get the releases, the server image and the Unraid template from it too (see [Visibility](#visibility)). @@ -54,14 +54,15 @@ dotnet run --project src/Chronos.Tools -- fixtures Run: ```sh -dotnet run --project src/Chronos.Server # admin panel https://localhost:8443/admin +dotnet run --project src/Chronos.Server.Host # admin panel https://localhost:8443/admin src/Chronos.App/bin/Release/net10.0-windows/Chronos.exe [--capture ] src/Chronos.Uploader/bin/Release/net10.0-windows/Chronos.Uploader.exe docker compose -f deploy/docker/docker-compose.yml up -d ``` The server reads `/data/server.json` (`CHRONOS_DATA_PATH`) and `CHRONOS_*` environment variables; -`Chronos.Server --help` lists them. On Linux it needs PostgreSQL; on Windows it defaults to SQLite. +`Chronos.Server.Host --help` lists them. On Linux it needs PostgreSQL; on Windows it defaults to SQLite (development +only: users on Windows share a library from Chronos Desktop, Settings › Server › *Share this library*). ### Debug in VS Code (Windows) @@ -83,9 +84,9 @@ Open the repository folder with the C# extension (`.vscode/extensions.json` reco - Quit an installed Chronos or Uploader first: a second copy hands over to it and ends. Debugging the Uploader points an existing *Start with Windows* entry at the Debug build. Closing the Uploader's window keeps it in the tray (the default): end its session with *Stop*. -- Stop the Docker stack or an installed Chronos Server before *Chronos Server*, which needs the same ports. The browser - warns about the server's self-signed certificate; sign in as `admin` with the temporary password in - `out/debug/server/data/initial-admin-password.txt`. +- Stop the Docker stack, a Chronos Server 1.0 or a Chronos that shares its library before *Chronos Server*, which + needs the same ports. The browser warns about the server's self-signed certificate; sign in as `admin` with the + temporary password in `out/debug/server/data/initial-admin-password.txt`. - Chronos, the Uploader and Setup log to files (`%LOCALAPPDATA%\Chronos\logs`, `%TEMP%\Chronos Setup`); the server logs to the Debug Console. Windows Firewall asks about Chronos, the Uploader and the server at their first start. - VS Code passes the drive letter in lower case: the first build after one made with an upper-case drive letter @@ -141,11 +142,11 @@ installed copy of either. - validates the tag (SemVer 2.0 without build metadata: no leading zeros, no empty identifiers), builds with `ChronosVersion` from the tag and `ChronosReleasesUrl` (the repository the release goes to), runs the package guard, the i18n check and the Core, Data, Server and Tools tests; - - cross-compiles the self-contained single-file win-x64 programs (Chronos, Uploader and Setup with ReadyToRun; - Server), checks them with `Chronos.Tools pe-check` (GUI subsystem, icon, version, PerMonitorV2 manifest), signs - them with osslsigncode when the signing secrets exist, packs `Chronos-Setup-.exe` (components Chronos, - Uploader, Server) and `Chronos-Uploader-Setup-.exe` (`Chronos.Tools pack-installer`), signs the setups, zips - `Chronos-Server-win-x64-.zip` and `Chronos-win-x64-portable-.zip` (with `portable.txt`); + - cross-compiles the self-contained single-file win-x64 programs (Chronos, Uploader and Setup with ReadyToRun), + checks them with `Chronos.Tools pe-check` (GUI subsystem, icon, version, PerMonitorV2 manifest), signs them with + osslsigncode when the signing secrets exist, packs the one `Chronos-Setup-.exe` (components Chronos Desktop and + Chronos Uploader; `Chronos.Tools pack-installer`), signs it, zips `Chronos-win-x64-portable-.zip` (with + `portable.txt`) and fails if an Uploader-only setup or a Windows server zip appears; - writes release notes from the Conventional Commits since the previous tag (`Chronos.Tools changelog`); a stable tag starts from the previous stable tag, so its notes include what its release candidates brought; - computes `SHA256SUMS` and publishes the Gitea release with `Chronos.Tools gitea-release`: a draft first, every diff --git a/deploy/releases-repo/README.md b/deploy/releases-repo/README.md index efd93159..5ee93043 100644 --- a/deploy/releases-repo/README.md +++ b/deploy/releases-repo/README.md @@ -12,9 +12,9 @@ for community review. Development happens elsewhere; please use the issues here | Program | Runs on | What it does | |---|---|---| -| **Chronos** | Windows 10 21H2+ / 11, x64 | Desktop client: card import with hash verification, archive, analysis advisor, sequence editor, rendering with GPU encoders (H.264, HEVC, AV1) | -| **Chronos Uploader** | Windows 10 21H2+ / 11, x64 | Small tray program that uploads photos, folders, cards and watch folders to a Chronos Server | -| **Chronos Server** | Docker (linux/amd64), Unraid, Windows | Shared archive, users, resumable uploads, sync, background jobs, render delegation to GPU-equipped PCs, web admin panel | +| **Chronos Desktop** | Windows 10 21H2+ / 11, x64 | Desktop client: card import with hash verification, archive, analysis advisor, sequence editor, rendering with GPU encoders (H.264, HEVC, AV1); can share its library on the local network | +| **Chronos Uploader** | Windows 10 21H2+ / 11, x64 | Small tray program that uploads photos, folders, cards and watch folders to a Chronos Server or a shared library | +| **Chronos Server** | Docker (linux/amd64), Unraid | Shared archive, users, resumable uploads, sync, background jobs, render delegation to GPU-equipped PCs, web admin panel | | | | |---|---| @@ -31,27 +31,30 @@ for community review. Development happens elsewhere; please use the issues here Extensions* and *HEVC Video Extensions*. - **Hardware encoding:** any GPU whose driver provides Media Foundation encoders (NVIDIA, AMD, Intel). Without one, Chronos encodes H.264 in software and its own formats (AVI, GIF, APNG, image sequences). -- **Server:** Docker 20.10+ (or Unraid 6.12+) and PostgreSQL 16 or 17; or Windows 10/11/Server 2019+ x64. +- **Server:** Docker 20.10+ (or Unraid 6.12+) and PostgreSQL 16 or 17. On Windows, Chronos Desktop shares its own + library instead (below). ## Install, upgrade, uninstall (Windows) -1. Download `Chronos-Setup-.exe` (Chronos, Uploader and, optionally, Server) or - `Chronos-Uploader-Setup-.exe` from the [latest release](https://gitea.encke-hake.ts.net/BalboSoft/Chronos/releases/latest). +1. Download `Chronos-Setup-.exe`, the one setup for Chronos Desktop and Chronos Uploader, from the + [latest release](https://gitea.encke-hake.ts.net/BalboSoft/Chronos/releases/latest). 2. Check the download (optional, recommended): in PowerShell run `Get-FileHash .\Chronos-Setup-.exe -Algorithm SHA256` and compare the value with the line for that file in `SHA256SUMS` of the same release. 3. Run the setup. It installs for the current user into `%LOCALAPPDATA%\Programs\Chronos` without administrator - rights; choose *All users* to install into `Program Files` (Windows asks for permission). The *Server* component - runs as a Windows service, so choosing it installs for all users, in a folder inside `Program Files`. + rights; choose *All users* to install into `Program Files` (Windows asks for permission). Tick Chronos Desktop, + Chronos Uploader or both; the *Changes* row lists what an update will do before it runs. Run it again later to add + or remove a program; with nothing ticked it uninstalls. A Chronos Uploader 1.0 installed on its own is replaced by + it, keeping its settings; a Chronos Server 1.0 for Windows is kept, marked *No longer offered*, until you untick it. -- **Upgrade:** Chronos checks this repository at start (you can turn this off in Settings › Updates) and shows a notice - when a new version exists. *Download* fetches the setup, verifies it against `SHA256SUMS` and shows it in Explorer; +- **Upgrade:** Chronos Desktop and Chronos Uploader check this repository at start (you can turn this off in + Settings › Updates) and show a notice when a new version exists. *Download* fetches the setup, verifies it against `SHA256SUMS` and shows it in Explorer; run it to upgrade in place. Your archive, settings and index are kept. - **Uninstall:** Windows Settings › Apps › Installed apps › Chronos › Uninstall. Your photos and archive are never touched; the program data in `%LOCALAPPDATA%\Chronos` is removed only if you tick the option to do so, and only the - part no other installed Chronos program still uses. A Chronos Server service of that folder is stopped and removed. + part no other installed Chronos program still uses. A Chronos Server 1.0 service of that folder is stopped and removed. - **Silent install** (IT deployment): `Chronos-Setup-.exe /S [/DIR="D:\Apps\Chronos"] [/ALLUSERS] - [/COMPONENTS=Chronos,Uploader,Server] [/NODESKTOP] [/NOSTARTMENU] [/LANG=it]`. Silent uninstall: + [/COMPONENTS=Desktop,Uploader] [/NODESKTOP] [/NOSTARTMENU] [/LANG=it]`. Silent uninstall: `"%LOCALAPPDATA%\Programs\Chronos\Uninstall Chronos.exe" /uninstall /S`. - **Portable:** `Chronos-win-x64-portable-.zip` keeps its data in a `data` folder next to `Chronos.exe` (because of the `portable.txt` file). Do not unpack it into a OneDrive or Dropbox folder. @@ -152,31 +155,17 @@ container's (8080 and 8443), not the ones clients use. The template file is [`unraid/chronos.xml`](unraid/chronos.xml). -## Chronos Server on Windows +## Share a library from Chronos Desktop -Choose the *Server* component in the setup, or unpack `Chronos-Server-win-x64-.zip`. It uses SQLite in -`C:\ProgramData\Chronos Server` by default, or PostgreSQL with `CHRONOS_DB=postgres` and the `CHRONOS_DB_*` variables. -The data folder is readable only by the server's account, SYSTEM and Administrators; without `CHRONOS_ADMIN_PASSWORD` -the first start writes a temporary admin password to `initial-admin-password.txt` there (open it from an -administrator prompt). Everything in it must belong to those accounts and nothing in it may be a link: otherwise the -server does not start and names the file to check (in the console, or for the service in Event Viewer › Windows Logs › -Application, source `ChronosServer`). A new archive folder (default `C:\ChronosArchive`) can be changed only by those -accounts and read by other users; when other users can change an existing archive, the log says so. +There is no separate Chronos Server for Windows any more. In Chronos Desktop turn on Settings › Server › *Share this +library*: while Chronos runs it serves this PC's archive to other PCs, Chronos Uploader and render nodes with the same +engine as the Docker image, on HTTPS 8443 and HTTP 8080 by default. Server › This library shows the addresses and the +certificate fingerprint to give to clients (each with *Copy*), the first admin's temporary password, the clients +connected and *Admin panel*. Allow Chronos through the Windows firewall on private networks when Windows asks. -Run `Chronos.Server.exe` in a console, or install it as a Windows service from an administrator prompt with -`Chronos.Server.exe --install-service` (remove it with `--uninstall-service`). The service runs as LocalSystem, so it -registers only from a copy inside `Program Files` that only administrators can change: install for *All users*, or -unpack the zip into a folder under `Program Files`. A console run that was not elevated creates the data folder as the -account that ran it, and the service then refuses the folder and names that account (`… belongs to PC\name …`). -Either delete the folder (with SQLite this also deletes the server's database and its accounts), or give the folder -and everything in it to Administrators and take that account's access to it away, from a Command Prompt run as -administrator: `takeown /F "C:\ProgramData\Chronos Server" /A /R`, then -`icacls "C:\ProgramData\Chronos Server" /remove:g "PC\name" /T`, with the account the refusal names in place of -`PC\name` (`dir /q C:\ProgramData` also shows it, as the folder's owner, until `takeown` runs). When you ran the -console yourself and the prompt runs as you, that account is `"%USERDOMAIN%\%USERNAME%"`. Then start the service. No -other account gains access at any step, and afterwards only SYSTEM and Administrators have it, to the TLS key and -`initial-admin-password.txt` too. Do not reset the folder's permissions (`icacls /reset`): everything in it would then -inherit those of `C:\ProgramData`, which let every user read it. +Moving from Chronos Server 1.0 for Windows: share the same archive folder from Chronos Desktop, or run the Docker image +with it; then untick Chronos Server in the setup, which removes it and its service. Its data in +`C:\ProgramData\Chronos Server` is kept. ## Translations diff --git a/docs/ARCHITECTURE.md b/docs/ARCHITECTURE.md index 046a2c8e..2417dd9d 100644 --- a/docs/ARCHITECTURE.md +++ b/docs/ARCHITECTURE.md @@ -11,7 +11,8 @@ Companion to `docs/BRIEF.md` (scope, behaviour) and `docs/ui/DESIGN.md` (looks). | `src/Chronos.Core.Windows` | net10.0-windows | WIC decoders and codec inventory, Media Foundation encoders, DXGI adapters, removable devices and volume free space, DPAPI, shell launcher, window chrome, power (P/Invoke/COM only) | | `src/Chronos.Data` | net10.0 | `IDatabase`, SQLite binding, PostgreSQL wire client, migrations, repositories, the job engine, the archive engine (`Archiving`), the analysis/render engine (`Processing`) and the client sync engine (`Sync`) | | `src/Chronos.Protocol` | net10.0 | API v1 DTOs, source-generated JSON context, typed `ChronosClient` with certificate pinning and bandwidth limiting, `ChronosAddress` (how both clients read a typed server address) | -| `src/Chronos.Server` | net10.0 (Web SDK) | ASP.NET Core minimal API, auth, uploads, sync, jobs, render nodes, events, embedded admin panel, Windows service host | +| `src/Chronos.Server` | net10.0 (Web SDK, `OutputType` Library) | ASP.NET Core minimal API, auth, uploads, sync, jobs, render nodes, events, embedded admin panel; hosted by `Chronos.Server.Host` or in-process by Chronos Desktop (owner review 5, #67); no Windows service host | +| `src/Chronos.Server.Host` | net10.0 exe | The console program of the server (`Program.cs`): the Docker image runs `Chronos.Server.Host.dll`, developers `dotnet run --project src/Chronos.Server.Host` | | `src/Chronos.Ui` | net10.0-windows (WPF) | Theme (DESIGN tokens), icons, standard and custom controls, visuals (charts, filmstrip, preview, curve editor, virtualizing grid), `Loc` markup extension, MVVM helpers, notification-area icon | | `src/Chronos.App` | WPF exe `Chronos.exe` | Desktop client | | `src/Chronos.Uploader` | WPF exe | Uploader (tray, watch folders, resumable queue) | @@ -20,7 +21,8 @@ Companion to `docs/BRIEF.md` (scope, behaviour) and `docs/ui/DESIGN.md` (looks). | `tests/Chronos.Testing` | net10.0 | In-house test framework (`[Test]`, `[Theory]`+`[Case]`, `[Category]`, `[RequiresEnvironment]`, `[WindowsOnly]`, `[Serial]`, `Assert`, `TestContext`, JUnit) | | `tests/Chronos.*.Tests` | exe | One test program per area; `dotnet run --project tests/X -- --junit out.xml` | -Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `Server`; `Ui` ← `App`, `Uploader`, `Setup`. +Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `Server` ← `Server.Host`, `App` (the App also takes the +`Microsoft.AspNetCore.App` shared framework to share its library, owner review 5); `Ui` ← `App`, `Uploader`, `Setup`. `Core`, `Data`, `Protocol` and `Server` never reference Windows-only code (Linux CI builds and tests them). ## 2. Module map @@ -44,10 +46,11 @@ Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `S | `Import` | Card scan, session detection, import plan (photos named through `FrameNaming` with the camera and lens of their session's first photo), hash-verified copy, card eraser (re-hash before delete) | | `Conversion` | Mass conversion after import (owner review 2, R7): `ConvertOptions` (target JPEG 4:4:4 / TIFF-16 / linear DNG, the archival one, `ConvertMode` Replace or New sequence, JPEG quality and the quality that counts, the converted name: the archive's file template with the frame's `FrameNaming` context in its sequence, as filing names it, `{ext}` the target's), `FrameConverter` (`Decoders`: the conversion's chain, the managed provider first with its header probes, WIC after it, no RAW at 8 bits for a 16-bit target; native-tier decode only; `Treatment`: what Chronos reads never changes, so the colour space is carried (code values), described by a profile made for the values written (`Describe`: float values as sRGB codes, a gray curve as RGB) or refused (a DNG takes sRGB's values only); pixels that are not numbers fail as damaged; in-house encoders, Exif from the sidecar and the original via `ExifWriter`, hashed as made, written atomically, verified: read back, metadata again, decoded by the server's decoders; `ConversionException` and its `ConversionFailure`, `FailureText`: the job log's sentence by cause), `ConvertPlanner` (per sequence the frames converted and skipped with `ConvertSkip`, each file probed with the conversion's decoders whatever tier was recorded, 8 at a time; `TooLarge`: what the target holds and the server's decoders read back, without overflow; a frame another host flagged undecodable asked again where other decoders (WIC) read it; size estimates per pixel; `ConvertSequencePlan.Digest`, the photos converted with their content; `ConvertPlan` with its space and fingerprint) | | `Naming` | Folder/file templates and tokens (folder levels scans skip escaped with `_`; `ExpandText` for titles; `ExpandFile` shortens a long file name before its `.{ext}`); `FrameNaming` (the naming context and unique file name of a frame, shared by import, upload, Reorganize and conversion: the sequence's camera and lens, the first frame for folders; `UniqueNames`: `_2`, `_3`… in linear time); `TemplateRules` (what every place a template is typed or sent refuses, the archive engine's new or changed templates included: a folder scans skip, a lost extension, names that repeat) | -| `Model` | Domain entities and enums (§5) shared by Data, Server and clients (`SequenceProject`, `ProjectVersion` and `ProjectVersionKinds`: owner review 2, R8; `Render.Sha256` and `Kind`, `RenderKind` with `Of` reading a kindless still from its codec, fps and duration, `RenderCopy`, `JobKind.VideoCopy = 24`: owner review 1, R9) | +| `Model` | Domain entities and enums (§5) shared by Data, Server and clients (`SequenceProject`, `ProjectVersion` and `ProjectVersionKinds`: owner review 2, R8; `Render.Sha256` and `Kind`, `RenderKind` with `Of` reading a kindless still from its codec, fps and duration, `RenderCopy`, `JobKind.VideoCopy = 24`: owner review 1, R9); `JobDetail` with `JobStep` and `JobPartUnit` (owner review 5, #65: append-only, stored by kebab name; the item cut to 160 characters, never inside a surrogate pair) and `Job.Detail` | | `Packaging` | TPK1 installer payload writer/reader, staged install transaction | | `Diagnostics` | `Log` (never throws: a line its sink cannot write is dropped), `FileLogSink` with `LogFileOptions` (level, daily or hourly files, numbered parts past a size, pruning by age and by the total size, never the file being written), synthetic sequences, `SecretScrubber`, `DiagnosticsArchive` (scrubbed diagnostics zip) | -| `Localization`, `IO`, `Hashing`, `Branding` | `Loc`/plural rules, `AtomicFile`, `StartupCommand` (sign-in entries of the programs, moved or removed by setup), CRC-32/SHA helpers, brand mark geometry | +| `Localization`, `IO`, `Hashing`, `Branding` | `Loc`/plural rules, `AtomicFile`, `StartupCommand` (sign-in entries of the programs, moved or removed by setup), CRC-32/SHA helpers, brand mark geometry; `IO/HomeFolders` (owner review 5, #66: home folder names `local`, `servers/`, `servers/addr-`, `IdKey`, `AddressHash`, `SafeName`, `OriginalsArchiveRoot`) | +| `Updates` | Owner review 5, #64: `UpdateCheck` (the releases feed), `UpdateDownload` (the `Chronos-Setup-*` asset, or the portable zip, verified against `SHA256SUMS`), `ProductLinks` (`ChronosReleasesUrl`); BCL only, tested on Linux | ### 2.2 Chronos.Data @@ -56,15 +59,16 @@ Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `S | `Sqlite`, `Postgres` | SQLite P/Invoke binding (winsqlite3 / libsqlite3), in-house PostgreSQL wire protocol v3 client with pool and LISTEN | | `Migrations/{sqlite,postgres}/NNNN_name.sql` | Embedded, applied in one transaction at open (`MigrationRunner`) | | `Repositories` | `ChronosDatabase` facade: archives, sequences, frames, tags, renders, jobs, cards, users, tokens, uploads, render nodes, settings, audit, schedules (`ScheduleRepository`: system rows seeded without overwriting edits and never deleted, the compare-and-set claim of a run), tombstones of removed photos (`FrameRemovalRepository`, `frame_removals`, written from the sidecar's `removed` list), `SequenceRepository.GetStampAsync` (a digest of what a Reorganize plans from in the index) and `GetConvertStampAsync` (with what a conversion plans from: its photos' count, sizes, formats, pixel sizes and the flags that decide), `JobRepository.ListPendingTargetsAsync` (the targets of pending jobs of a kind, also of those created before a time), `RenderRepository.RebaseFolderAsync` (the export paths that follow a moved folder), `ListPageAsync` (the videos library's keyset pages, filters and orders; a kindless still recognised in SQL by its image codec, fps 0 and duration 0) and `SetSha256Async` (a lazy hash); `RenderCopyRepository` (`render_copies`, migration 0010: the verified copies in a videos folder, no foreign key to `renders`); projects and their versions (`ProjectRepository`, `projects`, `project_versions`: rows derived from the projects' sidecars, a head advanced by compare-and-set, Main's last mirror); `JobRepository.ListPendingAsync` (the queued, running and paused jobs of a kind and target, full rows); `FrameRepository.CountNamedAsync` (hashed frames and a checksum of their hashes, for a home's frames stamp); `DatabaseBackups` (`VACUUM INTO` copies of an SQLite index into `backups` next to it, every copy keeping as many as the backup schedules keep (`KeptAsync`), the newest copy that seeds the `index-backup` schedule (`Newest`, `SystemSchedule.LastDone`), restore staged for the next start and carried out before the index opens, so it also recovers one that no longer opens) | -| `Jobs` | `JobEngine` (one job at a time; reviews the priority queue and makes a lower running job yield, requeued with its checkpoint; no history purge, the housekeeping schedule's clean-up does it), `JobPriorityQueue` (a level per job kind, the claim order, settings round trip), `IJobHandler`, `IJobHandlerProvider`, `JobContext` (progress, checkpoints, follow-up jobs that never interrupt their parent), `JobThroughput`/`JobEta` (rate and bounded time left), `ICancelledJobHandler` (a handler's clean-up after a cancel: `JobEngine.CancelAsync` calls it for a paused or failed job no handler runs, and waits first for a paused job's run that has not ended) | +| `Jobs` | `JobEngine` (one job at a time; reviews the priority queue and makes a lower running job yield, requeued with its checkpoint; no history purge, the housekeeping schedule's clean-up does it), `JobPriorityQueue` (a level per job kind, the claim order, settings round trip), `IJobHandler`, `IJobHandlerProvider`, `JobContext` (progress, checkpoints, follow-up jobs that never interrupt their parent), `JobThroughput`/`JobEta` (rate and bounded time left), `ICancelledJobHandler` (a handler's clean-up after a cancel: `JobEngine.CancelAsync` calls it for a paused or failed job no handler runs, and waits first for a paused job's run that has not ended). Owner review 5, #65: `JobContext.ReportAsync(done, total, JobDetail)`, `CheckpointAsync(…, detail)` and `ReportItemAsync` (item counts of the current detail with no allocation); publishing throttled to one report per `JobEngineOptions.ProgressInterval` (500 ms) per job with bypass for the first report, a step change and a completed count; `JobWire` maps the detail (`DetailJson`, `ParseDetailJson` never throws); `jobs.progress_detail` (migration 0011) | | `Scheduling` | `Scheduler` (one per host: seeds the host's system schedules, claims due runs by compare-and-set, catch-up, clock changes, create/edit/reset/delete/run now as API v1 DTOs), `ScheduleRecurrence` (the in-house `every:`/`daily:`/`weekly:`/`monthly:` form, wall-clock times across DST), `ScheduleActions` (action names, parameters, availability, the archive jobs a run queues), `IScheduleHost` and `SystemSchedule` (what the server and the desktop supply), `ScheduleOutcome`, `ScheduleMapping` (model ↔ DTO) | | `Housekeeping` | `BackupJobHandler`, `CleanupJobHandler`, `ICleanupStep` with the shared steps (`CleanupSteps`: job history, audit log, trash report that never deletes); hosts add their own steps through `ArchiveServiceOptions.CleanupSteps` | | `Archiving` | `ArchiveService` (create/adopt/open, archive settings written to `archive.json` then the index, `ArchiveSettings.CheckTemplates` and `TemplateRuleException` holding a template given anew to the template rules; `UnderLeaseAsync`: a write under a sequence's lease with its row read under it; `EditSettingsAsync`: settings an index edit writes, written to `project.json` under the lease first and put back when the index does not take them), `ArchiveIndexer` (scan, rebuild; a sequence found in another folder takes its exports' paths along; a full scan or a rebuild takes the projects' sidecars back too), `ArchiveIngest` (uploads and imports, named through `FrameNaming`; content a conversion replaced is a duplicate of the frame holding its conversion; a restore or a replacement not settled yet refuses the batch), `ImportService`, `ArchiveVerifier`, `ArchiveImages` (thumbnail and proxy passes, several photos at once through `OrderedWork`, which hands results back in frame order), `FrameTiers` (decode tier, `PreviewOnly`/`Undecodable` flags and preview size of frames, written to sidecar and index by the light analysis, deep analysis, renders and image passes), `GprCompanions` (the JPEG of each GoPro GPR, found in the index when an import kept it in another sequence), `ArchiveMaintenance` (also a conversion job's staging and journals, by the job's state; those of a job this index does not know go together, by age), `MassRenamer` (mass rename and Reorganize: the dry run reads each sidecar for a file template; each step checked under its leases before anything of it moves (where its sequences are, what is inside and at its new folder, a sidecar of a newer format, the title it was planned from when it changes it or names the folder or files after it), then the folder, with the sequences of the plan an earlier step left as they were inside it (taken along, their title and file names kept), every index row (the frame paths and render paths of the exports inside it, a file or an image-sequence folder, its own unless the export is still at the old place and another sequence's when it moved with it, follow it in one transaction; a sidecar that cannot be read or written then still has its row follow, and fails the step), then the files under the plan's journal in `journal/` (a sequence whose photos changed since, such as one still receiving them, or whose files are found changed or in use or have their new names taken keeps its file names, the renames being pinned by digest, and the step and the plan go on); the journal keeps the tally of the whole plan, and a plan its job held (paused, cancelled or failed) is left to that job, only its half-done file renames completed at an archive open, which completes any other plan an interruption left and tells each sequence changed; the file renames of a step: sidecar, a sequence whose sidecar cannot be read staying as it is with every folder around it, index (`FrameRepository.RenameFilesAsync`) and the sequence's journal), `SequenceFolders` (`Holds`: the folder the index has for a sequence is there and its sidecar names no other sequence; every writer into a sequence's folder asks it), `SequenceTrash` (delete into the archive's hidden trash with a dry run, restore; the folder moves back when the index step fails; lists sequence and photo entries; `SequenceTrash.Empty`: the emptying's dry run, fingerprint and erase, each entry checked against its fingerprint again under its lease, `TrashKept` with its `TrashKeptReason` for each entry kept; `SequenceTrash.Replaced`: where a replaced entry's conversions are, read from the archive's sidecars (in the index's or the entry's folder, in the trash, else by one `SidecarWalk` of the archive per dry run or emptying) through their replaced tombstones, a conversion deleted only on the archive's word (a tombstone, the trash, or an `ErasureRecord` in `trash/.erased/`, written when an emptying erases a deleted sequence a replaced entry still needs), `TrashEntry.ConversionDeleted` in the dry run and its fingerprint, the erase weighed under the entry's and the sequence's leases once the sequence is settled; `BusyAsync`: what running and paused jobs hold, but the job asking, from `JobRepository.ListHoldsAsync`), `FrameTrash` (photos of a sequence into `trash/photos` with a dry run, a journal that undoes an interrupted deletion whose entry stays unlisted until its sidecar is written, tombstones (a photo never hashed is hashed as it goes; one whose original is missing goes without a file or tombstone; a frame that stays and may be a twin is hashed, its hash kept), positions parked and placed back, proxies and thumbnails moved to follow their frames; `FrameTrash.Restore`: restore re-hashes each file and says why each kept photo stayed (`KeptReason`), under a journal of its own into the sequence that another writer settles only under the entry's lease, into a new sequence through the ingest when theirs is gone, each original staged inside its own entry and the record rewritten after each photo filed; a replaced entry swaps back while its converted frames are unchanged (`SwapBackAsync`); `FrameTrash.Replace`: the files of frames swapped in place, same ids and indices, the old files into one `Replaced` entry with their replacements' hashes, a copy of `analysis.json` and the job's id, the incoming files named never onto a file there, tombstones aliasing old content to new, under `.chronos/replace.pending.json` (its phase and the new names: the next writer completes it when the sidecar lists them, else undoes it; `EnsureReplaced`: the writers of a sequence's frames wait for one not settled); `ReplaceMissingAsync`: a frame missing here takes its photo back in another encoding, nothing to the trash; `FollowUps`: the passes a swap cleared), `MassConverter` (conversion's dry run: busy sequences (running and paused jobs, pending conversions), offline and unreadable ones, the space against `ArchiveServiceOptions.FreeSpace` for the archive root and its staging folder; `QueueAsync`: a confirmed plan's job queued under a process lock, its confirmed photos written first into `journal/convert-.photos` (`ConfirmedPhotos`) under the job's id, a second conversion of its sequences refused, `ConversionQueuedException`; the job, a sequence at a time: under its lease, settled, planned again and held to the confirmed photos (`Confirmed`, `Held`), pinned in `journal/convert-.pins` (`PinLog`); stage A converts into `staging/convert-/` with `OrderedWork`, the space watched before each photo, counting every photo still being written (`SpaceWatch`), each staged file appended to `journal/convert-.staged` (`StagedLog`); stage B per sequence, all or nothing: replace through `FrameTrash.ReplaceAsync` (the sequence's folder read again under its lease, as every writer does), or a new sequence through the ingest with the source's tags, rating, notes and project (a retry finishes the copy the journal names; a source another done conversion copied since is `Superseded`); `ConvertJournal` (`convert-.json`: each sequence's outcome and whether its passes were queued); each sequence replaced or made told, and its passes queued, as it completes), job handlers | | `Processing` | `ProcessingService`, `SequenceAnalyser`, `DeepReports` (a saved deep report while it still describes the frames), `SequenceRender`, `ProjectStore` (a newer format refused as `Errors.Render.NewerSettings`), `ProjectBundles` (a `.chronos` file for a sequence, and the sequence a file names), `ProcessingJobs` (`Routed`: a render job sized from its resolved preset box through `RenderSize` and given its `RequiredSettingsFormat`, read from the job's own export and never below the stored settings' format; `RequiredFormat` over a batch's presets, used by the desktop's gates; `BatchExport` carrying the playback; `Still`: a still job, `StillFrame` and `StillPhoto`, format 3), `RenderNodeClient` (registers the node's settings format), job handlers (`RenderJobHandler` hashes each single-file output and records its kind, stills included) | | `Videos` | Owner review 1, R9: `IVideoLibrary` (`ArchiveService.Videos`; the server's and the desktop's one library: list and get as `VideoItem` with state and copies, `PlanDeleteAsync` and `DeleteAsync` by fingerprint, `RestoreAsync` by trash entry, `CopiesAsync`, `CopyJob`, `FolderProblem`; `VideoQuery`, `VideoErrors` and `VideoLibraryException`, `VideoTrashNames`), `VideoLibrary` (`ProtectedFolders`: the host's folders a videos folder may not be in, the workspace on the desktop, the data folder on the server; `RecoverAsync` at open), `VideoTrash` (`.chronos/trash/videos/`: delete under the sequence's lease with a `.pending` record journal, a rename or a verified cross-volume copy, the row removed and `rendered_count` recounted, `.leftover` markers for a source a copy could not remove; restore after a re-hash under a free name, same render id; entries listed through `SequenceTrash` as `TrashKind.Videos`, titled by their sequence), `VideoCopyJobHandler` (`video-copy`, 24: free space for every render first, `.incoming-.part`, hash, rename without overwrite, `render_copies`; a server's render downloaded on the desktop; checkpoint `done:`), `VideosFolder` (validation, free space, " (2)" collision names, part-file names) | | `Projects` | `ProjectService` (`ArchiveService.Projects`: the projects of this PC's sequences as a home, under the sequence's lease and only in a folder that holds the sequence (`SequenceFolders.Holds`; otherwise `SequenceFolderMovedException`: reads answer from the index, writes are refused); reads wait 3 s for the lease, then answer from the index; a read-only archive is read without writing (an index-only Main written back once it takes writes): list, create, rename, delete (the folder into `projects/.trash` first, then the deleted record; never Main), history, head (NotFound once deleted), `StoredAsync` (a version file read back and checked), push with fast-forward / idempotent repeat / divergence / hash, portability, strict format and 64 MiB checks; each call first catches up: the sidecars into the index, Main made from the sequence's settings, settings another path wrote appended to Main as an `external` version or, with a push whose mirror was cut short, merged into one `merge` version where they win, a mirror never written over `project.json` settings it has not taken in (`MovedSharedAsync`), records behind the index healed (`HealAsync`, `UpdatedAfter`), projects the archive lost written back (`WriteBackAsync`); a push to Main mirrored into `project.json` and the settings with the settings version check), `ProjectIndexer` (the reconcile, also run by full scans and rebuilds: the projects' trash read before the live folders, so a deletion wins and the live folder's late version files move beside it; a record that cannot be read held back, never taken for a deletion; a lost record written again from the index only once its folder settled (`RecordSettle`, 2 minutes) and no trash folder holds it back (`TrashRecordGrace`, 1 day); a creation cut before its record left as it is; a version file a push left past its record adopted, a stray one moved to `versions/.stray`; `BehindAsync`, one rule for a record behind the index; `SettleMainAsync` and `SwapMainAsync`, one Main from the records, passed in one transaction), `ProjectSidecars` (record and immutable version files, the settings as a JSON string checked against their hash, `MaxVersionBytes` 64 MiB refused before writing), `ProjectMerge` (three-way merge member by member, pending frames merged photo by photo, conflicts, `Replay` of local commits on a moved head; `NewerSettingsException` rather than merge a newer format; `OneFraming`: a turn or mirror on one side and a framing edit on the other are one conflict at the orientation member), `IProjectHome` and `ArchiveProjectHome` (the home a workspace pushes to and pulls from: `HoldsAsync` reads a version back, `FramesStampAsync` says when the frames changed, an offline archive or busy lease is `HomeUnavailableException`), `ServerProjectHome` (phase 5b: a server sequence's `/projects` over `ChronosClient`; a server out of reach, an expired sign-in, a 503 lease, offline archive or `projects_unreadable`, a 409 `folder_in_use` and a server without the projects are `HomeUnavailableException`, a 404 `sequence`/`project`/`version` and a refused name `ProjectException` (a deleted project's head is 404 `project`), a 422 `too_large` the `TooLarge` outcome, other refusals keep their `ChronosApiException`; `HoldsAsync` reads the version back (`?stored=true`), `FramesStampAsync` from `…/frames/stamp`, version pages read on past a page the server ended early, a 413 the `TooLarge` outcome; its sequences name an archive id made from the server's key), `HomePhotos` (a sequence's photos as positions name them, with the encodings its Replaced tombstones join; the server's frames endpoint and render nodes build the same), what each call changed (`ProjectChangeSet` to `ArchiveServiceOptions.ProjectsChanged`, once the lease is let go: projects made, renamed, deleted or with a new head, compared before and after under the lease, and whether Main's head was written into the sequence's settings), `CatchUpAsync` (the catch-up alone, saying why it cannot run), `ProjectWire` (projects, versions, push outcomes and a home's frames to and from API v1 DTOs, for the server and a client of it) | -| `Workspaces` | `WorkspaceStore` (a folder outside the library: `workspace.json` written atomically, one folder per project, no index; a leftover folder holding only stale lease files removed on listing), `WorkspaceProject` (`project.chronos` working state, `media/` with `media.json`, `proxies/.jpg` (and `-.jpg` while a copy replaces one) and `analysis.json`, `versions/` with `.replaced` (versions set aside, pruned by age and count) and `.replaced.since`, `sync.json` for a conflict, a restore or the journal of a replay or a Save both, `exports/`, the lease `.lock.lease`; `UnreadableVersions`), `WorkspaceMedia` (`NamedAsAt`: the media learn the home's hashes and aliases), `WorkspaceSync` (checkout, open under the lease, save, commit, push, pull with replay and merge, the base in `project.chronos` as every write's commit point, `SettleAsync` finishing or undoing a cut push, replay or Save both, conflicts settled by keep mine, take server or save both only as shown, restore, status with Gone, Damaged and `MediaOutdated`, the home's frames read again only when their stamp moved; `FollowNameAsync`: the home's name and Main written into the copy at every pull and at a server's `renamed`), `WorkspaceCopyJobHandler` (`WorkspaceJobs.Copy` and `CopyFactsAsync`, registered by the desktop only: the archive only read, from a folder that holds the sequence; a workspace inside a library refused; the archive's current proxies copied, the others made in the workspace, each hash-verified, resumable from a checkpoint of its frames version and folder, free space checked against its estimate plus 512 MiB; the encodings conversions joined kept in `media.json`; the working state's positions moved by frame where frames stay, by photo where they came or went; a cancelled first copy's media cleared under the project's lease only when no other copy of the project waits or runs, through `ICancelledJobHandler` too; a project whose home is a server, `WorkspaceJobs.CopyFromServer`, phase 5b: downloaded through the desktop's session (`ISyncConnector`), never through this PC's archive, the frames of one frames version with the aliases of the server's conversions, each proxy (else the thumbnail standing in, `WorkspaceFrame.FileKind`) hashed as it arrives and checked on the disk, four at a time, the editor's current file never overwritten, resumable from the same checkpoint, a `.thumb` marker beside a thumbnail standing in until the commit, free space checked against the server's proxy sizes); phase 5c: `WorkspaceProject` gains `media/originals/-` (`OriginalName`), the ledger `exports/renders.json` (`WorkspaceRenders`, `WorkspaceRenderEntry`; `ContainedExportFile` keeps every ledger path inside `exports/`), `media.json` format 2 while it holds originals or was cleaned (`WorkspaceMedia.Cleaned`) and the project file format 3 while its media are Originals; `WorkspaceOriginals` (Proxies only's plan and apply, and `ClearOriginals`: every file of `media/originals` hashed and deleted only when the home's frames hold its SHA-256, the rest moved to the trash), `WorkspaceTrash` and `WorkspaceTrashBuilder` (`/.trash`: entries `-` filled under `.incoming--` and renamed when whole, listed with a fingerprint of every file's path, size and time, emptied only by a plan that still matches), `WorkspaceCleaner` (the clean-up of media of projects in step with their home: Clean after, Size limit, the reasons a project is kept in `WorkspaceKeep`, `UnsentRenders`), `WorkspaceMover` (survey, plan fingerprint, the journal `/.move.json` with stages Moving and Switched, rename on one volume or copy and hash-verify across volumes, resume, abandon, clear after the switch), `WorkspaceJobRoots` (internal, in `WorkspaceJobs.cs`: the folder a copy, render or send works in, the one that holds its project now, refused while a move has not switched) and the job parameters `WorkspaceRenderParameters`, `WorkspaceSendParameters`, `WorkspaceMoveParameters` in `WorkspaceJson` | -| `Sync` | `SyncService` (sync table of one server: compare, link by content through the aliases, settle conflicts, enqueue transfers), `SyncRules` (status, settings merge and differences, the proxies this PC can send, aliases followed; no I/O), `SyncTombstones` (photos either side removed are not offered back; the replaced tombstones of both sides join the encodings of one photo, union-find, each compared as the smallest SHA-256 among them, a deletion covering them all; immutable once made), `SyncPositions` (the settings' frame positions translated by photo to the frames of the copy they go to), `SyncLinkStore` (`sync_links`, `sync_state`), `SyncTransfers` and `SyncJobHandler` (resumable, hash-verified uploads and downloads as jobs; downloads commit through the archive ingest, and a frame missing here whose photo the server holds in another encoding takes that file through `FrameTrash.ReplaceMissingAsync`; job log lines from the catalog), `SyncAgent` (background comparison, server events, backoff, offline proxies; a server's `projectChanged` passed on as `ProjectChanged`, and null after a lost event stream once the stream is open again and a comparison made after that reached the server: `ISyncRemote.EventsAsync(connected, ct)`), `ProxyCache` and `RemoteSequence` (server sequences opened with proxies), `ISyncRemote` (the server calls; `ChronosSyncRemote` over `ChronosClient`) | +| `Workspaces` | `WorkspaceStore` (a folder outside the library: `workspace.json` written atomically, one folder per project, no index; a leftover folder holding only stale lease files removed on listing), `WorkspaceProject` (`project.chronos` working state, `media/` with `media.json`, `proxies/.jpg` (and `-.jpg` while a copy replaces one) and `analysis.json`, `versions/` with `.replaced` (versions set aside, pruned by age and count) and `.replaced.since`, `sync.json` for a conflict, a restore or the journal of a replay or a Save both, `exports/`, the lease `.lock.lease`; `UnreadableVersions`), `WorkspaceMedia` (`NamedAsAt`: the media learn the home's hashes and aliases), `WorkspaceSync` (checkout, open under the lease, save, commit, push, pull with replay and merge, the base in `project.chronos` as every write's commit point, `SettleAsync` finishing or undoing a cut push, replay or Save both, conflicts settled by keep mine, take server or save both only as shown, restore, status with Gone, Damaged and `MediaOutdated`, the home's frames read again only when their stamp moved; `FollowNameAsync`: the home's name and Main written into the copy at every pull and at a server's `renamed`), `WorkspaceCopyJobHandler` (`WorkspaceJobs.Copy` and `CopyFactsAsync`, registered by the desktop only: the archive only read, from a folder that holds the sequence; a workspace inside a library refused; the archive's current proxies copied, the others made in the workspace, each hash-verified, resumable from a checkpoint of its frames version and folder, free space checked against its estimate plus 512 MiB; the encodings conversions joined kept in `media.json`; the working state's positions moved by frame where frames stay, by photo where they came or went; a cancelled first copy's media cleared under the project's lease only when no other copy of the project waits or runs, through `ICancelledJobHandler` too; a project whose home is a server, `WorkspaceJobs.CopyFromServer`, phase 5b: downloaded through the desktop's session (`ISyncConnector`), never through this PC's archive, the frames of one frames version with the aliases of the server's conversions, each proxy (else the thumbnail standing in, `WorkspaceFrame.FileKind`) hashed as it arrives and checked on the disk, four at a time, the editor's current file never overwritten, resumable from the same checkpoint, a `.thumb` marker beside a thumbnail standing in until the commit, free space checked against the server's proxy sizes); phase 5c: `WorkspaceProject` gains `media/originals/-` (`OriginalName`), the ledger `exports/renders.json` (`WorkspaceRenders`, `WorkspaceRenderEntry`; `ContainedExportFile` keeps every ledger path inside `exports/`), `media.json` format 2 while it holds originals or was cleaned (`WorkspaceMedia.Cleaned`) and the project file format 3 while its media are Originals; `WorkspaceOriginals` (Proxies only's plan and apply, and `ClearOriginals`: every file of `media/originals` hashed and deleted only when the home's frames hold its SHA-256, the rest moved to the trash), `WorkspaceTrash` and `WorkspaceTrashBuilder` (`/.trash`: entries `-` filled under `.incoming--` and renamed when whole, listed with a fingerprint of every file's path, size and time, emptied only by a plan that still matches), `WorkspaceCleaner` (the clean-up of media of projects in step with their home: Clean after, Size limit, the reasons a project is kept in `WorkspaceKeep`, `UnsentRenders`), `WorkspaceMover` (survey, plan fingerprint, the journal `/.move.json` with stages Moving and Switched, rename on one volume or copy and hash-verify across volumes, resume, abandon, clear after the switch), `WorkspaceJobRoots` (internal, in `WorkspaceJobs.cs`: the folder a copy, render or send works in, the one that holds its project now, refused while a move has not switched) and the job parameters `WorkspaceRenderParameters`, `WorkspaceSendParameters`, `WorkspaceMoveParameters` in `WorkspaceJson`. Owner review 5, #66: `WorkspaceHomes` (the parent `workspace.json` format 2, layout "homes": `local` and `servers/`, each an ordinary store with `server.json`, `ServerHomeRecord`; `StoreFor(home)`, `All()`), `WorkspaceStore` refusing the homes layout and a read-only legacy view, `WorkspaceJobRoots` searching every home, `WorkspaceJobOptions.SameServer`/`IsSameServer` (aliases, used by the copy and send handlers' home checks), `WorkspaceMover` and `WorkspaceCleaner` over every home | +| `Sync` | `SyncService` (sync table of one server: compare, link by content through the aliases, settle conflicts, enqueue transfers), `SyncRules` (status, settings merge and differences, the proxies this PC can send, aliases followed; no I/O), `SyncTombstones` (photos either side removed are not offered back; the replaced tombstones of both sides join the encodings of one photo, union-find, each compared as the smallest SHA-256 among them, a deletion covering them all; immutable once made), `SyncPositions` (the settings' frame positions translated by photo to the frames of the copy they go to), `SyncLinkStore` (`sync_links`, `sync_state`), `SyncTransfers` and `SyncJobHandler` (resumable, hash-verified uploads and downloads as jobs; downloads commit through the archive ingest, and a frame missing here whose photo the server holds in another encoding takes that file through `FrameTrash.ReplaceMissingAsync`; job log lines from the catalog), `SyncAgent` (background comparison, server events, backoff, offline proxies; a server's `projectChanged` passed on as `ProjectChanged`, and null after a lost event stream once the stream is open again and a comparison made after that reached the server: `ISyncRemote.EventsAsync(connected, ct)`), `ProxyCache` and `RemoteSequence` (server sequences opened with proxies), `ISyncRemote` (the server calls; `ChronosSyncRemote` over `ChronosClient`). Owner review 5, #66: `ServerIdentity` (`KnownServerKey`; `Key`, `Canonical`, `Same`, `KeysOf`, `FolderName`, `With`), `SyncOptions.ServersDirectory` and `Identity`, `ProxyCache` per server with alias and 1.0 fallback reads, `SyncService.RekeyAsync`/`SyncLinkStore.RekeyAsync` | +| `Homes` | Owner review 5, #66: `HomeLayoutMigration` (`PlanAsync`, `ApplyAsync`: the 1.0 workspace and cache sorted into homes by same-folder renames checked by inventory, deferrals for leased projects, an offline workspace and an unfinished move; `RekeyAsync`: an address home renamed to the server id at sign-in), `HomeLayoutJournal` (the journal in the data folder that resumes after a crash) | ### 2.3 Chronos.App areas @@ -75,13 +79,13 @@ Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `S | `Library` | Filter, facets, pager, timeline, saved views, quick and mass actions (`MassActions`: Reorganize and Convert for the sequences of one archive), remote cards and thumbnails, thumbnail cache, list export | | `Editor` | `EditorSession` (project, undo/redo, saving, merges through `Data/Projects/ProjectMerge`), `ISequenceSource` (`LocalSequenceSource`, `RemoteSequenceSource`, `WorkspaceSequenceSource`: a workspace project over its media, the working state saved in `project.chronos` under the project's lease and merged photo by photo in the portable form (`Merge`, a setting both sides changed asked through `ProjectConflictException`), `ReadOnlyChanged` for a project of a newer Chronos, an unstored edit kept aside in `versions/.replaced` (`SetAsideAsync`), renders at the home with the portable settings through `IProjectRenders`, naming a version only while none waits to be sent; a server home's analyses and renders are the server's jobs over `WorkspaceServerHome(connect, session)`, which connects again when the sign-in changes, a render naming the version the server holds when the project is in step with it), `ServerJobs` (a server sequence's analyses and renders followed through its events, shared by `RemoteSequenceSource` and a server home's `WorkspaceSequenceSource`), the steps of the Edit path (`EditPath`: their order, each step's state, the step of each finding, the memory of the step shown; tabs Analysis, Frames, Exposure, Motion, Camera, Time, Stack, Export), the step rows (`CameraTab`: Aspect, Rotation, Mirror, Flip, Straighten, Crop size/X/Y and Reset framing through `EditorSession.Orient` and `ResetFraming`, the crop kept locked by `EditorSession.KeepCropLocked`; `ExposureTab`'s Look group; `ExportTab`'s Output size, Resolution, the Encoding and Playback rows and the footer (owner review 1, R3/R8); `ExportGroups` (`SettingGroup`: a collapsible group with its summary, open state in `EditorSettings.Groups`, which `AppSettings.EditorGroups` keeps; `ExportRules`: what rate control, keyframes, B-frames and profile offer per codec and depth, keyframes in seconds, the standard resolutions); `PresetTable` (the preset rows and their groups); `RenderMenu` (the header's Render ▾ entries, built on each opening: recommended, batch, recent, Other presets by group, Render batch, Add to queue, Save frame, Videos); `VideosLink` (the editor's way to the Videos section on a sequence); `EditorSession.StillRequests` (Save frame through the source's routing, `IProjectStills` for workspace projects); `SettingRows`: `SwitchRow`, `IconActionsRow`, `GroupRow`; `SliderActivity`, the Straighten slider showing the grid), `CropCommit` (a finished crop drag on the preview to `EditorViewModel.CommitCropCommand`, one undo step), `PreviewRenderer` (Source framing in the view frame through `RenderGeometry.ViewFor`, the mask from `EditableCrop` or `FootprintInView`, `FrameFinish` on the corrected picture only, motion vectors without it), `ExportPlanner`, `ExportSync`, `SavedCopies`, `SequenceJobs`, `ProjectFiles` (save and open `.chronos` project files: format 2 opens its workspace project, format 1 gives its settings to Main) | | `Videos` | Owner review 1, R9: `VideoSources` (WPF-free: `VideoEntry` rows of this PC's library, the signed-in server's `/videos` and the workspace's unsent renders merged by render id, `VideoFilter` and its order, `VideoServerState` for a server not signed in, without `videos` or out of reach, `WithLocalCopies` for server renders downloaded here; `VideosFolders`: the default `Videos\Chronos` and the folder's refusals), `VideoRows` (cards and list rows with their chips), `VideoPlayerPane` and `VideoPlayerViewModel` (in-process playback: `MediaElement` for videos, an image for stills and a GIF's or APNG's first frame, *Cannot play here*); the trash dialog restores video entries through `IVideoLibrary` | -| `Workspace` | Owner review 2, R8: `WorkspaceHost` (the desktop's `WorkspaceStore` and `WorkspaceSync` over Settings › Workspace's folder, this PC's archive or, through `SyncHost.ProjectHome`, the signed-in server as the home (a server it is not signed in to reads as offline; `HomeChanged` from the server's `projectChanged`, texts worded for it by `WorkspaceText.ForHome`); checkout and copy with its size and free space, status, Save version with the sync after it, sync, resolve, restore, history, open, new, rename, delete, the plan and removal of a local copy whose files but the media go to `/.trash` (put back whole when a move fails), pruning past Kept versions after `HoldsAsync`, copies a newer Chronos wrote or that cannot be read listed as such and never changed, a folder inside a library refused, `PlanFolderAsync` and `UseFolderAsync`; phase 5c partials: `WorkspaceHost.Media` (Copy originals, Proxies only), `.Render` (local renders, Send again), `.Cleanup` (usage, the clean-up after each copy and by schedule, the trash's plan and Empty, the removal's unsent renders and originals) and `.Move` (move plan and job, `IsMoving` gate, `MoveEnded`, the unfinished move)), `WorkspaceFolderChange` (Settings › Workspace › Change…, Move… and Resume, and the refused folder's Choose folder), `ProjectMenuViewModel` (the title's ▾: state chip read again after edits, the menu, Update media; `IWorkspaceUi` is what it asks of the section, `ShowDialogWhenFree` holding a background conflict until the open dialog closes), `WorkspaceDialogs` (Open in workspace with unreadable projects listed disabled, project name, Save version, History, conflict, a format conflict offering only Save both, Remove local copy with its typed confirmations; `WorkspaceDialogs.xaml`), `WorkspaceProjectItem` (a picker row), `WorkspaceText` (states, versions, authors, failures) | +| `Workspace` | Owner review 2, R8: `WorkspaceHost` (the desktop's `WorkspaceStore` and `WorkspaceSync` over Settings › Workspace's folder, this PC's archive or, through `SyncHost.ProjectHome`, the signed-in server as the home (a server it is not signed in to reads as offline; `HomeChanged` from the server's `projectChanged`, texts worded for it by `WorkspaceText.ForHome`); checkout and copy with its size and free space, status, Save version with the sync after it, sync, resolve, restore, history, open, new, rename, delete, the plan and removal of a local copy whose files but the media go to `/.trash` (put back whole when a move fails), pruning past Kept versions after `HoldsAsync`, copies a newer Chronos wrote or that cannot be read listed as such and never changed, a folder inside a library refused, `PlanFolderAsync` and `UseFolderAsync`; phase 5c partials: `WorkspaceHost.Media` (Copy originals, Proxies only), `.Render` (local renders, Send again), `.Cleanup` (usage, the clean-up after each copy and by schedule, the trash's plan and Empty, the removal's unsent renders and originals) and `.Move` (move plan and job, `IsMoving` gate, `MoveEnded`, the unfinished move)), `WorkspaceFolderChange` (Settings › Workspace › Change…, Move… and Resume, and the refused folder's Choose folder), `ProjectMenuViewModel` (the title's ▾: state chip read again after edits, the menu, Update media; `IWorkspaceUi` is what it asks of the section, `ShowDialogWhenFree` holding a background conflict until the open dialog closes), `WorkspaceDialogs` (Open in workspace with unreadable projects listed disabled, project name, Save version, History, conflict, a format conflict offering only Save both, Remove local copy with its typed confirmations; `WorkspaceDialogs.xaml`), `WorkspaceProjectItem` (a picker row), `WorkspaceText` (states, versions, authors, failures). Owner review 5, #66: `WorkspaceHost.Homes`, `Find`, `SyncOf`/`SyncFor` (one sync per store), `SameServer`, `Identity`, `Reopen` (the `Store` and `Sync` properties are gone) | | `Import` | `CardPool` (inserted cards, remembered cards, folders), camera profiles, plans and choices, destinations (archive, folder, server through `ServerImportSink`), card actions (verified delete, format, eject) | | `Archive` | `CurrentArchive`, `ArchiveTree`, figures for the charts, maintenance reports, Reorganize (`ReorganizeDialogViewModel`: folder, file and title templates each with its switch, the dry run, Apply queues the `move` job of that plan; `ReorganizePlans`: each template's check, the plan as rows and a summary; `ReorganizeOffer`: per archive, the templates Settings › Archive's toast offers, joined while that archive's toast is up), Convert (`ConvertDialogViewModel`: format, JPEG quality and a mode chosen at every run, the dry run made once per format and quality, Apply behind the mode's confirmation queues the `convert` job of that plan through `MassConverter.QueueAsync`; `ConvertPlans`: the plan as rows in the mode's words, a summary, the space line, the Replace confirmation that types the number of photos and the New sequence one that counts the photos not copied; `ConvertUndo`: the Undo the Jobs screen's toast offers when Replace conversions end, which restores the `Replaced` trash entries their jobs made, by the job's id), retag, delete and trash dialogs (`SequenceDeletion`, `DeletePlans`, `TrashEmptyPlans`: Empty… behind a dry run and a typed confirmation, every entry whose conversion was deleted named first), `ArchiveFailures` | -| `Server` | `ServerSession`, `ConnectFlow` (trust on first use), `SyncHost` (sync engine, agent, metered hold (`UploadHold`: uploads, downloads and the workspace's server copies and sends), editor connections, Export Sync; `HasProjects`, `ProjectHome` and `ProjectChanged`, also told with null at each session start and stop: the server as a project home), sync table, `RemoteSequenceApi` | -| `Jobs`, `Settings`, `About` | Job list and buffering, `JobNotices` (which job endings raise a toast, conversions among them; `JobEndings` lets a batch speak once); the schedules of Jobs › Scheduled (`DesktopScheduleHost`: the desktop's `IScheduleHost` and its system schedules `archive-scan`, `index-backup`, `housekeeping`, `workspace-cleanup`; `CacheTrimStep`, `WorkspaceCleanStep` and `WorkspaceTrashStep`, the host's clean-up steps; `SchedulesViewModel`, `ScheduleRowViewModel`, `ScheduleEditorViewModel` and `ScheduleDialogs.xaml`, the in-window editor; `ScheduleText`); settings rows (`LogSettingsRows`: Advanced's log rows; `WorkspaceSettingsRows`: Settings › Workspace), encoder and format inventories, `ProcessingTuning` (Settings › Rendering and Analysis applied to each job: parallelism, memory budget, quality), `InterfacePriority`, language catalog, naming preview; `AboutViewModel` (owned by the shell, not a section: Settings › About, the update notice of Settings › Updates and the update check on start), update check and download | -| `Infrastructure` | `AppServices` (composition root; `SequenceReorganized`, raised after each Reorganize step and each sequence a conversion replaced or made, reloads an editor open on that sequence; the archive engine's free space from `VolumeInfo.FreeBytesAt`), `AppSettings`, `AppLogging` (Settings › Advanced › Logs applied to the log files from their first line, a launch that only hands over included, and at every save), `AppEnvironment` (installed or portable), `AppClock` (today's date, frozen by `--capture`), `StartWithWindows` (this copy's sign-in entry), `UiLanguage`, `LiveRegion`, `RenderNodeHost`, `DiagnosticsBundle`, `ShellActions` (BRIEF §8.6), `SingleInstance` (one Chronos per data folder; a later launch hands its file over a named pipe, or waits for a closing one to exit and starts in its place), device monitor | -| `DesignTime` | `SampleData`: the archive, jobs and server the screenshots and smoke tests run on, dated from the fixed `SampleData.Now` | +| `Server` | `ServerSession`, `ConnectFlow` (trust on first use), `SyncHost` (sync engine, agent, metered hold (`UploadHold`: uploads, downloads and the workspace's server copies and sends), editor connections, Export Sync; `HasProjects`, `ProjectHome` and `ProjectChanged`, also told with null at each session start and stop: the server as a project home), sync table, `RemoteSequenceApi`. Owner review 5: `SyncHost.Identity`, `KeyOf`, `LastServer`, `KnownServersChanged`, `IdentityClash`, `OriginalsArchiveAsync`/`OriginalsForDownloadAsync`/`OriginalsArchivesAsync` and the re-key in `SwitchAsync` (#66); `ServerJobsApi` (`IServerJobsApi`) and `ServerJobsViewModel`/`ServerJobsView`, the connected server's running and paused jobs (#65); `LibraryShare` (`ShareState`, `ShareClient`, `ShareUploadsStep`: this PC's library shared on the LAN through `Chronos.Server`'s `HostedServer`, #67) and `ConnectFlow` refusing the own share (`ConnectError.OwnLibrary`) | +| `Jobs`, `Settings`, `About` | Job list and buffering, `JobNotices` (which job endings raise a toast, conversions among them; `JobEndings` lets a batch speak once); the schedules of Jobs › Scheduled (`DesktopScheduleHost`: the desktop's `IScheduleHost` and its system schedules `archive-scan`, `index-backup`, `housekeeping`, `workspace-cleanup`; `CacheTrimStep`, `WorkspaceCleanStep` and `WorkspaceTrashStep`, the host's clean-up steps; `SchedulesViewModel`, `ScheduleRowViewModel`, `ScheduleEditorViewModel` and `ScheduleDialogs.xaml`, the in-window editor; `ScheduleText`); settings rows (`LogSettingsRows`: Advanced's log rows; `WorkspaceSettingsRows`: Settings › Workspace), encoder and format inventories, `ProcessingTuning` (Settings › Rendering and Analysis applied to each job: parallelism, memory budget, quality), `InterfacePriority`, language catalog, naming preview; `AboutViewModel` (owned by the shell, not a section: Settings › About, the update notice of Settings › Updates and the update check on start), update check and download. Owner review 5: `JobText.Status`/`RowStatus`/`RowStatusToolTip` (the status line of a job's detail, `BarStatusLength` 60) and `JobEntry.Detail` (#65); `Settings/HomeRows` (`HomeFolderRow`, `KnownServerRow`, #66) and `Settings/ShareSettingsRows` (#67) | +| `Infrastructure` | `AppServices` (composition root; `SequenceReorganized`, raised after each Reorganize step and each sequence a conversion replaced or made, reloads an editor open on that sequence; the archive engine's free space from `VolumeInfo.FreeBytesAt`), `AppSettings`, `AppLogging` (Settings › Advanced › Logs applied to the log files from their first line, a launch that only hands over included, and at every save), `AppEnvironment` (installed or portable), `AppClock` (today's date, frozen by `--capture`), `StartWithWindows` (this copy's sign-in entry), `UiLanguage`, `LiveRegion`, `RenderNodeHost`, `DiagnosticsBundle`, `ShellActions` (BRIEF §8.6), `SingleInstance` (one Chronos per data folder; a later launch hands its file over a named pipe, or waits for a closing one to exit and starts in its place), device monitor. Owner review 5: `AppSettings.KnownServers` and `Share`, `AppServices.SortHomesAsync` with `HomeLayout`/`HomeLayoutError`, `CacheStore.ServersFolder`/`ServerFolder`, `AppServices.Share` | +| `DesignTime` | `SampleData`: the archive, jobs and server the screenshots and smoke tests run on, dated from the fixed `SampleData.Now`; `SampleJobDetails.Apply` (the sample jobs' details), `SampleServerJobs` (the server jobs capture) | ### 2.4 Chronos.Ui and Chronos.Server @@ -90,20 +94,21 @@ Dependencies point one way: `Core` ← `Core.Windows`, `Data`, `Protocol` ← `S | `Ui/Themes`, `Ui/Theming` | DESIGN tokens (light, dark), typography, control styles, `ThemeManager` | | `Ui/Controls` | `ChronosWindow` (chrome, language direction), `NavRail`, `JobBar`, `ToastHost` (`Toast.Closed` once a toast leaves the screen), `Field` (placeholder, icon, error), `Chip`, `AutoSlider`, `StatusGlyph`, `EmptyState`, `Icon`, `Bidi` (right-to-left rules), `Motion` (animations off for screenshots) | | `Ui/Interop` | DWM calls of the window chrome; `TrayIcon` (`Shell_NotifyIconW`: the Uploader's tray, the client's Windows notifications) | +| `Ui/Updates` | Owner review 5, #64: `UpdateState`, `UpdateHost`, `UpdateFlow`, shared by Chronos Desktop (About, Settings › Updates) and Chronos Uploader (`Shell/UpdatesViewModel`, `Infrastructure/UploaderUpdates`) | | `Ui/Visuals` | `DrawingElement` (hover readout, item keyboard and activation) and its charts (`BarChart`, `SeriesChart`, `StackedBar`, `HeatmapStrip`, `TimelineBands`), `Filmstrip`, `PreviewViewport` (with `PreviewSurface` and `ViewportMath`: the crop box's handles, hit-test order, drag, keyboard nudges once selected, the straighten grid and the automation value; the math in Core `CropFrame`), `CurveEditor`, `SequenceCard`, `VirtualizingWrapPanel`, `SegmentedControl`, `SplitButton` (owner review 1, R3: hierarchical, two-line menu entries, `RenderMenuItem` of kind preset, header, separator, command or submenu, styled in `Themes/Visuals.xaml`) | | `Server/Api`, `Server/Events` | Endpoint groups (`XxxEndpoints.Map`; `ScheduleEndpoints`: `/api/v1/schedules`; `LibraryEndpoints`: the Library filters' facets, sequence thumbnail, photo delete, bulk delete/retag/jobs; `TrashEndpoints`: list, restore, empty (`conversionDeleted` in its dry run; `videos--` entries restored through the videos library); `VideoEndpoints` (owner review 1, R9): `/api/v1/videos` list and get (Read), delete with a dry run and fingerprint (Delete, audited `videos_deleted`, `sequenceChanged` `renders`), copy as a `video-copy` job into `ServerOptions.VideosPath` (Edit, audited `videos_copied`), library refusals mapped to 409, 422 and 507; `SystemEndpoints` announcing the `videos` capability; `ProjectEndpoints`: `/api/v1/sequences/{sid}/projects` through the archive's `ProjectService` (list with Main first, create, rename, delete, head, versions a page at a time, one version, push with its outcome as `ProjectPushResultDto` under a 65 MiB body limit, the frames and photo aliases a workspace places positions on and their stamp; pages capped at 4 Mi settings characters, `summary` and `stored` reads, 409 `sequence_empty` for a sequence without photos, deletion by the owner, an admin or the maker's own account); `SequenceEndpoints`' settings `PATCH` through `ArchiveService.EditSettingsAsync`; `ArchiveEndpoints`: settings, statistics, scan jobs, Reorganize's dry run and `move` job, Convert's dry run and `convert` job, both through `PlanCache`: a dry run's plan, made apart from its request, a few at once across both kinds, kept a few minutes while what it reads from the index stays (typed keys `PlanKey`: `ReorganizePlanKey`, `ConvertPlanKey` from `GetConvertStampAsync`, the selection and the target with the quality that counts, not the mode), for the same dry run and its confirmation; a conversion's confirmation takes only a kept plan (`Kept`), its busy sequences and free space taken again), API errors, the WebSocket `EventHub` | | `Server/Security` | Accounts, password hashing, tokens, session cookies, login guard, access rules, audit log | -| `Server/Storage`, `Server/Jobs` | Archive and processing modules (the archive module's `SequenceChanged` publishes `sequenceChanged` `reorganized`, `converted` and `created`; its `FreeSpace` is `VolumeSpace.WritableFree`, the tighter of the space path's volume and the folder's own), uploads (`UploadMaintenance`: recovery at start, and the sweep that is the `uploads` clean-up step; `UploadService.ReceiveAgainAsync`: a verified upload whose filing was refused for now goes back to receiving, 503), render store (files a render under the sequence's lease, where the index has the folder then, with the project and version a node's job rendered; `FolderMovedException`, 503 `folder_moved`, when the sequence is not in it; a sent render or a node's result recorded with its verified SHA-256 and kind); `FileResponses` (Range requests, the media types of `.webm`, `.m4v` and `.apng`); the archive module sets `Videos.ProtectedFolders` to the data folder; `ProjectCatchUp` (Main takes settings written outside the projects soon after a `PATCH`, an analysis or a conversion, for sequences with a Main: `projectChanged` without waiting for the next project call); the archive module's `ProjectsChanged`, published as `projectChanged` (and `sequenceChanged` `settings` when Main was mirrored); `JobEngineHost`, `SchedulerHost` (the `Scheduler` on the engine, started after it; archive.json read every 10 minutes whatever the scan schedule does; every schedule change and run published as a `scheduleChanged` event) and `ServerScheduleHost` (time zone, archive refreshed from archive.json, system schedules), render node service (a job of a project version claimed with that version's settings placed on the frames it lists; `RoutedAsync` routes a job again from the sequence's settings of the moment, and a node that reads an older settings format, or cannot encode the adapted size, never claims it), monitor and availability (`RenderNodeAvailability` waits for a node only while one would take the routed job) | -| `Server/Hosting`, `Server/Admin/web` | `ServerHost`, `ServerLogging` (console and file levels the logging filters read at every line, the file sink's limits, the engine's level; applied again when Settings › Logs is saved), certificates, discovery beacon, embedded static files (`EmbeddedStaticFiles`: `no-cache` and a content ETag, so an upgrade never mixes old and new modules), Windows service (start and stop failures in the Application event log); the admin panel (ES modules, one per page; `schedules.js` is the Jobs page's Scheduled tab; the Library's views in `pages/library/`: `sequence.js` a sequence and its photo viewer, `projects.js` its Projects section (Main marked, head and last change, versions on demand, Rename and Delete of the others, live on `projectChanged`; nothing that edits settings), `trash.js` the archive's trash, `shared.js` cards, selection, grid keyboard and the retry of thumbnails a finished job may have built; `upload.js` the upload dialog the Library opens on demand, hashing in the module worker `hash-worker.js` with the in-house incremental SHA-256 of `sha256.js`, self-tested before its first use, and sending the capture time `capture-time.js` reads: the Exif DateTimeOriginal of a JPEG or TIFF-based file, else the file's time; `reorganize.js` the Reorganize dialog of the Library's selection and of the Archive page's save toast: template switches and fields, a live dry run of `POST /archive/reorganize` one request at a time, Apply that sends the shown plan's fingerprint back; `convert.js` the Convert dialog of the Library's selection (`planTarget` in `library.js`, shared with Reorganize: the ids, at most 1,000, or `all`): format, JPEG quality and a mode chosen at every run (Replace or New sequence, never preselected), a debounced dry run of `POST /archive/convert` one request at a time, asked in Replace's words until a mode is chosen and again while the server is still making it (a proxy's cut-off, `plan_dropped`), per sequence photos converted, left as they are or not copied and why, blocked, size before and after, the space line; Apply that confirms Replace by a typed word and New sequence with the photos not copied, asks the dry run again and sends the shown plan's fingerprint back, never twice after no answer; `pages/library/trash.js` gives replaced entries their own Restore and lists those whose conversion was deleted first, and names `videos` entries with their own Restore message; `audit.js` reads `archive_converted` as a sentence; `videos.js` the Videos page (owner review 1, R9: cards or list, filters in the address, `#/videos?sequence=`, selection, Play in a `