Bounded query execution: /v1/query OOM fix (LLP 0054-0059) [blocked by upstream]#221
Bounded query execution: /v1/query OOM fix (LLP 0054-0059) [blocked by upstream]#221philcunliffe wants to merge 4 commits into
Conversation
Mint the missing `design` LLP for the /v1/query OOM kernel-fix package. The package shipped spec (0054) + decisions (0055/0056) + prose plan (0057) with no design-type doc, so `neutral backlog` flagged 0054 as needing a design. LLP 0058 ties the spec to a concrete technical design grounded in the real query kernel: the buffering OOM site at `src/core/query/sql.js` (`squirrelExecuteSql` called with no signal, then `collect()`), the dead `context.signal` abort path, the dormant `scanColumn` aggregate fast path no kernel source implements, and the display-only `ContextControls` budget. It lays out signal threading, streaming aggregates via `scanColumn` down the source stack (per 0055), and the refuse-over-budget execution budget (per 0056), citing the decisions rather than restating them. @ref LLP 0054 (implements, coverage) / 0055, 0056 (constrained-by). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Mints the neutral executable plan for the /v1/query OOM kernel fix change set: a ## Tasks breakdown that extends the prose plan LLP 0057 and implements the technical design LLP 0058. Nine independently mergeable tasks across the three design mechanisms (signal threading, scanColumn down the source stack, execution budget with refusal), their two upstream engine PRs (icebird, squirreling), caller wiring, and an end-to-end memory-invariant smoke. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
🤖 neutral: blocked by upstream (held — not a failure)Labelled
What happens when you publish: drop the T1 (signal threading) lands here now — it works against the current pinned |
…T1, LLP 0059)
executeQuerySql now composes the caller-supplied `signal` with an optional
relative `timeoutMs` deadline (via AbortSignal.timeout/AbortSignal.any) and
forwards it as squirrelExecuteSql({ tables, query, signal }) at the call site
that previously omitted it. squirreling@0.12.24 already threads `signal` through
`context.signal` to its blocking operators (sort.js, aggregates.js) and the leaf
parquet scan honors it at the row-group boundary, so this wiring is the whole
fix: a long or runaway query can now be torn down mid-scan instead of running to
completion. This is the abort enabler only; it bounds nothing on its own (the
execution budget and refusal are T6/T7).
Add `signal?` and `timeoutMs?` to ExecuteSqlOptions. Annotate the call site with
@ref LLP 0054#signal-threading [implements].
Tests (test/core/query-sql-signal.test.js): a caller-aborted signal tears down a
running query mid-scan; an already-aborted signal stops it before completion; a
timeoutMs deadline aborts a slow query; and a normal no-signal query still
returns all rows (backward compatible).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
🤖 neutral: stuck — blocked by upstream (held, not a failure)What neutral was doing: driving the Why it cannot proceed: this is the hypaware slice of a 3-repo change set. The remaining kernel tasks pin exact upstream versions that do not exist on npm yet, so they cannot build or test:
Both upstream PRs are held/reviewed/green and waiting on your merge + npm publish. This is an external-dependency block, not a failed attempt — nothing here for a worker to retry. What it needs from you: merge and How to unstick: once the new |
Kernel fix for the
/v1/queryOOM. Implements the bounded-query-execution change set: spec LLP 0054, decisions 0055/0056, plan 0057 (human) → design 0058 + executable plan 0059 (neutral). Seellp/0058-bounded-query-execution.design.mdfor the technical design andllp/0059-…plan.mdfor the task breakdown.⛔ Blocked by (must be merged AND published to npm first)
This change set spans three repos. The kernel tasks below pin exact versions, so they cannot build/test until the upstream features ship:
scanColumnstreaming hook → publish a newicebird(currently pinnedicebird@0.8.11, which lacks it). Blocks T3/T4/T5.QueryBudgetExceededError→ publish a newsquirreling(currently pinnedsquirreling@0.12.24, which lacks it). Blocks T7/T8/T9.This PR stays draft + labelled
neutral:stuckuntil both upstream PRs are merged + published; it is blocked by an external dependency, not a failed attempt. Once the new versions are published, neutral bumps the pins and lands the remaining tasks, then drives this to held for review.Task status (LLP 0059)
AbortSignalintosquirrelExecuteSql;sql.js:115)squirreling(already threadssignal); greenscanColumnscanColumnforward (union-source.js)withSchemaColumnsforward (dataset.js)bounded_query_refusalacceptance smokeChange-Set: bounded-query-execution