nerdexam
Confluent

CCDAK · Question #3

A consumer application is using KafkaAvroDeserializer to deserialize Avro messages. What happens if message schema is not present in AvroDeserializer local cache?

The correct answer is D. Fetches schema from Schema Registry. First local cache is checked for the message schema. In case of cache miss, schema is pulled from the schema registry. An exception will be thrown in the Schema Registry does not have the schema (which should never happen if you set it up properly)

Developing Kafka Consumers

Question

A consumer application is using KafkaAvroDeserializer to deserialize Avro messages. What happens if message schema is not present in AvroDeserializer local cache?

Options

  • AThrows SerializationException
  • BFails silently
  • CThrows DeserializationException
  • DFetches schema from Schema Registry

How the community answered

(18 responses)
  • A
    6% (1)
  • D
    94% (17)

Explanation

First local cache is checked for the message schema. In case of cache miss, schema is pulled from the schema registry. An exception will be thrown in the Schema Registry does not have the schema (which should never happen if you set it up properly)

Topics

#KafkaAvroDeserializer#Schema Registry#schema cache#Avro deserialization

Community Discussion

No community discussion yet for this question.

Full CCDAK Practice