davsclaus commented on a change in pull request #4815: URL: https://github.com/apache/camel/pull/4815#discussion_r548423651
########## File path: catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/kafka-component.adoc ########## @@ -580,3 +580,23 @@ from("kafka:my_topic?headerFilterStrategy=#myStrategy") `myStrategy` object should be subclass of `HeaderFilterStrategy` and must be placed in the Camel registry, either manually or by registration as a bean in Spring/Blueprint, as it is `CamelContext` aware. include::camel-spring-boot::page$kafka-starter.adoc[] + +== Consuming Avro messages from Kafka using the schema-registry +*Since Camel 3.0.0* + +This route applies the schema and converts the Avro messages to POJOs for further processing: + +[source,java] +---- +from(kafka("avro-events") + .brokers("localhost:9092") + .schemaRegistryURL("http://localhost:8081") + .specificAvroReader(true) + .valueDeserializer("io.confluent.kafka.serializers.KafkaAvroDeserializer") Review comment: Is it only confluent that has avra deseriazlier and this implies you are using confluent schema registry. Can we make this example also work with other schema registries? And add some more notes on this? And btw the example is using endpoint-dsl which we should mention. ########## File path: catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/kafka-component.adoc ########## @@ -580,3 +580,23 @@ from("kafka:my_topic?headerFilterStrategy=#myStrategy") `myStrategy` object should be subclass of `HeaderFilterStrategy` and must be placed in the Camel registry, either manually or by registration as a bean in Spring/Blueprint, as it is `CamelContext` aware. include::camel-spring-boot::page$kafka-starter.adoc[] + +== Consuming Avro messages from Kafka using the schema-registry +*Since Camel 3.0.0* + +This route applies the schema and converts the Avro messages to POJOs for further processing: + +[source,java] +---- +from(kafka("avro-events") + .brokers("localhost:9092") + .schemaRegistryURL("http://localhost:8081") + .specificAvroReader(true) + .valueDeserializer("io.confluent.kafka.serializers.KafkaAvroDeserializer") + .resolve(getContext())) Review comment: You would not call resolve when using endpoint-dsl creating routes ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org