All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.quarkus.kafka.client.serialization.JsonObjectDeserializer Maven / Gradle / Ivy

There is a newer version: 3.17.5
Show newest version
package io.quarkus.kafka.client.serialization;

import org.apache.kafka.common.serialization.Deserializer;

import io.vertx.core.buffer.Buffer;
import io.vertx.core.json.JsonObject;

/**
 * Kafka deserializer for raw bytes in a buffer
 */
public class JsonObjectDeserializer implements Deserializer {

    @Override
    public JsonObject deserialize(String topic, byte[] data) {
        if (data == null)
            return null;

        return Buffer.buffer(data).toJsonObject();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy