You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Pushkar Deole <pd...@gmail.com> on 2020/05/15 09:30:18 UTC
topic input parameter in org.apache.kafka.common.serialization.Serializer
interface
Hi All,
I am writing a Json customer serializer for our customer objects, which
need to implement the Kafka Serializer interface.
I am wondering what the input parameter "topic" is in the
Serializer.serialize method.
I don't think it is the topic on which data is to be published. Please
correct me if I am wrong, and provide significance of this parameter.
Thanks.
Re: topic input parameter in
org.apache.kafka.common.serialization.Serializer interface
Posted by "Matthias J. Sax" <mj...@apache.org>.
It is the topic the record will be send to.
Most serializers ignore this parameter. If could be used to pick a
different serialization format for different topics.
-Matthias
On 5/15/20 2:30 AM, Pushkar Deole wrote:
> Hi All,
>
> I am writing a Json customer serializer for our customer objects, which
> need to implement the Kafka Serializer interface.
> I am wondering what the input parameter "topic" is in the
> Serializer.serialize method.
> I don't think it is the topic on which data is to be published. Please
> correct me if I am wrong, and provide significance of this parameter.
>
> Thanks.
>