Kafka: replication.factor and the loss of a broker

A replication factor of one means any broker restart takes its partitions offline.

Code
kafka-topics.sh --bootstrap-server localhost:9092 \
  --create --topic orders --partitions 6 --replication-factor 3
Output
RF=1: one broker down = data unavailable, and gone if the disk fails
RF=3: survives two broker failures, at 3x the storage
Advertisement

Run this yourself in the Online Java Compiler, spin up a live REST API in the API Sandbox, or practise with Java interview questions.

Published 2026-08-11