Don't PanicWindows & triggers

Windowed vs continuous

Windowed or continuous is the choice between finished snapshots per bucket of time and one running answer that keeps updating.

WINDOWEDone result per bucketemit at closeCONTINUOUSone running value per keyupsert per tick
Windowed emits each window once, when it closes. A continuous view keeps one running value per key and republishes it as an upsert on every --emit-every tick.

Windowed vs continuous - the two shapes a streaming result can take, and the windowed vs continuous query choice decides everything downstream: either one finished snapshot per bucket of time, or one running answer per key that never finishes. A windowed query emits each group once, when its window closes; the row is final and the output is append-only. A continuous query keeps one live value per key and republishes it as it changes, so the output is a changelog and the current answer is latest-per-key. That second shape is a materialised view, kept fresh.

Choose by the question. "Revenue per hour" is windowed; "revenue so far" is continuous. The sink follows the choice: an append-only store for finished windows, an upsert-capable store or a compacted topic for a changelog.

Do you need it? You need to make the choice, once, and it is one line of SQL. In ubik a GROUP BY with a tumbling window emits each window once when the watermark passes its end; the same GROUP BY without a window is a continuous view, republished as an upsert changelog on the --emit-every cadence. Same aggregates, same stream, different clock on the answer.

Sources

Related