What is accomplished by producing data to a topic with a message key?
A.
Messages with the same key are routed to a deterministically selected partition, enabling order guarantees within that partition.
B.
Kafka brokers allow you to add more partitions to a given topic, without impacting the data flow for existing keys.
C.
It provides a mechanism for encrypting messages at the partition level to ensure secure data transmission.
D.
Consumers can filter messages in real time based on the message key without processing unrelated messages.
The Answer Is:
A
This question includes an explanation.
Explanation:
When a message key is specified in Kafka, the producer uses a partitioner (typically the default hash-based partitioner) to deterministically map all records with the same key to the same partition. Kafka guarantees order within a partition, so this enables per-key ordering.
From Kafka Producer Concepts:
“If a key is present, the producer will always route records with the same key to the same partition. Kafka preserves the order of records within a partition.”
This is essential for ordered processing and join semantics.
[Reference: Kafka Producer Design > Partitions and Keys, ============, ]
CCDAK PDF/Engine
Printable Format
Value of Money
100% Pass Assurance
Verified Answers
Researched by Industry Experts
Based on Real Exams Scenarios
100% Real Questions
Get 65% Discount on All Products,
Use Coupon: "ac4s65"