-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Description
Discussed in #2837
Originally posted by ccrafael October 11, 2023
Actually in the class org.springframework.kafka.support.serializer.JsonDeserializer when an error happen it is handled like this:
catch (IOException e) {
throw new SerializationException("Can't deserialize data [" + Arrays.toString(data) +
"] from topic [" + topic + "]", e);
}
which I think is very inefficient as each byte of the payload is duplicated as a long array of numbers written as a String in the exception message. In my humble opinion the Arrays.toString(data) should be removed from the message and the original data[] object should be added to the SerializationException class.