--
You received this message because you are subscribed to the Google Groups "Confluent Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platf...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/ff546bff-79ee-43f1-952d-9d6e89f031e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi Kevin,You need to provide the value-schema as a command line parameter in kafka-avro-console-consumer. The quickstart of the confluent documentation constains some example (http://docs.confluent.io/2.0.1/quickstart.html). There are more information here http://docs.confluent.io/2.0.1/schema-registry/docs/serializer-formatter.html on serializers and formatters.Thanks,Liquan
On Wed, Apr 13, 2016 at 4:25 PM, Kevin Hutson <mrj...@gmail.com> wrote:
We are new to the schema registry, so I hope this isn't a dumb question.Our Kafka producer is using io.confluent.kafka.serializers.KafkaAvroEncoder as the value serializer (value.serializer). But, we aren't using it for the key. This means we end up with a schema for the message (subject=MYTOPIC-value) but not for the key. It's just plain text.From the Java API, I can consume messages for this topic and see both the message and the key. It talks to the schema registry fine.From kafka-avro-console-consumer, I can see the messages if I don't ask it to print the key.But, If I try to consume with the kafka-avro-console-consumer tool, it throws an exception if I try to print the key (--property print.key=true)../kafka-avro-console-consumer --zookeeper local.docker:2181 --topic MYTOPIC --from-beginning --property schema.registry.url=http://local.docker:8081 --property print.key=trueProcessed a total of 1 messages[2016-04-13 18:17:46,989] ERROR Unknown error when running consumer: (kafka.tools.ConsoleConsumer$:103)org.apache.kafka.common.errors.SerializationException: Error deserializing Avro message for id -1Caused by: org.apache.kafka.common.errors.SerializationException: Unknown magic byte!Is this because the kafka-avro-console-consumer tool expects both the key and value to have schemas?If so, will POSTing the key as a simple String be sufficient. At this time, our key is just a String.That would mean we would need to set key.serializer to io.confluent.kafka.serializers.KafkaAvroEncoder?thank you!Kevin Hutson
--
You received this message because you are subscribed to the Google Groups "Confluent Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platform+unsub...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/ff546bff-79ee-43f1-952d-9d6e89f031e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi Liquan ,
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platf...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/ff546bff-79ee-43f1-952d-9d6e89f031e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Liquan Pei | Software Engineer | Confluent | +1 413.230.6855Download Apache Kafka and Confluent Platform: www.confluent.io/download
--
You received this message because you are subscribed to the Google Groups "Confluent Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platf...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/bdfdcffd-edae-4a46-a6bc-85ac69888e09%40googlegroups.com.
Hi Liquan ,
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platform+unsub...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/ff546bff-79ee-43f1-952d-9d6e89f031e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Liquan Pei | Software Engineer | Confluent | +1 413.230.6855Download Apache Kafka and Confluent Platform: www.confluent.io/download
--
You received this message because you are subscribed to the Google Groups "Confluent Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to confluent-platform+unsub...@googlegroups.com.
To post to this group, send email to confluent...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/confluent-platform/bdfdcffd-edae-4a46-a6bc-85ac69888e09%40googlegroups.com.