A Kafka topic can be splited into several parts which are known as the partitions of the topic. The partitioning is used to improve the scalability. Kafka breaks a topic into fractions and stores each of them in different nodes of its distributed system.
We can divide the topic into two different partitions to improve the performance and read from them on the consumer side.
A topic can be splited into several parts which are known as the partitions of the topic. We need to specify the number of partitions while creating a topic. The message/data stored into a partition with an incremental id known as its Offset value.
You need to decide which messages to write to which partitions because if message has no key, messages will be distributed round-robin among all the topic’s partitions.
In the next topic, you will understand about
Kafka Producer