You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Xin Wang (JIRA)" <ji...@apache.org> on 2016/03/15 04:21:33 UTC

[jira] [Updated] (KAFKA-3398) avoid just sending to one partition when record key is empty string

     [ https://issues.apache.org/jira/browse/KAFKA-3398?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Xin Wang updated KAFKA-3398:
----------------------------
    Description: Now the DefaultPartitioner, if record key==null, choose a partition in a round-robin fashion; else choose a partition based on a hash of the key. But the producer will just send messages to one partition(partition index is 1) when key is an empty string "". We can add a check to avoid this.

> avoid just sending to one partition when record key is empty string
> -------------------------------------------------------------------
>
>                 Key: KAFKA-3398
>                 URL: https://issues.apache.org/jira/browse/KAFKA-3398
>             Project: Kafka
>          Issue Type: Bug
>          Components: clients
>            Reporter: Xin Wang
>
> Now the DefaultPartitioner, if record key==null, choose a partition in a round-robin fashion; else choose a partition based on a hash of the key. But the producer will just send messages to one partition(partition index is 1) when key is an empty string "". We can add a check to avoid this.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)