Skip to content

fleet queue: live tasks table still defaults max_attempts to 4 — align with the code DDL (1000) or record acceptance #12997

Open

Description

@dezren39

Gap (from the #12901 attempt-cap reconciliation, 2026-11-23)

The live fleet-queue Turso database's tasks table still carries the pre-#8973 column default:

max_attempts INTEGER NOT NULL DEFAULT 4

(read live 2026-11-23 via turso db shell fleet-queue on the laptop: SELECT sql FROM sqlite_master WHERE type='table' AND name='tasks').

Every current source of truth says 1000:

The broker only runs CREATE TABLE IF NOT EXISTS, so the live table never picks up the new DDL, and SQLite/libsql cannot change a column default in place — alignment needs a table rebuild (create new table with DEFAULT 1000, copy, swap) against the production queue store, or an explicit operator decision to accept the divergence because all broker paths write the value explicitly and the default only fires for out-of-band raw inserts.

Acceptance

  • The live tasks.max_attempts column default reads 1000 (verified by the sqlite_master query above), OR the divergence is accepted by an explicit recorded operator decision naming the reason.
  • Queue health stays green across the change (no at-cap or claim regression; fleet queue health before/after).

This is an operator/primary-seat action on the production queue store — not a code change. #12901 stays open on this item only.

Activity

  1. developing-today commented on Nov 23, 2026

    @developing-today
    Contributor
  2. dezren39 commented on Nov 23, 2026

    @dezren39
    MemberAuthor

    Claim — Lane IN (archer), 2026-11-23. Taking the lane-carryable slice of #12997: fresh first-hand re-verification of the live divergence (DDL + row distribution + code sources of truth) and a prepared operator packet — the exact table-rebuild procedure (with before/after health checks) and the acceptance-decision wording — so the primary seat's remaining action is a decision, not an investigation.

    Explicitly NOT in this lane's scope: executing the rebuild against the production queue store, or recording the acceptance as decided. Both are the operator/primary-seat actions the issue names; this lane prepares them and leaves the decision open.

    Premise + ownership (fresh gh REST): #12997 OPEN, no claims or comments beyond the Kaneo link; #12901's reconciliation (Lane IC) filed it as the sole remainder and did not claim it.

  3. dezren39 commented on Nov 23, 2026

    @dezren39
    MemberAuthor

    Claim — Lane JK (archer), 2026-11-23 ~01:00 CST. Taking over the verification slice of #12997 from Lane IN, whose claim (2026-11-23T06:46Z) was orphaned when that lane ended ~1 minute later with no writes attributable. Scope of this slice: fresh first-hand re-verification of the live divergence (live tasks schema default, row distribution, code-side DDL/defaults on current main, queue health), recorded on this issue. The production table rebuild itself is an operator/primary-seat action and is NOT part of this lane's slice.

  4. dezren39 commented on Nov 23, 2026

    @dezren39
    MemberAuthor

    Verification record — Lane JK (archer), 2026-11-23 ~01:05 CST. Fresh first-hand re-verification of the #12997 divergence (this also reconciles Lane IN's orphaned claim: IN ended ~1 minute after claiming with no writes; nothing of IN's needed redoing beyond this check).

    Live store (via laptop turso db shell fleet-queue, read just now):

    • SELECT sql FROM sqlite_master WHERE type='table' AND name='tasks' → max_attempts INTEGER NOT NULL DEFAULT 4. The divergence is real and current — the live column default is still 4.
    • Row distribution now: 17,923 @ 1000 of 18,106 total (17,921 @ 1000 at filing ~40 min ago — the +2 delta is new tasks written explicitly at 1000, i.e. live traffic still never touches the column default). Historical tail unchanged in shape: 75 @ 3, 72 @ 4, 20 @ 6, 14 @ 2, 1 @ 10, 1 @ 5 — all explicit per-task values from their creation era.

    Code side (current main, read via gh REST this run):

    • Fresh-store DDL: pkgs/fleet/crates/fleet-queue/src/turso_queue/core.rs:987 — max_attempts INTEGER NOT NULL DEFAULT 1000.
    • Ceiling: validate.rs:1119 — MAX_ATTEMPTS_CEILING: u64 = 1000, enforced range 1..=1000.
    • Broker creation paths write TASK_DEFAULT_MAX_ATTEMPTS explicitly (turso_queue.rs), so the stale default only fires for out-of-band raw inserts that omit the column.

    Queue health: could not be read this run — fleet queue health fails on the session-proxy leg, which has been down since ~2026-11-23 05:48Z (pre-existing platform fault, unrelated to this issue). The before/after health check in the acceptance criteria can only be exercised alongside the rebuild itself, once that leg is back.

    Verdict: premise TRUE, divergence inert in practice (every broker path writes 1000 explicitly; zero live rows owe their value to the default). Next step — operator/primary-seat decision, unchanged from the issue body: either (a) table rebuild on the production store (create new table with DEFAULT 1000, copy, swap) with fleet queue health before/after, or (b) an explicit recorded operator decision accepting the divergence. This lane does not perform production-store surgery; #12997 (and therefore #12901) stays open on that decision.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions