Introduction
Kafka sends messages as pairs of keys and values. The key helps decide where the message goes, and the value is the actual data you want to send.
When you want to keep related messages together in the same order.
When you need to update or delete messages by key later.
When you want to balance load evenly across servers.
When you want to group messages by customer ID or session ID.
When you want to ensure messages with the same key go to the same place.