[ 
https://issues.apache.org/jira/browse/KAFKA-902?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14359497#comment-14359497
 ] 

Jun Rao commented on KAFKA-902:
-------------------------------

Thanks for the patch. A few comments.

1. I feel that it's simpler to express jitter just as a percentage of the 
backoff. So the actual backoff will be backoff (1 + jitter-percent). This is 
simpler and it covers the case when backoff = 0 naturally, i.e., if backoff is 
0, no jitter is added. It's true that if the backoff is small, no jitter may be 
added. However, if backoff is really small, adding a small jitter may not 
spread the retries enough anyway.

2. We probably need to add jitter as a configuration. Should we add a single 
jitter config for all backoffs or one per backoff? Probably a single jitter 
config is enough.

3. On the broker side, we already have a config for log rolling jittter. It 
would be good to make the jitter implementation consistent. So, if we pick a 
new jitter strategy for the clients, we should use the same in the broker as 
well. This may mean that we will change some of the broker configs. This change 
will be of low impact, but we probably should file a KIP to keep everyone 
informed.

> Randomize backoff on the clients for metadata requests
> ------------------------------------------------------
>
>                 Key: KAFKA-902
>                 URL: https://issues.apache.org/jira/browse/KAFKA-902
>             Project: Kafka
>          Issue Type: Bug
>          Components: clients
>    Affects Versions: 0.8.0
>            Reporter: Neha Narkhede
>            Assignee: Geoffrey Anderson
>            Priority: Critical
>              Labels: newbie
>         Attachments: KAFKA-902.patch, KAFKA-902.patch
>
>
> If a Kafka broker dies and there are a large number of clients talking to the 
> Kafka cluster, each of the clients can end up shooting metadata requests at 
> around the same time. It is better to randomize the backoff on the clients so 
> the metadata requests are more evenly spread out



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

Reply via email to