Kafka Streams and Stream Processing – CCDAK Study Guide
This domain accounts for 30% of the exam and covers building stream-processing applications with the Kafka Streams library — the KStream/KTable abstractions, stateless and stateful operations, windowing, joins, and state stores. The recurring exam skills are distinguishing KStream from KTable, telling stateless from stateful operations, and picking the right window or join for a scenario.
KStream vs KTable
The foundational distinction:
- KStream — a record stream: every record is an independent event (append-only). Use for events like clicks, orders, transactions.
- KTable — a changelog stream: records are upserts keyed by key, so the KTable materializes the latest value per key (like a database table). Use for current state: inventory levels, user profiles.
- GlobalKTable — a KTable fully replicated to every application instance, useful for joins against reference/lookup data without co-partitioning.
Stateless vs Stateful Operations
| Type | Operations | Needs state store? |
|---|---|---|
| Stateless | map, filter, flatMap, branch/split, peek | No |
| Stateful | count, reduce, aggregate, joins, windowed operations | Yes |
- map (1→1), flatMap (1→0..many), filter (keep/drop), branch (route to multiple streams) — each record handled independently.
- aggregate / reduce / count — accumulate per-key results in a state store.
Unlock with a paid plan
5 more sections (about 328 words) continue below. Every paid plan unlocks all CCDAK study guides, the full question bank and mock exams, from $4.97/month.