-
Notifications
You must be signed in to change notification settings - Fork 798
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Check for broker existence when forming partition replica and ISR lis…
…ts (#776) Data for each partition returned by Conn.ReadPartitions includes the list of replicas and the ISR for the partition. The broker data is copied from the list of currently available brokers, retrieved from Kafka metadata. It can happen that a broker is not present in metadata (due to being down, for example), but still listed as a replica for a partition. (For example, broker 2 may be down but the ID 2 can still be listed as a replica for a partition.) The logic that copies broker data from the list of available brokers into partition data now omits any that are not present in the metadata list. Without this change, partition data receives the copy of a nil object in its replica or ISR list (ID 0, host nil, default port 9092), which is useless.
- Loading branch information
Showing
2 changed files
with
46 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters