All jobs / Backend developer / Distributed Systems

Backend developer interview question · 3–5 years

Order-status events for the same order are arriving out of order at the consumer. The topic has twelve partitions.

Why, and what do you change?

The strongest answer

Ordering only holds within a partition and these events were spread across twelve — key them by order id, so every event for one order lands on the same partition and one consumer reads them in sequence

Why it works

Exactly — the key picks the partition and the partition is the ordering unit. It also sets your parallelism ceiling.

What a good answer covers

Answers that fall short

Who gets asked this

More Distributed Systems questions