Class ObjectMapperSerializer<T>
- java.lang.Object
-
- io.quarkus.kafka.client.serialization.ObjectMapperSerializer<T>
-
- All Implemented Interfaces:
Closeable,AutoCloseable,org.apache.kafka.common.serialization.Serializer<T>
public class ObjectMapperSerializer<T> extends Object implements org.apache.kafka.common.serialization.Serializer<T>
ADeserializerthat deserializes JSON using Jackson's ObjectMapper.
-
-
Constructor Summary
Constructors Constructor Description ObjectMapperSerializer()ObjectMapperSerializer(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()voidconfigure(Map<String,?> configs, boolean isKey)byte[]serialize(String topic, T data)
-
-
-
Method Detail
-
configure
public void configure(Map<String,?> configs, boolean isKey)
- Specified by:
configurein interfaceorg.apache.kafka.common.serialization.Serializer<T>
-
serialize
public byte[] serialize(String topic, T data)
- Specified by:
serializein interfaceorg.apache.kafka.common.serialization.Serializer<T>
-
close
public void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceorg.apache.kafka.common.serialization.Serializer<T>
-
-