Skip to content

Commit 57713b5

Browse files
committed
update comments in group_balancer
1 parent 7f7b992 commit 57713b5

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

consumergroup.go

-1
Original file line numberDiff line numberDiff line change
@@ -1122,7 +1122,6 @@ func (cg *ConsumerGroup) makeSyncGroupRequestV0(memberID string, generationID in
11221122
}
11231123

11241124
balancer, _ := findGroupBalancer(strategy, cg.config.GroupBalancers)
1125-
11261125
if memberAssignments != nil {
11271126
request.GroupAssignments = make([]syncGroupRequestGroupAssignmentV0, 0, 1)
11281127

groupbalancer.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -29,19 +29,19 @@ type GroupMemberAssignments map[string]map[string][]int
2929

3030
// GroupBalancer encapsulates the client side rebalancing logic.
3131
type GroupBalancer interface {
32-
// ProtocolName of the GroupBalancer.
32+
// ProtocolName of the GroupBalance
3333
ProtocolName() string
3434

3535
// UserData provides the GroupBalancer an opportunity to embed custom
3636
// UserData into the metadata.
3737
//
3838
// Will be used by JoinGroup to begin the consumer group handshake.
3939
//
40-
// See https://cwiki.apache.org/confluence/display/KAFKA/A+Guide+To+The+Kafka+Protocol#AGuideToTheKafkaProtocol-JoinGroupRequest .
40+
// See https://cwiki.apache.org/confluence/display/KAFKA/A+Guide+To+The+Kafka+Protocol#AGuideToTheKafkaProtocol-JoinGroupRequest
4141
UserData(memberID string, topics map[string][]int32, generationID int32) ([]byte, error)
4242

4343
// DefineMemberships returns which members will be consuming
44-
// which topic partitions.
44+
// which topic partitions
4545
AssignGroups(members []GroupMember, partitions []Partition) GroupMemberAssignments
4646
}
4747

groupbalancer_test.go

-4
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@ import (
1313
"time"
1414
)
1515

16-
// func TestRandom(t *testing.T) {
17-
// panic("kdvfnvjfnmfckdvnfjkv gf bghb hgb kgmbmtkmb kytmbnynmky nm")
18-
// }
19-
2016
func TestFindMembersByTopic(t *testing.T) {
2117
a1 := GroupMember{
2218
ID: "a",

0 commit comments

Comments
 (0)