Pradeep
Pradeep

Reputation: 149

Kafka org.apache.kafka.connect.converters.ByteArrayConverter doesn't work as values for key.converter and value.converter

I'm trying to build a pipeline where I have to move binary data from kafka topic to kinesis stream with out transforming. So I'm planning to use ByteArrayConverter for worker properties setup. But I'm getting the following error! Although I could see the ByteArrayConverter class in here

on 0.11.0 version. I cannot find the same class under 3.2.x :(

Any help would be much appreciated.

key.converter=io.confluent.connect.replicator.util.ByteArrayConverter value.converter=io.confluent.connect.replicator.util.ByteArrayConverter

Exception in thread "main" org.apache.kafka.common.config.ConfigException: Invalid value io.confluent.connect.replicator.util.ByteArrayConverter for configuration key.converter: Class io.confluent.connect.replicator.util.ByteArrayConverter could not be found.
    at org.apache.kafka.common.config.ConfigDef.parseType(ConfigDef.java:672)
    at org.apache.kafka.common.config.ConfigDef.parse(ConfigDef.java:418)
    at org.apache.kafka.common.config.AbstractConfig.<init>(AbstractConfig.java:55)
    at org.apache.kafka.common.config.AbstractConfig.<init>(AbstractConfig.java:62)
    at org.apache.kafka.connect.runtime.WorkerConfig.<init>(WorkerConfig.java:156)
    at org.apache.kafka.connect.runtime.distributed.DistributedConfig.<init>(DistributedConfig.java:198)
    at org.apache.kafka.connect.cli.ConnectDistributed.main(ConnectDistributed.java:65)

Upvotes: 1

Views: 4771

Answers (1)

Hans Jespersen
Hans Jespersen

Reputation: 8335

org.apache.kafka.connect.converters.ByteArrayConverter was only added to Apache Kafka 0.11 (which is Confluent 3.3). If you are running a Confluent distro earlier than 3.3 then you will need the Confluent Enterprise distro (not Confluent Open Source) and use the io.confluent.connect.replicator.util.ByteArrayConverter converter

Upvotes: 4

Related Questions