diff --git a/pubsub/google/cloud/pubsub_v1/publisher/client.py b/pubsub/google/cloud/pubsub_v1/publisher/client.py index 8e878e1df764..c37b1cb80a64 100644 --- a/pubsub/google/cloud/pubsub_v1/publisher/client.py +++ b/pubsub/google/cloud/pubsub_v1/publisher/client.py @@ -34,7 +34,6 @@ @_gapic.add_methods(publisher_client.PublisherClient, blacklist=('publish',)) class Client(object): - _batch_class = thread.Batch """A publisher client for Google Cloud Pub/Sub. This creates an object that is capable of publishing messages. @@ -52,6 +51,8 @@ class Client(object): be added if ``credentials`` are passed explicitly or if the Pub / Sub emulator is detected as running. """ + _batch_class = thread.Batch + def __init__(self, batch_settings=(), **kwargs): # Sanity check: Is our goal to use the emulator? # If so, create a grpc insecure channel with the emulator host