Skip to main content

## MIGRATION_017

# Constant MIGRATION_017

Source

    const MIGRATION_017: &str = r#"
    -- Resolved download source URL and on-disk target directory, captured when the
    -- download is enqueued. Nullable: pre-existing rows and rows enqueued without a
    -- URL simply won't be auto-started by the pump.
    ALTER TABLE downloads ADD COLUMN stream_url TEXT;
    ALTER TABLE downloads ADD COLUMN target_dir TEXT;
    "#;

Expand description

Migration to persist the resolved stream URL and target directory on each download row. This lets the backend queue pump start a pending download by itself (replaying the stored URL) once a concurrency slot frees up, instead of relying on the frontend to re-issue every queued item.