Build Kafka (13 scenes)
Scene 1.5 · Hello Kafka — topic, brokers, records
Foundations: what's a topic vs a partition, what's a broker, what does the producer/consumer code actually look like.
Previously

You've named the parts. Now meet a real topic — partitioned across brokers — and watch a record's journey from producer call to consumer poll, end to end.

Scene 1.5
Hello Kafka — topic, brokers, records
Diagram
A topic 'events' shown as a row of partitions, each laid out across brokers in a small cluster. Producers append records (key, value, timestamp, headers) to the right edge of each partition; consumers read from the left at their own offset. Code panels show the producer and consumer client calls that drive every arrow you see.
Producersend(record)key, value, timestampPARTITION 0events3 partitions1 partition shownBroker 2holds P0, P3, P7PRODUCER / CONSUMER PSEUDOCODEproducer = new Producer({ broker: "..." })producer.send({ topic: "events", key: "user-42", value: click })// routed by keyconsumer = new Consumer({ groupId: "dashboard" })consumer.subscribe("events")for (record of consumer.poll()) { ... }Consumeroffset = 0
A topic called "events" lives on a broker as a partitioned log. The producer sends records into Partition 0; the consumer polls them back. Watch the code panel — the line that's running glows.
Not sure what to ask? Tap a question — the staff engineer answers in the chat panel.