From b6d9bd7c38d4fe597c25b7b5869fd4a1259c7687 Mon Sep 17 00:00:00 2001 From: dpcollins-google <40498610+dpcollins-google@users.noreply.github.com> Date: Tue, 10 Nov 2020 13:02:21 -0500 Subject: [PATCH] docs: document potentially unexpected blocking behavior of publish() method (#214) * docs: Document potentially unexpected blocking behavior of publish() method. * Update google/cloud/pubsub_v1/publisher/client.py Co-authored-by: Tres Seaver Co-authored-by: Prad Nelluru --- google/cloud/pubsub_v1/publisher/client.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/google/cloud/pubsub_v1/publisher/client.py b/google/cloud/pubsub_v1/publisher/client.py index f1de9f1f4..6a9418e69 100644 --- a/google/cloud/pubsub_v1/publisher/client.py +++ b/google/cloud/pubsub_v1/publisher/client.py @@ -291,6 +291,8 @@ def publish( Add the given message to this object; this will cause it to be published once the batch either has enough messages or a sufficient period of time has elapsed. + This method may block if LimitExceededBehavior.BLOCK is used in the + flow control settings. Example: >>> from google.cloud import pubsub_v1