Skip to content

Commit 91d5e2a

Browse files
chore(bigtable): added warning to MutationsBatcher (#18176)
Add warning to upgrade to MutationsBatcher docstrings, related to #18122
1 parent 23b9499 commit 91d5e2a

3 files changed

Lines changed: 21 additions & 0 deletions

File tree

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
Mutations Batching
22
~~~~~~~~~~~~~~~~~~
33

4+
.. warning::
5+
6+
If using ``MutationsBatcher``, please ensure you are using
7+
``google-cloud-bigtable >= 2.42.0``, or consider migrating to the
8+
batcher provided by the synchronous/asynchronous data client
9+
(:mod:`google.cloud.bigtable.data`).
10+
411
.. automodule:: google.cloud.bigtable.batcher
512
:members:
613
:show-inheritance:

packages/google-cloud-bigtable/google/cloud/bigtable/batcher.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,13 @@ class MutationsBatcher(object):
186186
187187
Note on thread safety: The same :class:`MutationBatcher` cannot be shared by multiple end-user threads.
188188
189+
.. warning::
190+
191+
If using ``MutationsBatcher``, please ensure you are using
192+
``google-cloud-bigtable >= 2.42.0``, or consider migrating to the
193+
batcher provided by the synchronous/asynchronous data client
194+
(:mod:`google.cloud.bigtable.data`).
195+
189196
:type table: class
190197
:param table: class:`~google.cloud.bigtable.table.Table`.
191198

packages/google-cloud-bigtable/google/cloud/bigtable/table.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -873,6 +873,13 @@ def mutations_batcher(
873873
:end-before: [END bigtable_api_mutations_batcher]
874874
:dedent: 4
875875
876+
.. warning::
877+
878+
If using ``MutationsBatcher``, please ensure you are using
879+
``google-cloud-bigtable >= 2.42.0``, or consider migrating to the
880+
batcher provided by the synchronous/asynchronous data client
881+
(:mod:`google.cloud.bigtable.data`).
882+
876883
:type flush_count: int
877884
:param flush_count: (Optional) Maximum number of rows per batch. If it
878885
reaches the max number of rows it calls finish_batch() to

0 commit comments

Comments
 (0)