This time for sure
This commit is contained in:
parent
d192e745c5
commit
b221d43f92
1 changed files with 0 additions and 3 deletions
|
@ -82,9 +82,6 @@ func (m *LocalPubSubMessage) ReceiveMessage(ctx context.Context) (*pubsub.Messag
|
|||
// A message has been received. Send it to the client.
|
||||
lib.LogInfo.Printf("\n[PUBSUB/LOCAL] Received message: %s\n", msg.Payload)
|
||||
return &msg, nil
|
||||
case <-time.After(30 * time.Second):
|
||||
// No message has been received for 30 seconds. Send a keep-alive message.
|
||||
return &pubsub.Message{Payload: "keep-alive"}, nil
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue