feat: add job outbox, relay, leases and image variants to the pipeline

Move publishing out of the upload path: a relay process publishes queued
jobs with confirms. Add lease and attempt fencing, backoff with jitter, a
per-job render process with CPU and memory limits, crop and optimized
variants, the failed registry with audited replay, and staging cleanup.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-31 15:36:15 +03:00
co-authored by Claude Opus 5.5
parent 99a222eee2
commit e2a6427c24
102 changed files with 9499 additions and 1916 deletions
+7
View File
@@ -14,6 +14,13 @@ paths:
`src/schemas/jobs/attachment.py`, а не DTO: оно приходит извне и разбирается по
`contracts/jobs.schema.json`.
С change `pipeline-reliability`: `AttachmentJobDTO.attempt_base`,
`AttachmentInListDTO.status`, `updated_at`, `ReconcilePassDTO.listed_staging`, новые
`AttachmentJobReplayDTO`, `FailedJobDTO`, `RelayPassDTO`, `StagingCleanupPassDTO`,
`ReplayResultDTO`, `ReplayPassDTO`, `RenderedVariantDTO`, `RenderedVariantsDTO`;
`AttachmentJobReason` — ещё лимиты, `render_killed`, `render_crashed`,
`lease_expired`; `ReconcileFinding.ORPHAN_STAGING`.
`src/schemas/dataclasses/<domain>.py` — DTO между repo → service → api;
`src/schemas/enums/<domain>.py` — `StrEnum` доменов. HTTP-модели
(pydantic) лежат не здесь, а в `src/api/schemas/` (`api-layer.md`).