You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/11/15 13:34:59 UTC
[jira] [Commented] (KAFKA-1548) Refactor the "replica_id" in
requests
[ https://issues.apache.org/jira/browse/KAFKA-1548?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15667147#comment-15667147 ]
ASF GitHub Bot commented on KAFKA-1548:
---------------------------------------
GitHub user baluchicken opened a pull request:
https://github.com/apache/kafka/pull/2137
KAFKA-1548 Refactor the "replica_id" in requests
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/baluchicken/kafka-1 KAFKA-1548
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/kafka/pull/2137.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 #2137
----
commit 4e55654c288fa18ad294796b5d58c5bc8e198ccc
Author: Balint Molnar <ba...@gmail.com>
Date: 2016-11-15T13:27:09Z
KAFKA-1548 Refactor the "replica_id" in requests
----
> Refactor the "replica_id" in requests
> -------------------------------------
>
> Key: KAFKA-1548
> URL: https://issues.apache.org/jira/browse/KAFKA-1548
> Project: Kafka
> Issue Type: Bug
> Reporter: Guozhang Wang
> Assignee: Balint Molnar
> Labels: newbie
> Fix For: 0.10.2.0
>
>
> Today in many requests like fetch and offset we have a integer replica_id field, if the request is from a follower consumer it is the broker id from that follower replica, if it is from a regular consumer it could be one of the two values: "-1" for ordinary consumer, or "-2" for debugging consumer.
> Hence this replica_id field is used in two folds:
> 1) Logging for trouble shooting in request logs, which can be helpful only when this is from a follower replica,
> 2) Deciding if it is from the consumer or a replica to logically handle the request in different ways. For this purpose we do not really care about the actually id value.
> We probably would like to do the following improvements:
> 1) Rename "replica_id" to sth. less confusing?
> 2) Change the request.toString() function based on the replica_id, whether it is a positive integer (meaning from a broker replica fetcher) or -1/-2 (meaning from a regular consumer).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)