Multiple producer services publish Avro-encoded events to Azure Event Hubs. You need to validate payloads and evolve schemas without breaking existing consumers. Producers and consumers should automatically fetch and apply schema versions at runtime. What should you implement?
Choose an answer
Tap an option to check your answer.
Correct answer: Create an Event Hubs Schema Registry group with Backward compatibility, register the Avro schemas as versions, and use a Schema Registry–aware Avro serializer in producers and consumers to encode/decode payloads with schema IDs..
Why this is the answer
The correct option leverages Azure Event Hubs Schema Registry, which is designed precisely for this scenario. It allows you to register and version Avro schemas, ensuring backward compatibility. Producers and consumers use Schema Registry-aware serializers/deserializers that automatically fetch the correct schema version based on a schema ID embedded in the message, enabling seamless schema evolution without breaking existing consumers. Enabling JSON validation on the Event Hubs namespace is incorrect because the events are Avro-encoded, not JSON. Storing schemas in Azure App Configuration and versioning them manually would require custom logic for schema retrieval and application, which is less efficient and more error-prone than using the built-in Schema Registry. Emitting CloudEvents 1.0 via Event Grid doesn't inherently provide the Avro schema management and evolution capabilities required for Event Hubs payloads. Adding a custom message property with a schema URL also requires manual implementation for fetching and validation, lacking the automatic integration and compatibility guarantees of Schema Registry.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed