ksqlDB stream processing expert. Covers SQL-like queries on Kafka topics, stream and table concepts, joins, aggregations, windowing, materialized views, and real-time data transformations. Activates for ksqldb, ksql, stream processing, kafka sql, real-time analytics, windowing, stream joins, table joins, materialized views.
View on GitHubanton-abyzov/specweave
sw-confluent
January 25, 2026
Select agents to install to:
npx add-skill https://github.com/anton-abyzov/specweave/blob/main/plugins/specweave-confluent/skills/confluent-ksqldb/SKILL.md -a claude-code --skill confluent-ksqldbInstallation paths:
.claude/skills/confluent-ksqldb/# Confluent ksqlDB Skill
Expert knowledge of ksqlDB - Confluent's event streaming database for building real-time applications with SQL-like queries on Kafka topics.
## What I Know
### Core Concepts
**Streams** (Unbounded, Append-Only):
- Represents immutable event sequences
- Every row is a new event
- Cannot be updated or deleted
- Example: Click events, sensor readings, transactions
**Tables** (Mutable, Latest State):
- Represents current state
- Updates override previous values (by key)
- Compacted topic under the hood
- Example: User profiles, product inventory, account balances
**Key Difference**:
```sql
-- STREAM: Every event is independent
INSERT INTO clicks_stream (user_id, page, timestamp)
VALUES (1, 'homepage', CURRENT_TIMESTAMP());
-- Creates NEW row
-- TABLE: Latest value wins (by key)
INSERT INTO users_table (user_id, name, email)
VALUES (1, 'John', 'john@example.com');
-- UPDATES existing row with user_id=1
```
### Query Types
**1. Streaming Queries** (Continuous, Real-Time):
```sql
-- Filter events in real-time
SELECT user_id, page, timestamp
FROM clicks_stream
WHERE page = 'checkout'
EMIT CHANGES;
-- Transform on the fly
SELECT
user_id,
UPPER(page) AS page_upper,
TIMESTAMPTOSTRING(timestamp, 'yyyy-MM-dd') AS date
FROM clicks_stream
EMIT CHANGES;
```
**2. Materialized Views** (Pre-Computed Tables):
```sql
-- Aggregate clicks per user (updates continuously)
CREATE TABLE user_click_counts AS
SELECT
user_id,
COUNT(*) AS click_count
FROM clicks_stream
GROUP BY user_id
EMIT CHANGES;
-- Query the table (instant results!)
SELECT * FROM user_click_counts WHERE user_id = 123;
```
**3. Pull Queries** (Point-in-Time Reads):
```sql
-- Query current state (like traditional SQL)
SELECT * FROM users_table WHERE user_id = 123;
-- No EMIT CHANGES = pull query (returns once)
```
## When to Use This Skill
Activate me when you need help with:
- ksqlDB syntax ("How to create ksqlDB stream?")
- Stream vs table concepts ("When to use stream vs tab