Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/libraries/go/worker/consumer/nats_consumer.go
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,6 @@ func fetchMax(ctx context.Context, consumer jetstream.Consumer, maxReq int64) (<
var msg jetstream.Msg
select {
case msg = <-activeFetch.Messages():
break
case <-ctx.Done():
// sure wish we could cancel fetches. best we can do is nack.
// TODO https://github.com/nats-io/nats.go/issues/1651
Expand All @@ -369,7 +368,6 @@ func fetchMax(ctx context.Context, consumer jetstream.Consumer, maxReq int64) (<
zap.L().Debug("message fetched", zap.String("consumer", consumer.CachedInfo().Name))
select {
case retChan <- msg:
break
case <-ctx.Done():
zap.L().Debug("nacking message due to closed context", zap.String("subject", msg.Subject()))
_ = msg.Nak()
Expand Down
Loading