nerdexam
Confluent

CCAAK · Question #116

You have a cluster with a topic t1 that already has uncompressed messages. A new Producer starts sending messages to t1 with compression enabled. Which condition would allow this?

The correct answer is A. If the new Producer is configured to use compression. Kafka allows mixed compression formats within the same topic and even the same partition. Each message batch includes metadata indicating whether and how it is compressed. Therefore, a new producer can send compressed messages to a topic that already contains uncompressed…

Apache Kafka Fundamentals

Question

You have a cluster with a topic t1 that already has uncompressed messages. A new Producer starts sending messages to t1 with compression enabled. Which condition would allow this?

Options

  • AIf the new Producer is configured to use compression.
  • BNever, because topic t1 already has uncompressed messages.
  • COnly if Kafka is also enabled for encryption.
  • DOnly if the new Producer disables batching.

How the community answered

(18 responses)
  • A
    72% (13)
  • B
    17% (3)
  • C
    6% (1)
  • D
    6% (1)

Explanation

Kafka allows mixed compression formats within the same topic and even the same partition. Each message batch includes metadata indicating whether and how it is compressed. Therefore, a new producer can send compressed messages to a topic that already contains uncompressed messages, as long as it is configured with a compression codec (e.g., compression.type=gzip,

Topics

#producer compression#message compression#topic compression#producer configuration

Community Discussion

No community discussion yet for this question.

Full CCAAK Practice