[
https://issues.apache.org/jira/browse/KAFKA-2268?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14643573#comment-14643573
]
Xuan Gong commented on KAFKA-2268:
----------------------------------
Looks like this is duplicate with
https://issues.apache.org/jira/browse/KAFKA-2289
> New producer logs WARN if serializer supplied directly to constructor
> ---------------------------------------------------------------------
>
> Key: KAFKA-2268
> URL: https://issues.apache.org/jira/browse/KAFKA-2268
> Project: Kafka
> Issue Type: Bug
> Components: producer
> Affects Versions: 0.8.2.1
> Reporter: Morten Lied Johansen
> Assignee: Jun Rao
> Priority: Trivial
>
> When creating a new KafkaProducer by passing in a configuration-map, a key
> serializer and a value serializer, two warnings are logged:
> {noformat}
> [WARN ] [2015-06-15T14:26:36,271] The configuration value.serializer = class
> no.finntech.commons.kafka.ThriftSerializer was supplied but isn't a known
> config.
> [org.apache.kafka.common.config.AbstractConfig.logUnused(AbstractConfig.java:121)]
> [RMI TCP Connection(2)-127.0.0.1]
> [WARN ] [2015-06-15T14:26:36,271] The configuration key.serializer = class
> org.apache.kafka.common.serialization.StringSerializer was supplied but isn't
> a known config.
> [org.apache.kafka.common.config.AbstractConfig.logUnused(AbstractConfig.java:121)]
> [RMI TCP Connection(2)-127.0.0.1]
> {noformat}
> This happens because this constructor adds the serializers to the config
> (KafkaProducer.java:108), and then ignores that configuration since the
> instances are already present (KafkaProducer.java:215). Finally, it checks
> which parts of the configuration were used, and logs warnings for the
> remaining keys (KafkaProducer.java:230).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)