|
|
@@ -432,6 +432,9 @@ func (client *Client) cachedLeader(topic string, partitionID int32) (*Broker, er
|
|
|
if partitions != nil {
|
|
|
metadata, ok := partitions[partitionID]
|
|
|
if ok {
|
|
|
+ if metadata.Err == LeaderNotAvailable {
|
|
|
+ return nil, LeaderNotAvailable
|
|
|
+ }
|
|
|
b := client.brokers[metadata.Leader]
|
|
|
if b == nil {
|
|
|
return nil, LeaderNotAvailable
|