[ https://issues.apache.org/jira/browse/KAFKA-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13967666#comment-13967666 ]
Joel Koshy commented on KAFKA-1355: ----------------------------------- Tim's patch in 1363 conflicts with this. So we can get 1363 in first, and I will rebase this one. > Reduce/optimize update metadata requests sent during leader election > -------------------------------------------------------------------- > > Key: KAFKA-1355 > URL: https://issues.apache.org/jira/browse/KAFKA-1355 > Project: Kafka > Issue Type: Bug > Affects Versions: 0.8.1 > Reporter: Joel Koshy > Priority: Critical > Fix For: 0.8.1.1 > > Attachments: KAFKA-1355.patch, KAFKA-1355_2014-04-04_13:48:34.patch, > KAFKA-1355_2014-04-04_13:51:22.patch > > > This is part of the investigation into slow shutdowns in 0.8.1. While > logging contributes to bulk of the regression, this one also adds > quite a bit of overhead: > In addLeaderAndIsrRequest (called for every partition that is led by the > broker being shut down) we also add an UpdateMetadataRequest - each call to > addUpdateMetadataRequests does two traversals over _all_ (global) > partitions. I think it should be straightforward to optimize this a bit. > Marking as critical, since it is not as big an overhead as the logging. -- This message was sent by Atlassian JIRA (v6.2#6252)