@@ -117,6 +117,22 @@ AlloyDBAdminClient::DeleteCluster(
117117 return connection_->DeleteCluster (request);
118118}
119119
120+ future<StatusOr<google::cloud::alloydb::v1::Cluster>>
121+ AlloyDBAdminClient::PromoteCluster (std::string const & name, Options opts) {
122+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
123+ google::cloud::alloydb::v1::PromoteClusterRequest request;
124+ request.set_name (name);
125+ return connection_->PromoteCluster (request);
126+ }
127+
128+ future<StatusOr<google::cloud::alloydb::v1::Cluster>>
129+ AlloyDBAdminClient::PromoteCluster (
130+ google::cloud::alloydb::v1::PromoteClusterRequest const & request,
131+ Options opts) {
132+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
133+ return connection_->PromoteCluster (request);
134+ }
135+
120136future<StatusOr<google::cloud::alloydb::v1::Cluster>>
121137AlloyDBAdminClient::RestoreCluster (
122138 google::cloud::alloydb::v1::RestoreClusterRequest const & request,
@@ -125,6 +141,27 @@ AlloyDBAdminClient::RestoreCluster(
125141 return connection_->RestoreCluster (request);
126142}
127143
144+ future<StatusOr<google::cloud::alloydb::v1::Cluster>>
145+ AlloyDBAdminClient::CreateSecondaryCluster (
146+ std::string const & parent,
147+ google::cloud::alloydb::v1::Cluster const & cluster,
148+ std::string const & cluster_id, Options opts) {
149+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
150+ google::cloud::alloydb::v1::CreateSecondaryClusterRequest request;
151+ request.set_parent (parent);
152+ *request.mutable_cluster () = cluster;
153+ request.set_cluster_id (cluster_id);
154+ return connection_->CreateSecondaryCluster (request);
155+ }
156+
157+ future<StatusOr<google::cloud::alloydb::v1::Cluster>>
158+ AlloyDBAdminClient::CreateSecondaryCluster (
159+ google::cloud::alloydb::v1::CreateSecondaryClusterRequest const & request,
160+ Options opts) {
161+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
162+ return connection_->CreateSecondaryCluster (request);
163+ }
164+
128165StreamRange<google::cloud::alloydb::v1::Instance>
129166AlloyDBAdminClient::ListInstances (std::string const & parent, Options opts) {
130167 internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
@@ -176,6 +213,27 @@ AlloyDBAdminClient::CreateInstance(
176213 return connection_->CreateInstance (request);
177214}
178215
216+ future<StatusOr<google::cloud::alloydb::v1::Instance>>
217+ AlloyDBAdminClient::CreateSecondaryInstance (
218+ std::string const & parent,
219+ google::cloud::alloydb::v1::Instance const & instance,
220+ std::string const & instance_id, Options opts) {
221+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
222+ google::cloud::alloydb::v1::CreateSecondaryInstanceRequest request;
223+ request.set_parent (parent);
224+ *request.mutable_instance () = instance;
225+ request.set_instance_id (instance_id);
226+ return connection_->CreateSecondaryInstance (request);
227+ }
228+
229+ future<StatusOr<google::cloud::alloydb::v1::Instance>>
230+ AlloyDBAdminClient::CreateSecondaryInstance (
231+ google::cloud::alloydb::v1::CreateSecondaryInstanceRequest const & request,
232+ Options opts) {
233+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
234+ return connection_->CreateSecondaryInstance (request);
235+ }
236+
179237future<StatusOr<google::cloud::alloydb::v1::BatchCreateInstancesResponse>>
180238AlloyDBAdminClient::BatchCreateInstances (
181239 google::cloud::alloydb::v1::BatchCreateInstancesRequest const & request,
@@ -235,6 +293,25 @@ AlloyDBAdminClient::FailoverInstance(
235293 return connection_->FailoverInstance (request);
236294}
237295
296+ future<StatusOr<google::cloud::alloydb::v1::Instance>>
297+ AlloyDBAdminClient::InjectFault (
298+ google::cloud::alloydb::v1::InjectFaultRequest::FaultType fault_type,
299+ std::string const & name, Options opts) {
300+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
301+ google::cloud::alloydb::v1::InjectFaultRequest request;
302+ request.set_fault_type (fault_type);
303+ request.set_name (name);
304+ return connection_->InjectFault (request);
305+ }
306+
307+ future<StatusOr<google::cloud::alloydb::v1::Instance>>
308+ AlloyDBAdminClient::InjectFault (
309+ google::cloud::alloydb::v1::InjectFaultRequest const & request,
310+ Options opts) {
311+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
312+ return connection_->InjectFault (request);
313+ }
314+
238315future<StatusOr<google::cloud::alloydb::v1::Instance>>
239316AlloyDBAdminClient::RestartInstance (std::string const & name, Options opts) {
240317 internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
@@ -351,6 +428,83 @@ AlloyDBAdminClient::ListSupportedDatabaseFlags(
351428 return connection_->ListSupportedDatabaseFlags (std::move (request));
352429}
353430
431+ StreamRange<google::cloud::alloydb::v1::User> AlloyDBAdminClient::ListUsers (
432+ std::string const & parent, Options opts) {
433+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
434+ google::cloud::alloydb::v1::ListUsersRequest request;
435+ request.set_parent (parent);
436+ return connection_->ListUsers (request);
437+ }
438+
439+ StreamRange<google::cloud::alloydb::v1::User> AlloyDBAdminClient::ListUsers (
440+ google::cloud::alloydb::v1::ListUsersRequest request, Options opts) {
441+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
442+ return connection_->ListUsers (std::move (request));
443+ }
444+
445+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::GetUser (
446+ std::string const & name, Options opts) {
447+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
448+ google::cloud::alloydb::v1::GetUserRequest request;
449+ request.set_name (name);
450+ return connection_->GetUser (request);
451+ }
452+
453+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::GetUser (
454+ google::cloud::alloydb::v1::GetUserRequest const & request, Options opts) {
455+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
456+ return connection_->GetUser (request);
457+ }
458+
459+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::CreateUser (
460+ std::string const & parent, google::cloud::alloydb::v1::User const & user,
461+ std::string const & user_id, Options opts) {
462+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
463+ google::cloud::alloydb::v1::CreateUserRequest request;
464+ request.set_parent (parent);
465+ *request.mutable_user () = user;
466+ request.set_user_id (user_id);
467+ return connection_->CreateUser (request);
468+ }
469+
470+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::CreateUser (
471+ google::cloud::alloydb::v1::CreateUserRequest const & request,
472+ Options opts) {
473+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
474+ return connection_->CreateUser (request);
475+ }
476+
477+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::UpdateUser (
478+ google::cloud::alloydb::v1::User const & user,
479+ google::protobuf::FieldMask const & update_mask, Options opts) {
480+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
481+ google::cloud::alloydb::v1::UpdateUserRequest request;
482+ *request.mutable_user () = user;
483+ *request.mutable_update_mask () = update_mask;
484+ return connection_->UpdateUser (request);
485+ }
486+
487+ StatusOr<google::cloud::alloydb::v1::User> AlloyDBAdminClient::UpdateUser (
488+ google::cloud::alloydb::v1::UpdateUserRequest const & request,
489+ Options opts) {
490+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
491+ return connection_->UpdateUser (request);
492+ }
493+
494+ Status AlloyDBAdminClient::DeleteUser (std::string const & name, Options opts) {
495+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
496+ google::cloud::alloydb::v1::DeleteUserRequest request;
497+ request.set_name (name);
498+ return connection_->DeleteUser (request);
499+ }
500+
501+ Status AlloyDBAdminClient::DeleteUser (
502+ google::cloud::alloydb::v1::DeleteUserRequest const & request,
503+ Options opts) {
504+ internal::OptionsSpan span (internal::MergeOptions (std::move (opts), options_));
505+ return connection_->DeleteUser (request);
506+ }
507+
354508GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_END
355509} // namespace alloydb_v1
356510} // namespace cloud
0 commit comments