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

ASF GitHub Bot commented on KAFKA-2763:
---------------------------------------

GitHub user ymatsuda opened a pull request:

    https://github.com/apache/kafka/pull/497

    KAFKA-2763: better stream task assignment

    @guozhangwang 
    
    When the rebalance happens each consumer reports the following information 
to the coordinator.
    * Client UUID (a unique id assigned to an instance of KafkaStreaming) 
    * Task ids of previously running tasks
    * Task ids of valid local states on the client's state directory
    
    TaskAssignor does the following
    * Assign a task to a client which was running it previously. If there is no 
such client, assign a task to a client which has its valid local state.
    * Try to balance the load among stream threads.
      * A client may have more than one stream threads. The assignor tries to 
assign tasks to a client proportionally to the number of threads.


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/ymatsuda/kafka task_assignment

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/kafka/pull/497.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #497
    
----
commit 0e4cd31d3f9f055aa8db5917bcb30f1dbc3da984
Author: Yasuhiro Matsuda <yasuh...@confluent.io>
Date:   2015-11-11T17:46:57Z

    better task assignment

----


> Reduce stream task migrations and initialization costs
> ------------------------------------------------------
>
>                 Key: KAFKA-2763
>                 URL: https://issues.apache.org/jira/browse/KAFKA-2763
>             Project: Kafka
>          Issue Type: Sub-task
>          Components: kafka streams
>    Affects Versions: 0.9.0.0
>            Reporter: Yasuhiro Matsuda
>
> Stream task assignment is not aware of either the previous task assignment or 
> local states of participating clients. By making the assignment logic aware 
> of them, we can reduce task migrations and initialization cost.



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

Reply via email to