org.apache.kafka.connect.errors.DataException

Converting byte[] to Kafka Connect data failed due to serialization error:


Samebug tips4

If you're using Java Chronicle it might be a Cleanup problem. Either add @ignore to the test or delete the memory map file and do it again.

If you're using Facebook API, they now use OAuth2, so your URL should contain version number, like this:
facebook.authorizationURL="https://graph.facebook.com/v2.3/oauth/authorize"

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.


Solutions on the web57

Solution icon of github
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
via GitHub by tony-lijinwen
, 1 year ago
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of googlegroups
via Google Groups by Nishant Verma, 7 months ago
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of stackoverflow
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
via GitHub by xiabai84
, 4 months ago
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
via GitHub by pawan-kmr
, 2 months ago
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
via GitHub by camelia-c
, 11 months ago
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
Converting byte[] to Kafka Connect data failed due to serialization error:

Solution icon of github
Converting byte[] to Kafka Connect data failed due to serialization error:

Stack trace

  • org.apache.kafka.connect.errors.DataException: Converting byte[] to Kafka Connect data failed due to serialization error: at org.apache.kafka.connect.json.JsonConverter.toConnectData(JsonConverter.java:305) at org.apache.kafka.connect.runtime.WorkerSinkTask.convertMessages(WorkerSinkTask.java:358) at org.apache.kafka.connect.runtime.WorkerSinkTask.poll(WorkerSinkTask.java:239) at org.apache.kafka.connect.runtime.WorkerSinkTask.iteration(WorkerSinkTask.java:172) at org.apache.kafka.connect.runtime.WorkerSinkTask.execute(WorkerSinkTask.java:143) at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:140) at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:175) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.apache.kafka.common.errors.SerializationException: com.fasterxml.jackson.core.JsonParseException: Unrecognized character escape 'x' (code 120) at [Source: [B@aa4d27a; line: 1, column: 106] Caused by: com.fasterxml.jackson.core.JsonParseException: Unrecognized character escape 'x' (code 120) at [Source: [B@aa4d27a; line: 1, column: 106] at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1581) at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:533) at com.fasterxml.jackson.core.base.ParserMinimalBase._handleUnrecognizedCharacterEscape(ParserMinimalBase.java:510) at com.fasterxml.jackson.core.json.UTF8StreamJsonParser._decodeEscaped(UTF8StreamJsonParser.java:3174) at com.fasterxml.jackson.core.json.UTF8StreamJsonParser._finishString2(UTF8StreamJsonParser.java:2459) at com.fasterxml.jackson.core.json.UTF8StreamJsonParser._finishAndReturnString(UTF8StreamJsonParser.java:2414) at com.fasterxml.jackson.core.json.UTF8StreamJsonParser.getText(UTF8StreamJsonParser.java:285) at com.fasterxml.jackson.databind.deser.std.BaseNodeDeserializer.deserializeObject(JsonNodeDeserializer.java:233) at com.fasterxml.jackson.databind.deser.std.JsonNodeDeserializer.deserialize(JsonNodeDeserializer.java:69) at com.fasterxml.jackson.databind.deser.std.JsonNodeDeserializer.deserialize(JsonNodeDeserializer.java:15) at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:3736) at com.fasterxml.jackson.databind.ObjectMapper.readTree(ObjectMapper.java:2294) at org.apache.kafka.connect.json.JsonDeserializer.deserialize(JsonDeserializer.java:50) at org.apache.kafka.connect.json.JsonConverter.toConnectData(JsonConverter.java:303) at org.apache.kafka.connect.runtime.WorkerSinkTask.convertMessages(WorkerSinkTask.java:358) at org.apache.kafka.connect.runtime.WorkerSinkTask.poll(WorkerSinkTask.java:239) at org.apache.kafka.connect.runtime.WorkerSinkTask.iteration(WorkerSinkTask.java:172) at org.apache.kafka.connect.runtime.WorkerSinkTask.execute(WorkerSinkTask.java:143) at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:140) at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:175) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Once, 1 month ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Once, 15 hours ago
60 times, 1 day ago
111 more bugmates