Discovery Nano the light version.
This commit is contained in:
@@ -203,6 +203,9 @@ func waitResults[T interface{}](topic *pubsub.Topic, s *LongLivedPubSubService,
|
||||
if errors.Is(err, context.DeadlineExceeded) {
|
||||
// timeout hit, no message before deadline kill subsciption.
|
||||
s.PubsubMu.Lock()
|
||||
if s.LongLivedPubSubs[proto] != nil {
|
||||
s.LongLivedPubSubs[proto].Close()
|
||||
}
|
||||
delete(s.LongLivedPubSubs, proto)
|
||||
s.PubsubMu.Unlock()
|
||||
return
|
||||
@@ -214,6 +217,5 @@ func waitResults[T interface{}](topic *pubsub.Topic, s *LongLivedPubSubService,
|
||||
continue
|
||||
}
|
||||
f(ctx, evt, fmt.Sprintf("%v", proto))
|
||||
fmt.Println("DEADLOCK ?")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user