Event ordering in Kafka: partition-level ordering vs global ordering
Elena Fernandez
·96 views
event ordering in kafka is always a fun one. we partition by `userId` to ensure order for user-specific events, which works well for things like 'item added to cart' then 'checkout completed'. but what about events that need global ordering? for example, an admin disabling an account. this event might affect multiple users or system-wide states and needs to be processed in a specific global sequence relative to other admin actions. trying to achieve cross-partition ordering feels like a huge headache, possibly involving re-partitioning or a single global partition which defeats the purpose of horizontal scaling. has anyone tackled global ordering requirements while still maintaining partitioned data for other use cases? what were the trade-offs and implementation challenges?
4 comments