thirdparty package kafka updated to date

This commit is contained in:
John
2019-01-02 11:02:03 +08:00
parent d6aa2b2512
commit adf06a2b0d
98 changed files with 4670 additions and 1816 deletions

View File

@ -44,6 +44,7 @@ func NewAsyncProducer(t ErrorReporter, config *sarama.Config) *AsyncProducer {
defer func() {
close(mp.successes)
close(mp.errors)
close(mp.closed)
}()
for msg := range mp.input {
@ -86,8 +87,6 @@ func NewAsyncProducer(t ErrorReporter, config *sarama.Config) *AsyncProducer {
mp.t.Errorf("Expected to exhaust all expectations, but %d are left.", len(mp.expectations))
}
mp.l.Unlock()
close(mp.closed)
}()
return mp