a273e28e20
This ensures that when using automatic Kafka topic creation, with more than one node in the Kafka cluster, all partitions in the topic are automatically replicated. When a single node goes down in a >=3 node cluster, these topics will continue to accept writes providing there are at least two insync replicas. In a two node cluster, no failures are tolerated. In a three node cluster, only a single node failure is tolerated. In a larger cluster the configuration may need manual tuning. This configuration follows advice given here: [1] https://docs.cloudera.com/documentation/kafka/1-2-x/topics/kafka_ha.html#xd_583c10bfdbd326ba-590cb1d1-149e9ca9886--6fec__section_d2t_ff2_lq Closes-Bug: #1888522 Change-Id: I7d38c6ccb22061aa88d9ac6e2e25c3e095fdb8c3
26 lines
1.1 KiB
Django/Jinja
26 lines
1.1 KiB
Django/Jinja
listeners=PLAINTEXT://{{ api_interface_address | put_address_in_context('url') }}:{{ kafka_port }}
|
|
controlled.shutdown.enable=true
|
|
auto.leader.rebalance.enable=true
|
|
num.network.threads=3
|
|
num.io.threads=8
|
|
socket.send.buffer.bytes=102400
|
|
socket.receive.buffer.bytes=102400
|
|
socket.request.max.bytes=104857600
|
|
log.dirs=/var/lib/kafka/data
|
|
min.insync.replicas={{ kafka_broker_count if kafka_broker_count|int < 3 else 2 }}
|
|
default.replication.factor={{ kafka_broker_count if kafka_broker_count|int < 3 else 3 }}
|
|
num.partitions=30
|
|
num.recovery.threads.per.data.dir=1
|
|
offsets.topic.replication.factor={{ kafka_broker_count if kafka_broker_count|int < 3 else 3 }}
|
|
transaction.state.log.replication.factor={{ kafka_broker_count if kafka_broker_count|int < 3 else 3 }}
|
|
transaction.state.log.min.isr={{ kafka_broker_count if kafka_broker_count|int < 3 else 2 }}
|
|
log.retention.hours=168
|
|
log.segment.bytes=1073741824
|
|
log.retention.check.interval.ms=300000
|
|
zookeeper.connect={{ kafka_zookeeper }}
|
|
zookeeper.connection.timeout.ms=6000
|
|
{% if enable_monasca | bool %}
|
|
log.message.format.version=0.9.0.0
|
|
connections.max.idle.ms=31540000000
|
|
{% endif %}
|