Skip to content

Commit 6867bce

Browse files
dpebottseaver
authored andcommitted
Re-generate library using bigtable/synth.py (googleapis#5948)
1 parent 723b2a3 commit 6867bce

7 files changed

Lines changed: 193 additions & 135 deletions

File tree

bigtable/google/cloud/bigtable_admin_v2/__init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,7 @@
2525
class BigtableInstanceAdminClient(
2626
bigtable_instance_admin_client.BigtableInstanceAdminClient):
2727
__doc__ = (
28-
bigtable_instance_admin_client.BigtableInstanceAdminClient.__doc__
29-
)
28+
bigtable_instance_admin_client.BigtableInstanceAdminClient.__doc__)
3029
enums = enums
3130

3231

bigtable/google/cloud/bigtable_admin_v2/gapic/bigtable_instance_admin_client.py

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ def create_instance(self,
268268
cluster ID, e.g., just ``mycluster`` rather than
269269
``projects/myproject/instances/myinstance/clusters/mycluster``.
270270
Fields marked ``OutputOnly`` must be left blank.
271-
Currently exactly one cluster must be specified.
271+
Currently, at most two clusters can be specified.
272272
If a dict is provided, it must be of the same form as the protobuf
273273
message :class:`~google.cloud.bigtable_admin_v2.types.Cluster`
274274
retry (Optional[google.api_core.retry.Retry]): A retry object used
@@ -415,7 +415,7 @@ def list_instances(self,
415415
Args:
416416
parent (str): The unique name of the project for which a list of instances is requested.
417417
Values are of the form ``projects/<project>``.
418-
page_token (str): The value of ``next_page_token`` returned by a previous call.
418+
page_token (str): DEPRECATED: This field is unused and ignored.
419419
retry (Optional[google.api_core.retry.Retry]): A retry object used
420420
to retry requests. If ``None`` is specified, requests will not
421421
be retried.
@@ -918,7 +918,7 @@ def list_clusters(self,
918918
Values are of the form ``projects/<project>/instances/<instance>``.
919919
Use ``<instance> = '-'`` to list Clusters for all Instances in a project,
920920
e.g., ``projects/myproject/instances/-``.
921-
page_token (str): The value of ``next_page_token`` returned by a previous call.
921+
page_token (str): DEPRECATED: This field is unused and ignored.
922922
retry (Optional[google.api_core.retry.Retry]): A retry object used
923923
to retry requests. If ``None`` is specified, requests will not
924924
be retried.
@@ -1296,6 +1296,7 @@ def get_app_profile(self,
12961296

12971297
def list_app_profiles(self,
12981298
parent,
1299+
page_size=None,
12991300
retry=google.api_core.gapic_v1.method.DEFAULT,
13001301
timeout=google.api_core.gapic_v1.method.DEFAULT,
13011302
metadata=None):
@@ -1327,6 +1328,10 @@ def list_app_profiles(self,
13271328
parent (str): The unique name of the instance for which a list of app profiles is
13281329
requested. Values are of the form
13291330
``projects/<project>/instances/<instance>``.
1331+
Use ``<instance> = '-'`` to list AppProfiles for all Instances in a project,
1332+
e.g., ``projects/myproject/instances/-``.
1333+
page_size (int): Maximum number of results per page.
1334+
CURRENTLY UNIMPLEMENTED AND IGNORED.
13301335
retry (Optional[google.api_core.retry.Retry]): A retry object used
13311336
to retry requests. If ``None`` is specified, requests will not
13321337
be retried.
@@ -1362,7 +1367,9 @@ def list_app_profiles(self,
13621367
)
13631368

13641369
request = bigtable_instance_admin_pb2.ListAppProfilesRequest(
1365-
parent=parent, )
1370+
parent=parent,
1371+
page_size=page_size,
1372+
)
13661373
if metadata is None:
13671374
metadata = []
13681375
metadata = list(metadata)

bigtable/google/cloud/bigtable_admin_v2/gapic/bigtable_table_admin_client.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -438,6 +438,7 @@ def create_table_from_snapshot(
438438
def list_tables(self,
439439
parent,
440440
view=None,
441+
page_size=None,
441442
retry=google.api_core.gapic_v1.method.DEFAULT,
442443
timeout=google.api_core.gapic_v1.method.DEFAULT,
443444
metadata=None):
@@ -470,6 +471,8 @@ def list_tables(self,
470471
Values are of the form ``projects/<project>/instances/<instance>``.
471472
view (~google.cloud.bigtable_admin_v2.types.View): The view to be applied to the returned tables' fields.
472473
Defaults to ``NAME_ONLY`` if unspecified; no others are currently supported.
474+
page_size (int): Maximum number of results per page.
475+
CURRENTLY UNIMPLEMENTED AND IGNORED.
473476
retry (Optional[google.api_core.retry.Retry]): A retry object used
474477
to retry requests. If ``None`` is specified, requests will not
475478
be retried.
@@ -505,6 +508,7 @@ def list_tables(self,
505508
request = bigtable_table_admin_pb2.ListTablesRequest(
506509
parent=parent,
507510
view=view,
511+
page_size=page_size,
508512
)
509513
if metadata is None:
510514
metadata = []

bigtable/google/cloud/bigtable_admin_v2/gapic/enums.py

Lines changed: 65 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -32,71 +32,6 @@ class StorageType(enum.IntEnum):
3232
HDD = 2
3333

3434

35-
class Instance(object):
36-
class State(enum.IntEnum):
37-
"""
38-
Possible states of an instance.
39-
40-
Attributes:
41-
STATE_NOT_KNOWN (int): The state of the instance could not be determined.
42-
READY (int): The instance has been successfully created and can serve requests
43-
to its tables.
44-
CREATING (int): The instance is currently being created, and may be destroyed
45-
if the creation process encounters an error.
46-
"""
47-
STATE_NOT_KNOWN = 0
48-
READY = 1
49-
CREATING = 2
50-
51-
class Type(enum.IntEnum):
52-
"""
53-
The type of the instance.
54-
55-
Attributes:
56-
TYPE_UNSPECIFIED (int): The type of the instance is unspecified. If set when creating an
57-
instance, a ``PRODUCTION`` instance will be created. If set when updating
58-
an instance, the type will be left unchanged.
59-
PRODUCTION (int): An instance meant for production use. ``serve_nodes`` must be set
60-
on the cluster.
61-
DEVELOPMENT (int): The instance is meant for development and testing purposes only; it has
62-
no performance or uptime guarantees and is not covered by SLA.
63-
After a development instance is created, it can be upgraded by
64-
updating the instance to type ``PRODUCTION``. An instance created
65-
as a production instance cannot be changed to a development instance.
66-
When creating a development instance, ``serve_nodes`` on the cluster must
67-
not be set.
68-
"""
69-
TYPE_UNSPECIFIED = 0
70-
PRODUCTION = 1
71-
DEVELOPMENT = 2
72-
73-
74-
class Cluster(object):
75-
class State(enum.IntEnum):
76-
"""
77-
Possible states of a cluster.
78-
79-
Attributes:
80-
STATE_NOT_KNOWN (int): The state of the cluster could not be determined.
81-
READY (int): The cluster has been successfully created and is ready to serve requests.
82-
CREATING (int): The cluster is currently being created, and may be destroyed
83-
if the creation process encounters an error.
84-
A cluster may not be able to serve requests while being created.
85-
RESIZING (int): The cluster is currently being resized, and may revert to its previous
86-
node count if the process encounters an error.
87-
A cluster is still capable of serving requests while being resized,
88-
but may exhibit performance as if its number of allocated nodes is
89-
between the starting and requested states.
90-
DISABLED (int): The cluster has no backing nodes. The data (tables) still
91-
exist, but no operations can be performed on the cluster.
92-
"""
93-
STATE_NOT_KNOWN = 0
94-
READY = 1
95-
CREATING = 2
96-
RESIZING = 3
97-
DISABLED = 4
98-
99-
10035
class Table(object):
10136
class TimestampGranularity(enum.IntEnum):
10237
"""
@@ -169,3 +104,68 @@ class State(enum.IntEnum):
169104
STATE_NOT_KNOWN = 0
170105
READY = 1
171106
CREATING = 2
107+
108+
109+
class Instance(object):
110+
class State(enum.IntEnum):
111+
"""
112+
Possible states of an instance.
113+
114+
Attributes:
115+
STATE_NOT_KNOWN (int): The state of the instance could not be determined.
116+
READY (int): The instance has been successfully created and can serve requests
117+
to its tables.
118+
CREATING (int): The instance is currently being created, and may be destroyed
119+
if the creation process encounters an error.
120+
"""
121+
STATE_NOT_KNOWN = 0
122+
READY = 1
123+
CREATING = 2
124+
125+
class Type(enum.IntEnum):
126+
"""
127+
The type of the instance.
128+
129+
Attributes:
130+
TYPE_UNSPECIFIED (int): The type of the instance is unspecified. If set when creating an
131+
instance, a ``PRODUCTION`` instance will be created. If set when updating
132+
an instance, the type will be left unchanged.
133+
PRODUCTION (int): An instance meant for production use. ``serve_nodes`` must be set
134+
on the cluster.
135+
DEVELOPMENT (int): The instance is meant for development and testing purposes only; it has
136+
no performance or uptime guarantees and is not covered by SLA.
137+
After a development instance is created, it can be upgraded by
138+
updating the instance to type ``PRODUCTION``. An instance created
139+
as a production instance cannot be changed to a development instance.
140+
When creating a development instance, ``serve_nodes`` on the cluster must
141+
not be set.
142+
"""
143+
TYPE_UNSPECIFIED = 0
144+
PRODUCTION = 1
145+
DEVELOPMENT = 2
146+
147+
148+
class Cluster(object):
149+
class State(enum.IntEnum):
150+
"""
151+
Possible states of a cluster.
152+
153+
Attributes:
154+
STATE_NOT_KNOWN (int): The state of the cluster could not be determined.
155+
READY (int): The cluster has been successfully created and is ready to serve requests.
156+
CREATING (int): The cluster is currently being created, and may be destroyed
157+
if the creation process encounters an error.
158+
A cluster may not be able to serve requests while being created.
159+
RESIZING (int): The cluster is currently being resized, and may revert to its previous
160+
node count if the process encounters an error.
161+
A cluster is still capable of serving requests while being resized,
162+
but may exhibit performance as if its number of allocated nodes is
163+
between the starting and requested states.
164+
DISABLED (int): The cluster has no backing nodes. The data (tables) still
165+
exist, but no operations can be performed on the cluster.
166+
"""
167+
STATE_NOT_KNOWN = 0
168+
READY = 1
169+
CREATING = 2
170+
RESIZING = 3
171+
DISABLED = 4

0 commit comments

Comments
 (0)