feat(pipeline): standalone Blender renders on the same queue
Deploy / deploy (push) Successful in 7m2s
Deploy / deploy (push) Successful in 7m2s
Blender work is not a shot submission: no Export, no version, no validation, QC or delivery. It is "Ctrl+F12, but on the farm", so it is modelled as what it is — a queue entry and nothing more. That turned out to need very little. Claim, progress, fail and complete-render already tolerated a job with no Export behind them, so a Blender job reuses the whole lifecycle; RenderJob gains projectId, label and submittedBy so a job with no shot code still has something to show. Capability gating is new and was already missing: the claim now filters job types by the machine's reported tools. Without it a workstation without Blender would claim Blender work and fail it repeatedly, burning the attempts while a machine that could have rendered it sat idle. The worker asks for Blender jobs unconditionally and the server refuses them — trusting the worker to self-select would have left the same hole. The runner treats a clean exit with no saved frames as a failure: Blender exits 0 when a frame range is empty or an output path is unwritable, and a job that silently rendered nothing is the worst outcome available. Standalone jobs auto-requeue on a transient failure like any other work; delivery builds are deliberately excluded, since a half-written package wants a human first. Adds the Blender add-on (BlenderPanel/) and its docs. The add-on refuses to submit an unsaved file — the farm opens the .blend from disk, so unsaved changes would render the previous state without warning. Its payload is pinned by a contract test, since add-on and server only ever meet over JSON. Worker 1.5.0. Adds migration 20260815000000_blender_render_jobs. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
-- Standalone Blender renders: a queue entry with no Export behind it.
|
||||
|
||||
-- AlterEnum
|
||||
ALTER TYPE "RenderJobType" ADD VALUE 'BLENDER_RENDER';
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "render_jobs" ADD COLUMN "projectId" TEXT;
|
||||
ALTER TABLE "render_jobs" ADD COLUMN "label" TEXT;
|
||||
ALTER TABLE "render_jobs" ADD COLUMN "submittedBy" TEXT;
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "render_jobs_projectId_status_idx" ON "render_jobs"("projectId", "status");
|
||||
@@ -149,6 +149,10 @@ enum RenderJobType {
|
||||
AE_RENDER
|
||||
PREVIEW_ONLY
|
||||
DELIVERY_BUILD
|
||||
/// A standalone Blender render: a queue entry and nothing more. It has no
|
||||
/// Export, takes no shot version, and is not validated, QC'd or delivered —
|
||||
/// it is "Ctrl+F12, but on the farm".
|
||||
BLENDER_RENDER
|
||||
}
|
||||
|
||||
enum ValidationStatus {
|
||||
@@ -915,6 +919,13 @@ model RenderJob {
|
||||
exportId String? // set for AE_RENDER / PREVIEW_ONLY
|
||||
export Export? @relation(fields: [exportId], references: [id])
|
||||
deliveryId String? // set for DELIVERY_BUILD (Phase 5)
|
||||
/// Set for jobs that belong to a project but not to a shot — a standalone
|
||||
/// Blender render. Lets the queue be filtered by production without
|
||||
/// inventing an Export for work that has no shot.
|
||||
projectId String?
|
||||
/// Human label for such a job, since there is no shot code to show.
|
||||
label String?
|
||||
submittedBy String? // email/name of whoever queued it
|
||||
attempt Int @default(1)
|
||||
maxAttempts Int @default(3)
|
||||
status RenderJobStatus @default(QUEUED)
|
||||
@@ -942,6 +953,7 @@ model RenderJob {
|
||||
|
||||
@@index([status, priority, createdAt])
|
||||
@@index([machineId, status])
|
||||
@@index([projectId, status])
|
||||
@@map("render_jobs")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user