Scenario 07.1.3 · Inkless: a broker dies
Aiven Inkless: what losing a Kafka broker costs
Aiven Inkless 0.51 · the broker in the clients' zone dies: nothing to catch up, since the data is in object storage; the clients fall back to another zone, whose cache starts cold.
Run this scenario in the playgroundWritten through broker-2. t+1.400s
p1 is in az-b, so its record went to broker-2, the only az-b broker, and was committed by PostgreSQL at 1310 ms. broker-2 keeps the committed range in its cache. The consumer group g1, also in az-b, has not polled yet.
Open at this step: step 1, Written through broker-2broker-2 dies. t+2.100s
broker-2 was killed at 2000 ms. The record it wrote is in object storage and committed in PostgreSQL, so nothing has to be copied or caught up: Inkless keeps no committed data on the broker that another broker needs (broker-2's write buffer was empty when it died). What is lost is broker-2's in-memory cache, and az-b has no broker left.
Open at this step: step 2, broker-2 diesClients fall back to another zone, reading from object storage. t+2.550s
With no broker in az-b, the clients are sent to a broker in another zone, as Inkless's docs describe: p1's next record went to broker-3 in az-c at 2250 ms, a cross-AZ write. g1 polled at 2500 ms and was served by broker-3 too, which had nothing cached, so it read the object from object storage (remote read) and now caches it. Which zone's broker takes over comes from the simulator's own hash.
Open at this step: step 3, Clients fall back to another zone, reading from object storagebroker-2 back, cache empty. t+5.050s
broker-2 restarted at 4500 ms and az-b clients are routed to it again. g1's next read at 5000 ms was for the record written through broker-3 while broker-2 was down, so broker-2 had to read it from object storage (remote read) and cache it. Its cache was empty anyway: it did not survive the restart.
Open at this step: step 4, broker-2 back, cache emptyWrites back in az-b. t+6.900s
p1's next record went to broker-2 again and was committed at 6810 ms. Over the whole run nothing was copied between brokers; the cost of the failure was a cold cache on each broker that took over and, while az-b had no broker, traffic across zones.
Open at this step: step 5, Writes back in az-bWhat you start with
In Inkless any broker can serve any diskless partition, and a client that names its zone in client.id is sent to a broker in that zone. A producer and a consumer group in az-b use broker-2, the only broker there. broker-2 will die. Watch the WAL counters, the remote reads and the cross-AZ count.
Step by step
- Written through broker-2 t+1.400s p1 is in az-b, so its record went to broker-2, the only az-b broker, and was committed by PostgreSQL at 1310 ms. broker-2 keeps the committed range in its cache. The consumer group g1, also in az-b, has not polled yet. Open at this step: step 1, Written through broker-2
- broker-2 dies t+2.100s broker-2 was killed at 2000 ms. The record it wrote is in object storage and committed in PostgreSQL, so nothing has to be copied or caught up: Inkless keeps no committed data on the broker that another broker needs (broker-2's write buffer was empty when it died). What is lost is broker-2's in-memory cache, and az-b has no broker left. Open at this step: step 2, broker-2 dies
- Clients fall back to another zone, reading from object storage t+2.550s With no broker in az-b, the clients are sent to a broker in another zone, as Inkless's docs describe: p1's next record went to broker-3 in az-c at 2250 ms, a cross-AZ write. g1 polled at 2500 ms and was served by broker-3 too, which had nothing cached, so it read the object from object storage (remote read) and now caches it. Which zone's broker takes over comes from the simulator's own hash. Open at this step: step 3, Clients fall back to another zone, reading from object storage
- broker-2 back, cache empty t+5.050s broker-2 restarted at 4500 ms and az-b clients are routed to it again. g1's next read at 5000 ms was for the record written through broker-3 while broker-2 was down, so broker-2 had to read it from object storage (remote read) and cache it. Its cache was empty anyway: it did not survive the restart. Open at this step: step 4, broker-2 back, cache empty
- Writes back in az-b t+6.900s p1's next record went to broker-2 again and was committed at 6810 ms. Over the whole run nothing was copied between brokers; the cost of the failure was a cold cache on each broker that took over and, while az-b had no broker, traffic across zones. Open at this step: step 5, Writes back in az-b
The takeaway
Nothing had to be copied or caught up: the records were in object storage. With az-b empty the clients fell back to another zone, which Inkless's docs describe, and paid cross-AZ traffic; the new broker had nothing cached, so its first read went to object storage. broker-2 came back with an empty cache, because the cache lives in memory. Simulator choice: the fallback broker comes from the simulator's own hash.
Configs in this scenario
-
client.A logical name the producer sends with every request - it shows up in broker logs, metrics, and quota enforcement so traffic can be attributed to an application.id
Embed this scenario
Paste this into a blog post, a course page or your team's docs. The scenario plays inside your page, and the link under it points readers to this walkthrough.
<iframe src="https://monedula.dev/kafka-simulator/embed/?scenario=07.1.3" title="Kafka Simulator: Inkless: a broker dies" width="100%" height="520" style="border:1px solid #d0d0d0;border-radius:8px" loading="lazy" referrerpolicy="no-referrer-when-downgrade"></iframe>
<p><a href="https://monedula.dev/kafka-simulator/scenarios/inkless-broker-failure/">Aiven Inkless: what losing a Kafka broker costs</a></p> Further reading
Aiven Inkless source on GitHub (inkless-release-0.51)
More in Diskless
- Diskless Kafka topics (KIP-1163): the write path
- Diskless vs classic Kafka: cross-AZ replication traffic
- Diskless Kafka produce latency: the price of object storage
- Diskless Kafka (KIP-1163): when object storage goes down
- Aiven Inkless diskless Kafka: the write path
- Aiven Inkless: what a PostgreSQL outage does to Kafka
- Aiven Inkless: a slow S3 bucket fails Kafka produce
- KafScale diskless Kafka: etcd lease, S3 segment, ack
- KafScale 2.1 diskless Kafka: a lease owner crashes
- KafScale 2.1 diskless Kafka: when etcd goes down
- KafScale 2.1 diskless Kafka: when S3 goes down
- KafScale 2.1 proxy: etcd down past the 60 s cache TTL
- KafScale 2.1: a Kafka producer timeout that still wrote
- KafScale 2.1 diskless Kafka: lease handover, no overwrite
- KafScale 2.1 diskless Kafka: a paused broker comes back
- AutoMQ diskless Kafka: one S3 WAL per broker, then ack
- AutoMQ diskless Kafka: a broker crash and WAL failover
- AutoMQ diskless Kafka: moving a partition, no copying
- AutoMQ diskless Kafka: zone router, no cross-zone data
- AutoMQ diskless Kafka: when S3 goes down
- WarpStream diskless Kafka: the write path through Agents
- WarpStream Kafka: a leader per client, a cache per zone
- WarpStream Kafka: an Agent dies mid-commit
- WarpStream Kafka: the control plane goes down
- WarpStream Kafka Ripcord: produce without the control plane
- WarpStream Kafka lightning topics: ack before the commit
- WarpStream Kafka transactions in the control plane
- Redpanda Kafka write path: the offset comes after S3
- Redpanda Kafka leader crash: a Raft election, no replay
- Redpanda Kafka S3 outage: uploads time out, Raft holds
- Redpanda Kafka L0 to L1: the LRO and who serves a read
- Redpanda Kafka transactions: exactly-once on Cloud Topics
- Nisshi diskless Kafka: watermark.json, then the batch
- Nisshi diskless Kafka on PostgreSQL: a row lock per write
- Nisshi diskless Kafka: two brokers write one partition
- Nisshi diskless Kafka: reading through another broker
- Nisshi diskless Kafka: a broker dies mid-write
- Nisshi diskless Kafka: when PostgreSQL goes down
- Nisshi diskless Kafka: what 0.8.2 refuses
- Ursa for Kafka write path: Oxia assigns the offset
- Ursa for Kafka zones: the zonal owner and the zone cache
- Ursa for Kafka compaction: from WAL objects to Parquet
- Ursa for Kafka broker failure: a kill and a silent broker
- Ursa for Kafka: diskless and disk topics, side by side