From 25be04ce2620769b1fbafc9d5bc4530acc5f465d Mon Sep 17 00:00:00 2001 From: Valeriy Selitskiy <239034+iamwavecut@users.noreply.github.com> Date: Thu, 3 Dec 2026 21:07:30 +0100 Subject: [PATCH] Give a video seven minutes on the farm A ten-second clip renders in up to 140 s at 4 steps, and draw-api may first wait up to 240 s for the GPU, so the shared five-minute draw deadline gave up on clips that were still rendering. --- crates/openplotva-app/src/image_jobs.rs | 3 +++ crates/openplotva-app/src/lib.rs | 1 + 2 files changed, 4 insertions(+) diff --git a/crates/openplotva-app/src/image_jobs.rs b/crates/openplotva-app/src/image_jobs.rs index d3d68ab..9df05fe 100644 --- a/crates/openplotva-app/src/image_jobs.rs +++ b/crates/openplotva-app/src/image_jobs.rs @@ -85,6 +85,9 @@ pub const AIFARM_DRAW_API_H3VIDEO_ENDPOINT_NAME: &str = "h3video_generate"; pub const AIFARM_DRAW_API_DEFAULT_BASE_URL: &str = "http://127.0.0.1:50051"; pub const AIFARM_DRAW_API_DEFAULT_TIMEOUT: StdDuration = StdDuration::from_secs(5 * 60); pub const AIFARM_DRAW_API_DEFAULT_POLL_INTERVAL: StdDuration = StdDuration::from_secs(1); +/// Farm deadline of one clip. A ten-second video renders in up to 140 s at 4 steps, after +/// draw-api has waited up to 240 s for the GPU, and then crosses the slow farm link. +pub const AIFARM_DRAW_API_VIDEO_TIMEOUT: StdDuration = StdDuration::from_secs(7 * 60); /// How long the farm may hold a draw submit for a free slot before answering /// 429 instead of queueing it. draw-api runs one job at a time, so a queued job /// abandoned by our inference watchdog would still burn the slot later; waiting diff --git a/crates/openplotva-app/src/lib.rs b/crates/openplotva-app/src/lib.rs index 9221f92..a1ff487 100644 --- a/crates/openplotva-app/src/lib.rs +++ b/crates/openplotva-app/src/lib.rs @@ -4438,6 +4438,7 @@ async fn start_runtime_workers( image_jobs::AifarmDrawApiConfig { endpoint_name: image_jobs::AIFARM_DRAW_API_FASTFRAMES_ENDPOINT_NAME .to_owned(), + timeout: image_jobs::AIFARM_DRAW_API_VIDEO_TIMEOUT, ..image_jobs::aifarm_draw_api_config_from_app_config(config) }, ),