Want to use kafka with serializerClass ByteArraySerializer

Solution Verified - Updated -

Issue

  • ByteArraySerializer is not available in Apache ServiceMix :: Bundles :: kafka_2.10 where it seems to be going to look for the class.
  • Error received
JBossFuse:admin@test> log:display-exception
org.apache.camel.FailedToCreateProducerException: Failed to create Producer for endpoint: Endpoint[kafka://10.0.2.13:9092?keySerializerClass=org.apache.kafka.common.serialization.StringSerializer&serializerClass=org.apache.kafka.common.serialization.ByteArraySerializer&topic=avroTest]. Reason: java.lang.ClassNotFoundException: org.apache.kafka.common.serialization.ByteArraySerializer not found by org.apache.servicemix.bundles.kafka_2.10 [152]
        at org.apache.camel.impl.ProducerCache.doGetProducer(ProducerCache.java:407)[129:org.apache.camel.camel-core:2.15.1.redhat-621177]
        at org.apache.camel.impl.ProducerCache.acquireProducer(ProducerCache.java:123)[129:org.apache.camel.camel-core:2.15.1.redhat-621177]

Environment

  • Red Hat JBoss Fuse
    • 6.3.0

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.