15#ifndef GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_SPANNER_INSTANCE_ADMIN_CLIENT_H
16#define GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_SPANNER_INSTANCE_ADMIN_CLIENT_H
18#include "google/cloud/spanner/iam_updater.h"
19#include "google/cloud/spanner/instance.h"
20#include "google/cloud/spanner/instance_admin_connection.h"
21#include "google/cloud/spanner/version.h"
22#include "google/cloud/status_or.h"
29GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_BEGIN
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
71 : conn_(std::move(conn)) {}
89 return a.conn_ == b.conn_;
98
99
100
101
102
103
104
105
106
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126 future<StatusOr<
google::spanner::admin::instance::v1::Instance>>
128 google::spanner::admin::instance::v1::CreateInstanceRequest
const&);
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146 future<StatusOr<
google::spanner::admin::instance::v1::Instance>>
148 google::spanner::admin::instance::v1::UpdateInstanceRequest
const&);
151
152
153
154
155
156
157
158
162
163
164
165
166
167
168
169
170
171 StatusOr<
google::spanner::admin::instance::v1::InstanceConfig>
175
176
177
178
179
180
181
182
183
187
188
189
190
191
192
193
194
195
196 ListInstancesRange
ListInstances(std::string project_id, std::string filter);
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
271 IamUpdater
const& updater);
274
275
276
277
278
279
280
282 Instance const& in, IamUpdater
const& updater,
283 std::unique_ptr<TransactionRerunPolicy> rerun_policy,
284 std::unique_ptr<BackoffPolicy> backoff_policy);
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
306 Instance const& in, std::vector<std::string> permissions);
312GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_END
friend friend class future
Performs instance administration operations on Cloud Spanner.
Definition: instance_admin_client.h:68
StatusOr< google::spanner::admin::instance::v1::Instance > GetInstance(Instance const &in)
Retrieve metadata information about a Cloud Spanner Instance.
InstanceAdminClient & operator=(InstanceAdminClient &&)=default
StatusOr< google::iam::v1::Policy > SetIamPolicy(Instance const &in, IamUpdater const &updater)
Updates the IAM policy for an instance using an optimistic concurrency control loop.
ListInstanceConfigsRange ListInstanceConfigs(std::string project_id)
Retrieve a list of instance configs for a given project.
StatusOr< google::spanner::admin::instance::v1::InstanceConfig > GetInstanceConfig(std::string const &name)
Retrieve information about a Cloud Spanner Instance Config.
future< StatusOr< google::spanner::admin::instance::v1::Instance > > CreateInstance(google::spanner::admin::instance::v1::CreateInstanceRequest const &)
Creates a new Cloud Spanner instance in the given project.
StatusOr< google::iam::v1::Policy > GetIamPolicy(Instance const &in)
Get the IAM policy in effect for the given instance.
StatusOr< google::iam::v1::TestIamPermissionsResponse > TestIamPermissions(Instance const &in, std::vector< std::string > permissions)
Get the subset of the permissions the caller has on the given instance.
InstanceAdminClient(InstanceAdminClient const &)=default
Status DeleteInstance(Instance const &in)
Deletes an existing Cloud Spanner instance.
StatusOr< google::iam::v1::Policy > SetIamPolicy(Instance const &in, IamUpdater const &updater, std::unique_ptr< TransactionRerunPolicy > rerun_policy, std::unique_ptr< BackoffPolicy > backoff_policy)
Updates the IAM policy for an instance using an optimistic concurrency control loop.
InstanceAdminClient(InstanceAdminClient &&)=default
InstanceAdminClient & operator=(InstanceAdminClient const &)=default
InstanceAdminClient()=delete
No default construction.
future< StatusOr< google::spanner::admin::instance::v1::Instance > > UpdateInstance(google::spanner::admin::instance::v1::UpdateInstanceRequest const &)
Updates a Cloud Spanner instance.
InstanceAdminClient(std::shared_ptr< InstanceAdminConnection > conn)
Definition: instance_admin_client.h:70
ListInstancesRange ListInstances(std::string project_id, std::string filter)
Retrieve a list of instances for a given project.
friend bool operator!=(InstanceAdminClient const &a, InstanceAdminClient const &b)
Definition: instance_admin_client.h:91
StatusOr< google::iam::v1::Policy > SetIamPolicy(Instance const &in, google::iam::v1::Policy policy)
Set the IAM policy for the given instance.
friend bool operator==(InstanceAdminClient const &a, InstanceAdminClient const &b)
Definition: instance_admin_client.h:87
A connection to the Cloud Spanner instance administration service.
Definition: instance_admin_connection.h:75
This class identifies a Cloud Spanner Instance.
Definition: instance.h:42
Contains all the Cloud Spanner C++ client types and functions.
Definition: backoff_policy.h:23
#define GOOGLE_CLOUD_CPP_SPANNER_ADMIN_API_DEPRECATED(name)
Definition: version.h:23