From 9c8aa5ad52c2c697aa46fd8b31438e61d650eb07 Mon Sep 17 00:00:00 2001 From: tmdiep Date: Thu, 8 Jul 2021 11:02:06 +1000 Subject: [PATCH] docs(pubsublite): recommendation for timeout settings (#4389) --- pubsublite/pscompat/settings.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pubsublite/pscompat/settings.go b/pubsublite/pscompat/settings.go index 1e5b98e53d0..59b84c84556 100644 --- a/pubsublite/pscompat/settings.go +++ b/pubsublite/pscompat/settings.go @@ -73,6 +73,8 @@ type PublishSettings struct { // details of the last error that occurred while trying to reconnect to // backends. Note that if the timeout duration is long, ErrOverflow may occur // first. + // + // It is not recommended to set Timeout below 2 minutes. Timeout time.Duration // The maximum number of bytes that the publisher will keep in memory before @@ -191,6 +193,8 @@ type ReceiveSettings struct { // exceeded, the SubscriberClient will terminate with ErrBackendUnavailable // and details of the last error that occurred while trying to reconnect to // backends. + // + // It is not recommended to set Timeout below 2 minutes. Timeout time.Duration // The topic partition numbers (zero-indexed) to receive messages from.