Streams, windows, and delta streams offer different characteristics and features, but also share common designation, visibility, and column parameters.
The terms "stateless" and "stateful" commonly describe the most significant difference between windows and streams. A stateful element has the capacity to store information, while a stateless element does not.
Feature Capability | Streams | Windows | Delta Streams |
---|---|---|---|
Type of element | Stateless | Stateful, due to retention and store capabilities | Stateless |
Data retention | None | Yes, rows (based on retention policy) | None |
Available store types | Not applicable | Memory store or log store | Not applicable |
Element types that can be derived from this element | Stream or a Window with an aggregation clause (GROUP BY) | Stream, Window, Delta Stream | Stream, Window, Delta Stream |
Primary key Required | No | Yes, explicit or deduced | Yes, explicit or deduced |
Support for aggregation operations | No | Yes | No |
Behavior on receiving update | Receives and produces insert | Receives and produces update | Receives and produces update |
Behavior on receiving insert | Receives and produces insert | Receives and produces insert | Receives and produces insert |
Behavior on receiving delete | Receives but ignores | Receives and produces delete | Receives and produces delete |
Streams, windows, and delta streams share several important characteristics, including implicit columns and visibility rules.