2. Installing Kafka
2.0 The shape of a Kafka deployment
Everything else is tuning.
zookeeper.connect = zoo1:2181,zoo2:2181,zoo3:2181/kafka-cluster-a — the trailing chroot path is what lets the ensemble “be shared with other applications, including other Kafka clusters, without conflict.” If the chroot path doesn’t exist, the broker creates it at startup.
- · Every broker has the same
zookeeper.connect— same ensemble and same path. - · Every broker has a unique
broker.id. If two brokers try to join with the same ID, the second logs an error and fails to start. - · Those are the only two requirements to form a cluster. Everything else is tuning.
Two hard requirements to form a cluster — that's all:
- Every broker has the same
zookeeper.connect(same ensemble + same path). - Every broker has a unique
broker.id. If two brokers try to join with the same ID, the second logs an error and fails to start.
Everything else is tuning.