Skip to content

Commit

Permalink
Merge pull request #336 from karalabe/producer-log-tagging
Browse files Browse the repository at this point in the history
producer: fix shutdown logs to be uniform with others
  • Loading branch information
ploxiln authored Oct 20, 2021
2 parents 61df38e + c4f8b83 commit 54583b5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions producer.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ func (w *Producer) Stop() {
w.guard.Unlock()
return
}
w.log(LogLevelInfo, "stopping")
w.log(LogLevelInfo, "(%s) stopping", w.addr)
close(w.exitChan)
w.close()
w.guard.Unlock()
Expand Down Expand Up @@ -296,7 +296,7 @@ func (w *Producer) connect() error {
}

state := atomic.LoadInt32(&w.state)
switch {
switch {
case state == StateConnected:
return nil
case state != StateInit:
Expand Down Expand Up @@ -363,7 +363,7 @@ func (w *Producer) router() {
exit:
w.transactionCleanup()
w.wg.Done()
w.log(LogLevelInfo, "exiting router")
w.log(LogLevelInfo, "(%s) exiting router", w.conn.String())
}

func (w *Producer) popTransaction(frameType int32, data []byte) {
Expand Down

0 comments on commit 54583b5

Please sign in to comment.