google-cloud-sql-v1 0.a → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +122 -0
- data/README.md +146 -8
- data/lib/google/cloud/sql/v1/cloud_sql_available_database_versions_pb.rb +25 -0
- data/lib/google/cloud/sql/v1/cloud_sql_available_database_versions_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_backup_runs_pb.rb +35 -0
- data/lib/google/cloud/sql/v1/cloud_sql_backup_runs_services_pb.rb +53 -0
- data/lib/google/cloud/sql/v1/cloud_sql_backups_pb.rb +41 -0
- data/lib/google/cloud/sql/v1/cloud_sql_backups_services_pb.rb +54 -0
- data/lib/google/cloud/sql/v1/cloud_sql_connect_pb.rb +34 -0
- data/lib/google/cloud/sql/v1/cloud_sql_connect_services_pb.rb +50 -0
- data/lib/google/cloud/sql/v1/cloud_sql_databases_pb.rb +30 -0
- data/lib/google/cloud/sql/v1/cloud_sql_databases_services_pb.rb +61 -0
- data/lib/google/cloud/sql/v1/cloud_sql_events_pb.rb +25 -0
- data/lib/google/cloud/sql/v1/cloud_sql_events_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_feature_eligibility_pb.rb +24 -0
- data/lib/google/cloud/sql/v1/cloud_sql_feature_eligibility_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_flags_pb.rb +31 -0
- data/lib/google/cloud/sql/v1/cloud_sql_flags_services_pb.rb +45 -0
- data/lib/google/cloud/sql/v1/cloud_sql_iam_policies_pb.rb +23 -0
- data/lib/google/cloud/sql/v1/cloud_sql_iam_policies_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_instance_names_pb.rb +24 -0
- data/lib/google/cloud/sql/v1/cloud_sql_instance_names_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_instances_pb.rb +146 -0
- data/lib/google/cloud/sql/v1/cloud_sql_instances_services_pb.rb +184 -0
- data/lib/google/cloud/sql/v1/cloud_sql_operations_pb.rb +30 -0
- data/lib/google/cloud/sql/v1/cloud_sql_operations_services_pb.rb +50 -0
- data/lib/google/cloud/sql/v1/cloud_sql_regions_pb.rb +25 -0
- data/lib/google/cloud/sql/v1/cloud_sql_regions_services_pb.rb +29 -0
- data/lib/google/cloud/sql/v1/cloud_sql_resources_pb.rb +119 -0
- data/lib/google/cloud/sql/v1/cloud_sql_ssl_certs_pb.rb +31 -0
- data/lib/google/cloud/sql/v1/cloud_sql_ssl_certs_services_pb.rb +56 -0
- data/lib/google/cloud/sql/v1/cloud_sql_tiers_pb.rb +26 -0
- data/lib/google/cloud/sql/v1/cloud_sql_tiers_services_pb.rb +47 -0
- data/lib/google/cloud/sql/v1/cloud_sql_users_pb.rb +41 -0
- data/lib/google/cloud/sql/v1/cloud_sql_users_services_pb.rb +53 -0
- data/lib/google/cloud/sql/v1/rest.rb +46 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service/client.rb +809 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service/rest/client.rb +720 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service/rest/service_stub.rb +332 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_backup_runs_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/client.rb +896 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/paths.rb +64 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/rest/client.rb +818 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/rest/service_stub.rb +388 -0
- data/lib/google/cloud/sql/v1/sql_backups_service/rest.rb +50 -0
- data/lib/google/cloud/sql/v1/sql_backups_service.rb +53 -0
- data/lib/google/cloud/sql/v1/sql_connect_service/client.rb +607 -0
- data/lib/google/cloud/sql/v1/sql_connect_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_connect_service/rest/client.rb +544 -0
- data/lib/google/cloud/sql/v1/sql_connect_service/rest/service_stub.rb +206 -0
- data/lib/google/cloud/sql/v1/sql_connect_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_connect_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_databases_service/client.rb +1011 -0
- data/lib/google/cloud/sql/v1/sql_databases_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_databases_service/rest/client.rb +896 -0
- data/lib/google/cloud/sql/v1/sql_databases_service/rest/service_stub.rb +460 -0
- data/lib/google/cloud/sql/v1/sql_databases_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_databases_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_flags_service/client.rb +488 -0
- data/lib/google/cloud/sql/v1/sql_flags_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_flags_service/rest/client.rb +446 -0
- data/lib/google/cloud/sql/v1/sql_flags_service/rest/service_stub.rb +140 -0
- data/lib/google/cloud/sql/v1/sql_flags_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_flags_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/client.rb +4738 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/paths.rb +95 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/rest/client.rb +4274 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/rest/service_stub.rb +2769 -0
- data/lib/google/cloud/sql/v1/sql_instances_service/rest.rb +50 -0
- data/lib/google/cloud/sql/v1/sql_instances_service.rb +53 -0
- data/lib/google/cloud/sql/v1/sql_operations_service/client.rb +694 -0
- data/lib/google/cloud/sql/v1/sql_operations_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_operations_service/rest/client.rb +624 -0
- data/lib/google/cloud/sql/v1/sql_operations_service/rest/service_stub.rb +266 -0
- data/lib/google/cloud/sql/v1/sql_operations_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_operations_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service/client.rb +804 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service/rest/client.rb +715 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service/rest/service_stub.rb +332 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_ssl_certs_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service/client.rb +494 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service/rest/client.rb +444 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service/rest/service_stub.rb +142 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_tiers_service.rb +54 -0
- data/lib/google/cloud/sql/v1/sql_users_service/client.rb +909 -0
- data/lib/google/cloud/sql/v1/sql_users_service/credentials.rb +48 -0
- data/lib/google/cloud/sql/v1/sql_users_service/rest/client.rb +813 -0
- data/lib/google/cloud/sql/v1/sql_users_service/rest/service_stub.rb +394 -0
- data/lib/google/cloud/sql/v1/sql_users_service/rest.rb +51 -0
- data/lib/google/cloud/sql/v1/sql_users_service.rb +54 -0
- data/lib/google/cloud/sql/v1/version.rb +8 -3
- data/lib/google/cloud/sql/v1.rb +60 -0
- data/lib/google-cloud-sql-v1.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/client.rb +593 -0
- data/proto_docs/google/api/field_behavior.rb +85 -0
- data/proto_docs/google/api/field_info.rb +88 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/api/resource.rb +227 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_backup_runs.rb +245 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_backups.rb +259 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_connect.rb +190 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_databases.rb +111 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_flags.rb +154 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_instances.rb +2357 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_operations.rb +85 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_resources.rb +2522 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_ssl_certs.rb +120 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_tiers.rb +69 -0
- data/proto_docs/google/cloud/sql/v1/cloud_sql_users.rb +291 -0
- data/proto_docs/google/protobuf/any.rb +145 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +34 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/timestamp.rb +127 -0
- data/proto_docs/google/protobuf/wrappers.rb +148 -0
- data/proto_docs/google/rpc/status.rb +48 -0
- data/proto_docs/google/type/interval.rb +45 -0
- metadata +176 -14
|
@@ -0,0 +1,2769 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
|
+
#
|
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
# you may not use this file except in compliance with the License.
|
|
7
|
+
# You may obtain a copy of the License at
|
|
8
|
+
#
|
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
#
|
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
# See the License for the specific language governing permissions and
|
|
15
|
+
# limitations under the License.
|
|
16
|
+
|
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
|
18
|
+
|
|
19
|
+
require "google/cloud/sql/v1/cloud_sql_instances_pb"
|
|
20
|
+
|
|
21
|
+
module Google
|
|
22
|
+
module Cloud
|
|
23
|
+
module Sql
|
|
24
|
+
module V1
|
|
25
|
+
module SqlInstancesService
|
|
26
|
+
module Rest
|
|
27
|
+
##
|
|
28
|
+
# REST service stub for the SqlInstancesService service.
|
|
29
|
+
# Service stub contains baseline method implementations
|
|
30
|
+
# including transcoding, making the REST call, and deserialing the response.
|
|
31
|
+
#
|
|
32
|
+
class ServiceStub
|
|
33
|
+
# @private
|
|
34
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:, logger:
|
|
35
|
+
# These require statements are intentionally placed here to initialize
|
|
36
|
+
# the REST modules only when it's required.
|
|
37
|
+
require "gapic/rest"
|
|
38
|
+
|
|
39
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
|
40
|
+
endpoint_template: endpoint_template,
|
|
41
|
+
universe_domain: universe_domain,
|
|
42
|
+
credentials: credentials,
|
|
43
|
+
numeric_enums: true,
|
|
44
|
+
service_name: self.class,
|
|
45
|
+
raise_faraday_errors: false,
|
|
46
|
+
logger: logger
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
##
|
|
50
|
+
# The effective universe domain
|
|
51
|
+
#
|
|
52
|
+
# @return [String]
|
|
53
|
+
#
|
|
54
|
+
def universe_domain
|
|
55
|
+
@client_stub.universe_domain
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
##
|
|
59
|
+
# The effective endpoint
|
|
60
|
+
#
|
|
61
|
+
# @return [String]
|
|
62
|
+
#
|
|
63
|
+
def endpoint
|
|
64
|
+
@client_stub.endpoint
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
##
|
|
68
|
+
# The logger used for request/response debug logging.
|
|
69
|
+
#
|
|
70
|
+
# @return [Logger]
|
|
71
|
+
#
|
|
72
|
+
def logger stub: false
|
|
73
|
+
stub ? @client_stub.stub_logger : @client_stub.logger
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
##
|
|
77
|
+
# Baseline implementation for the add_server_ca REST call
|
|
78
|
+
#
|
|
79
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddServerCaRequest]
|
|
80
|
+
# A request object representing the call parameters. Required.
|
|
81
|
+
# @param options [::Gapic::CallOptions]
|
|
82
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
83
|
+
#
|
|
84
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
85
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
86
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
87
|
+
#
|
|
88
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
89
|
+
# A result object deserialized from the server's reply
|
|
90
|
+
def add_server_ca request_pb, options = nil
|
|
91
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
92
|
+
|
|
93
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_add_server_ca_request request_pb
|
|
94
|
+
query_string_params = if query_string_params.any?
|
|
95
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
96
|
+
else
|
|
97
|
+
{}
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
response = @client_stub.make_http_request(
|
|
101
|
+
verb,
|
|
102
|
+
uri: uri,
|
|
103
|
+
body: body || "",
|
|
104
|
+
params: query_string_params,
|
|
105
|
+
method_name: "add_server_ca",
|
|
106
|
+
options: options
|
|
107
|
+
)
|
|
108
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
109
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
110
|
+
catch :response do
|
|
111
|
+
yield result, operation if block_given?
|
|
112
|
+
result
|
|
113
|
+
end
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
##
|
|
117
|
+
# Baseline implementation for the add_server_certificate REST call
|
|
118
|
+
#
|
|
119
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddServerCertificateRequest]
|
|
120
|
+
# A request object representing the call parameters. Required.
|
|
121
|
+
# @param options [::Gapic::CallOptions]
|
|
122
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
123
|
+
#
|
|
124
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
125
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
126
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
127
|
+
#
|
|
128
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
129
|
+
# A result object deserialized from the server's reply
|
|
130
|
+
def add_server_certificate request_pb, options = nil
|
|
131
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
132
|
+
|
|
133
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_add_server_certificate_request request_pb
|
|
134
|
+
query_string_params = if query_string_params.any?
|
|
135
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
136
|
+
else
|
|
137
|
+
{}
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
response = @client_stub.make_http_request(
|
|
141
|
+
verb,
|
|
142
|
+
uri: uri,
|
|
143
|
+
body: body || "",
|
|
144
|
+
params: query_string_params,
|
|
145
|
+
method_name: "add_server_certificate",
|
|
146
|
+
options: options
|
|
147
|
+
)
|
|
148
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
149
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
150
|
+
catch :response do
|
|
151
|
+
yield result, operation if block_given?
|
|
152
|
+
result
|
|
153
|
+
end
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
##
|
|
157
|
+
# Baseline implementation for the add_entra_id_certificate REST call
|
|
158
|
+
#
|
|
159
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddEntraIdCertificateRequest]
|
|
160
|
+
# A request object representing the call parameters. Required.
|
|
161
|
+
# @param options [::Gapic::CallOptions]
|
|
162
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
163
|
+
#
|
|
164
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
165
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
166
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
167
|
+
#
|
|
168
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
169
|
+
# A result object deserialized from the server's reply
|
|
170
|
+
def add_entra_id_certificate request_pb, options = nil
|
|
171
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
172
|
+
|
|
173
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_add_entra_id_certificate_request request_pb
|
|
174
|
+
query_string_params = if query_string_params.any?
|
|
175
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
176
|
+
else
|
|
177
|
+
{}
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
response = @client_stub.make_http_request(
|
|
181
|
+
verb,
|
|
182
|
+
uri: uri,
|
|
183
|
+
body: body || "",
|
|
184
|
+
params: query_string_params,
|
|
185
|
+
method_name: "add_entra_id_certificate",
|
|
186
|
+
options: options
|
|
187
|
+
)
|
|
188
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
189
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
190
|
+
catch :response do
|
|
191
|
+
yield result, operation if block_given?
|
|
192
|
+
result
|
|
193
|
+
end
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
##
|
|
197
|
+
# Baseline implementation for the call_clone REST call
|
|
198
|
+
#
|
|
199
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesCloneRequest]
|
|
200
|
+
# A request object representing the call parameters. Required.
|
|
201
|
+
# @param options [::Gapic::CallOptions]
|
|
202
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
203
|
+
#
|
|
204
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
205
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
206
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
207
|
+
#
|
|
208
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
209
|
+
# A result object deserialized from the server's reply
|
|
210
|
+
def call_clone request_pb, options = nil
|
|
211
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
212
|
+
|
|
213
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_call_clone_request request_pb
|
|
214
|
+
query_string_params = if query_string_params.any?
|
|
215
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
216
|
+
else
|
|
217
|
+
{}
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
response = @client_stub.make_http_request(
|
|
221
|
+
verb,
|
|
222
|
+
uri: uri,
|
|
223
|
+
body: body || "",
|
|
224
|
+
params: query_string_params,
|
|
225
|
+
method_name: "call_clone",
|
|
226
|
+
options: options
|
|
227
|
+
)
|
|
228
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
229
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
230
|
+
catch :response do
|
|
231
|
+
yield result, operation if block_given?
|
|
232
|
+
result
|
|
233
|
+
end
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
##
|
|
237
|
+
# Baseline implementation for the delete REST call
|
|
238
|
+
#
|
|
239
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDeleteRequest]
|
|
240
|
+
# A request object representing the call parameters. Required.
|
|
241
|
+
# @param options [::Gapic::CallOptions]
|
|
242
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
243
|
+
#
|
|
244
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
245
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
246
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
247
|
+
#
|
|
248
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
249
|
+
# A result object deserialized from the server's reply
|
|
250
|
+
def delete request_pb, options = nil
|
|
251
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
252
|
+
|
|
253
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_request request_pb
|
|
254
|
+
query_string_params = if query_string_params.any?
|
|
255
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
256
|
+
else
|
|
257
|
+
{}
|
|
258
|
+
end
|
|
259
|
+
|
|
260
|
+
response = @client_stub.make_http_request(
|
|
261
|
+
verb,
|
|
262
|
+
uri: uri,
|
|
263
|
+
body: body || "",
|
|
264
|
+
params: query_string_params,
|
|
265
|
+
method_name: "delete",
|
|
266
|
+
options: options
|
|
267
|
+
)
|
|
268
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
269
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
270
|
+
catch :response do
|
|
271
|
+
yield result, operation if block_given?
|
|
272
|
+
result
|
|
273
|
+
end
|
|
274
|
+
end
|
|
275
|
+
|
|
276
|
+
##
|
|
277
|
+
# Baseline implementation for the demote_master REST call
|
|
278
|
+
#
|
|
279
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDemoteMasterRequest]
|
|
280
|
+
# A request object representing the call parameters. Required.
|
|
281
|
+
# @param options [::Gapic::CallOptions]
|
|
282
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
283
|
+
#
|
|
284
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
285
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
286
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
287
|
+
#
|
|
288
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
289
|
+
# A result object deserialized from the server's reply
|
|
290
|
+
def demote_master request_pb, options = nil
|
|
291
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
292
|
+
|
|
293
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_demote_master_request request_pb
|
|
294
|
+
query_string_params = if query_string_params.any?
|
|
295
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
296
|
+
else
|
|
297
|
+
{}
|
|
298
|
+
end
|
|
299
|
+
|
|
300
|
+
response = @client_stub.make_http_request(
|
|
301
|
+
verb,
|
|
302
|
+
uri: uri,
|
|
303
|
+
body: body || "",
|
|
304
|
+
params: query_string_params,
|
|
305
|
+
method_name: "demote_master",
|
|
306
|
+
options: options
|
|
307
|
+
)
|
|
308
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
309
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
310
|
+
catch :response do
|
|
311
|
+
yield result, operation if block_given?
|
|
312
|
+
result
|
|
313
|
+
end
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
##
|
|
317
|
+
# Baseline implementation for the demote REST call
|
|
318
|
+
#
|
|
319
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDemoteRequest]
|
|
320
|
+
# A request object representing the call parameters. Required.
|
|
321
|
+
# @param options [::Gapic::CallOptions]
|
|
322
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
323
|
+
#
|
|
324
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
325
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
326
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
327
|
+
#
|
|
328
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
329
|
+
# A result object deserialized from the server's reply
|
|
330
|
+
def demote request_pb, options = nil
|
|
331
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
332
|
+
|
|
333
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_demote_request request_pb
|
|
334
|
+
query_string_params = if query_string_params.any?
|
|
335
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
336
|
+
else
|
|
337
|
+
{}
|
|
338
|
+
end
|
|
339
|
+
|
|
340
|
+
response = @client_stub.make_http_request(
|
|
341
|
+
verb,
|
|
342
|
+
uri: uri,
|
|
343
|
+
body: body || "",
|
|
344
|
+
params: query_string_params,
|
|
345
|
+
method_name: "demote",
|
|
346
|
+
options: options
|
|
347
|
+
)
|
|
348
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
349
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
350
|
+
catch :response do
|
|
351
|
+
yield result, operation if block_given?
|
|
352
|
+
result
|
|
353
|
+
end
|
|
354
|
+
end
|
|
355
|
+
|
|
356
|
+
##
|
|
357
|
+
# Baseline implementation for the export REST call
|
|
358
|
+
#
|
|
359
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesExportRequest]
|
|
360
|
+
# A request object representing the call parameters. Required.
|
|
361
|
+
# @param options [::Gapic::CallOptions]
|
|
362
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
363
|
+
#
|
|
364
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
365
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
366
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
367
|
+
#
|
|
368
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
369
|
+
# A result object deserialized from the server's reply
|
|
370
|
+
def export request_pb, options = nil
|
|
371
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
372
|
+
|
|
373
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_export_request request_pb
|
|
374
|
+
query_string_params = if query_string_params.any?
|
|
375
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
376
|
+
else
|
|
377
|
+
{}
|
|
378
|
+
end
|
|
379
|
+
|
|
380
|
+
response = @client_stub.make_http_request(
|
|
381
|
+
verb,
|
|
382
|
+
uri: uri,
|
|
383
|
+
body: body || "",
|
|
384
|
+
params: query_string_params,
|
|
385
|
+
method_name: "export",
|
|
386
|
+
options: options
|
|
387
|
+
)
|
|
388
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
389
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
390
|
+
catch :response do
|
|
391
|
+
yield result, operation if block_given?
|
|
392
|
+
result
|
|
393
|
+
end
|
|
394
|
+
end
|
|
395
|
+
|
|
396
|
+
##
|
|
397
|
+
# Baseline implementation for the failover REST call
|
|
398
|
+
#
|
|
399
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesFailoverRequest]
|
|
400
|
+
# A request object representing the call parameters. Required.
|
|
401
|
+
# @param options [::Gapic::CallOptions]
|
|
402
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
403
|
+
#
|
|
404
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
405
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
406
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
407
|
+
#
|
|
408
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
409
|
+
# A result object deserialized from the server's reply
|
|
410
|
+
def failover request_pb, options = nil
|
|
411
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
412
|
+
|
|
413
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_failover_request request_pb
|
|
414
|
+
query_string_params = if query_string_params.any?
|
|
415
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
416
|
+
else
|
|
417
|
+
{}
|
|
418
|
+
end
|
|
419
|
+
|
|
420
|
+
response = @client_stub.make_http_request(
|
|
421
|
+
verb,
|
|
422
|
+
uri: uri,
|
|
423
|
+
body: body || "",
|
|
424
|
+
params: query_string_params,
|
|
425
|
+
method_name: "failover",
|
|
426
|
+
options: options
|
|
427
|
+
)
|
|
428
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
429
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
430
|
+
catch :response do
|
|
431
|
+
yield result, operation if block_given?
|
|
432
|
+
result
|
|
433
|
+
end
|
|
434
|
+
end
|
|
435
|
+
|
|
436
|
+
##
|
|
437
|
+
# Baseline implementation for the reencrypt REST call
|
|
438
|
+
#
|
|
439
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesReencryptRequest]
|
|
440
|
+
# A request object representing the call parameters. Required.
|
|
441
|
+
# @param options [::Gapic::CallOptions]
|
|
442
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
443
|
+
#
|
|
444
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
445
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
446
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
447
|
+
#
|
|
448
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
449
|
+
# A result object deserialized from the server's reply
|
|
450
|
+
def reencrypt request_pb, options = nil
|
|
451
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
452
|
+
|
|
453
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_reencrypt_request request_pb
|
|
454
|
+
query_string_params = if query_string_params.any?
|
|
455
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
456
|
+
else
|
|
457
|
+
{}
|
|
458
|
+
end
|
|
459
|
+
|
|
460
|
+
response = @client_stub.make_http_request(
|
|
461
|
+
verb,
|
|
462
|
+
uri: uri,
|
|
463
|
+
body: body || "",
|
|
464
|
+
params: query_string_params,
|
|
465
|
+
method_name: "reencrypt",
|
|
466
|
+
options: options
|
|
467
|
+
)
|
|
468
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
469
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
470
|
+
catch :response do
|
|
471
|
+
yield result, operation if block_given?
|
|
472
|
+
result
|
|
473
|
+
end
|
|
474
|
+
end
|
|
475
|
+
|
|
476
|
+
##
|
|
477
|
+
# Baseline implementation for the get REST call
|
|
478
|
+
#
|
|
479
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetRequest]
|
|
480
|
+
# A request object representing the call parameters. Required.
|
|
481
|
+
# @param options [::Gapic::CallOptions]
|
|
482
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
483
|
+
#
|
|
484
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
485
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::DatabaseInstance]
|
|
486
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
487
|
+
#
|
|
488
|
+
# @return [::Google::Cloud::Sql::V1::DatabaseInstance]
|
|
489
|
+
# A result object deserialized from the server's reply
|
|
490
|
+
def get request_pb, options = nil
|
|
491
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
492
|
+
|
|
493
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_request request_pb
|
|
494
|
+
query_string_params = if query_string_params.any?
|
|
495
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
496
|
+
else
|
|
497
|
+
{}
|
|
498
|
+
end
|
|
499
|
+
|
|
500
|
+
response = @client_stub.make_http_request(
|
|
501
|
+
verb,
|
|
502
|
+
uri: uri,
|
|
503
|
+
body: body || "",
|
|
504
|
+
params: query_string_params,
|
|
505
|
+
method_name: "get",
|
|
506
|
+
options: options
|
|
507
|
+
)
|
|
508
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
509
|
+
result = ::Google::Cloud::Sql::V1::DatabaseInstance.decode_json response.body, ignore_unknown_fields: true
|
|
510
|
+
catch :response do
|
|
511
|
+
yield result, operation if block_given?
|
|
512
|
+
result
|
|
513
|
+
end
|
|
514
|
+
end
|
|
515
|
+
|
|
516
|
+
##
|
|
517
|
+
# Baseline implementation for the import REST call
|
|
518
|
+
#
|
|
519
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesImportRequest]
|
|
520
|
+
# A request object representing the call parameters. Required.
|
|
521
|
+
# @param options [::Gapic::CallOptions]
|
|
522
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
523
|
+
#
|
|
524
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
525
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
526
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
527
|
+
#
|
|
528
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
529
|
+
# A result object deserialized from the server's reply
|
|
530
|
+
def import request_pb, options = nil
|
|
531
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
532
|
+
|
|
533
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_import_request request_pb
|
|
534
|
+
query_string_params = if query_string_params.any?
|
|
535
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
536
|
+
else
|
|
537
|
+
{}
|
|
538
|
+
end
|
|
539
|
+
|
|
540
|
+
response = @client_stub.make_http_request(
|
|
541
|
+
verb,
|
|
542
|
+
uri: uri,
|
|
543
|
+
body: body || "",
|
|
544
|
+
params: query_string_params,
|
|
545
|
+
method_name: "import",
|
|
546
|
+
options: options
|
|
547
|
+
)
|
|
548
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
549
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
550
|
+
catch :response do
|
|
551
|
+
yield result, operation if block_given?
|
|
552
|
+
result
|
|
553
|
+
end
|
|
554
|
+
end
|
|
555
|
+
|
|
556
|
+
##
|
|
557
|
+
# Baseline implementation for the insert REST call
|
|
558
|
+
#
|
|
559
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesInsertRequest]
|
|
560
|
+
# A request object representing the call parameters. Required.
|
|
561
|
+
# @param options [::Gapic::CallOptions]
|
|
562
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
563
|
+
#
|
|
564
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
565
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
566
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
567
|
+
#
|
|
568
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
569
|
+
# A result object deserialized from the server's reply
|
|
570
|
+
def insert request_pb, options = nil
|
|
571
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
572
|
+
|
|
573
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_insert_request request_pb
|
|
574
|
+
query_string_params = if query_string_params.any?
|
|
575
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
576
|
+
else
|
|
577
|
+
{}
|
|
578
|
+
end
|
|
579
|
+
|
|
580
|
+
response = @client_stub.make_http_request(
|
|
581
|
+
verb,
|
|
582
|
+
uri: uri,
|
|
583
|
+
body: body || "",
|
|
584
|
+
params: query_string_params,
|
|
585
|
+
method_name: "insert",
|
|
586
|
+
options: options
|
|
587
|
+
)
|
|
588
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
589
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
590
|
+
catch :response do
|
|
591
|
+
yield result, operation if block_given?
|
|
592
|
+
result
|
|
593
|
+
end
|
|
594
|
+
end
|
|
595
|
+
|
|
596
|
+
##
|
|
597
|
+
# Baseline implementation for the list REST call
|
|
598
|
+
#
|
|
599
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListRequest]
|
|
600
|
+
# A request object representing the call parameters. Required.
|
|
601
|
+
# @param options [::Gapic::CallOptions]
|
|
602
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
603
|
+
#
|
|
604
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
605
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::InstancesListResponse]
|
|
606
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
607
|
+
#
|
|
608
|
+
# @return [::Google::Cloud::Sql::V1::InstancesListResponse]
|
|
609
|
+
# A result object deserialized from the server's reply
|
|
610
|
+
def list request_pb, options = nil
|
|
611
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
612
|
+
|
|
613
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_request request_pb
|
|
614
|
+
query_string_params = if query_string_params.any?
|
|
615
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
616
|
+
else
|
|
617
|
+
{}
|
|
618
|
+
end
|
|
619
|
+
|
|
620
|
+
response = @client_stub.make_http_request(
|
|
621
|
+
verb,
|
|
622
|
+
uri: uri,
|
|
623
|
+
body: body || "",
|
|
624
|
+
params: query_string_params,
|
|
625
|
+
method_name: "list",
|
|
626
|
+
options: options
|
|
627
|
+
)
|
|
628
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
629
|
+
result = ::Google::Cloud::Sql::V1::InstancesListResponse.decode_json response.body, ignore_unknown_fields: true
|
|
630
|
+
catch :response do
|
|
631
|
+
yield result, operation if block_given?
|
|
632
|
+
result
|
|
633
|
+
end
|
|
634
|
+
end
|
|
635
|
+
|
|
636
|
+
##
|
|
637
|
+
# Baseline implementation for the list_server_cas REST call
|
|
638
|
+
#
|
|
639
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListServerCasRequest]
|
|
640
|
+
# A request object representing the call parameters. Required.
|
|
641
|
+
# @param options [::Gapic::CallOptions]
|
|
642
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
643
|
+
#
|
|
644
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
645
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::InstancesListServerCasResponse]
|
|
646
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
647
|
+
#
|
|
648
|
+
# @return [::Google::Cloud::Sql::V1::InstancesListServerCasResponse]
|
|
649
|
+
# A result object deserialized from the server's reply
|
|
650
|
+
def list_server_cas request_pb, options = nil
|
|
651
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
652
|
+
|
|
653
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_server_cas_request request_pb
|
|
654
|
+
query_string_params = if query_string_params.any?
|
|
655
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
656
|
+
else
|
|
657
|
+
{}
|
|
658
|
+
end
|
|
659
|
+
|
|
660
|
+
response = @client_stub.make_http_request(
|
|
661
|
+
verb,
|
|
662
|
+
uri: uri,
|
|
663
|
+
body: body || "",
|
|
664
|
+
params: query_string_params,
|
|
665
|
+
method_name: "list_server_cas",
|
|
666
|
+
options: options
|
|
667
|
+
)
|
|
668
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
669
|
+
result = ::Google::Cloud::Sql::V1::InstancesListServerCasResponse.decode_json response.body, ignore_unknown_fields: true
|
|
670
|
+
catch :response do
|
|
671
|
+
yield result, operation if block_given?
|
|
672
|
+
result
|
|
673
|
+
end
|
|
674
|
+
end
|
|
675
|
+
|
|
676
|
+
##
|
|
677
|
+
# Baseline implementation for the list_server_certificates REST call
|
|
678
|
+
#
|
|
679
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListServerCertificatesRequest]
|
|
680
|
+
# A request object representing the call parameters. Required.
|
|
681
|
+
# @param options [::Gapic::CallOptions]
|
|
682
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
683
|
+
#
|
|
684
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
685
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::InstancesListServerCertificatesResponse]
|
|
686
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
687
|
+
#
|
|
688
|
+
# @return [::Google::Cloud::Sql::V1::InstancesListServerCertificatesResponse]
|
|
689
|
+
# A result object deserialized from the server's reply
|
|
690
|
+
def list_server_certificates request_pb, options = nil
|
|
691
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
692
|
+
|
|
693
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_server_certificates_request request_pb
|
|
694
|
+
query_string_params = if query_string_params.any?
|
|
695
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
696
|
+
else
|
|
697
|
+
{}
|
|
698
|
+
end
|
|
699
|
+
|
|
700
|
+
response = @client_stub.make_http_request(
|
|
701
|
+
verb,
|
|
702
|
+
uri: uri,
|
|
703
|
+
body: body || "",
|
|
704
|
+
params: query_string_params,
|
|
705
|
+
method_name: "list_server_certificates",
|
|
706
|
+
options: options
|
|
707
|
+
)
|
|
708
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
709
|
+
result = ::Google::Cloud::Sql::V1::InstancesListServerCertificatesResponse.decode_json response.body, ignore_unknown_fields: true
|
|
710
|
+
catch :response do
|
|
711
|
+
yield result, operation if block_given?
|
|
712
|
+
result
|
|
713
|
+
end
|
|
714
|
+
end
|
|
715
|
+
|
|
716
|
+
##
|
|
717
|
+
# Baseline implementation for the list_entra_id_certificates REST call
|
|
718
|
+
#
|
|
719
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListEntraIdCertificatesRequest]
|
|
720
|
+
# A request object representing the call parameters. Required.
|
|
721
|
+
# @param options [::Gapic::CallOptions]
|
|
722
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
723
|
+
#
|
|
724
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
725
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::InstancesListEntraIdCertificatesResponse]
|
|
726
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
727
|
+
#
|
|
728
|
+
# @return [::Google::Cloud::Sql::V1::InstancesListEntraIdCertificatesResponse]
|
|
729
|
+
# A result object deserialized from the server's reply
|
|
730
|
+
def list_entra_id_certificates request_pb, options = nil
|
|
731
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
732
|
+
|
|
733
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_entra_id_certificates_request request_pb
|
|
734
|
+
query_string_params = if query_string_params.any?
|
|
735
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
736
|
+
else
|
|
737
|
+
{}
|
|
738
|
+
end
|
|
739
|
+
|
|
740
|
+
response = @client_stub.make_http_request(
|
|
741
|
+
verb,
|
|
742
|
+
uri: uri,
|
|
743
|
+
body: body || "",
|
|
744
|
+
params: query_string_params,
|
|
745
|
+
method_name: "list_entra_id_certificates",
|
|
746
|
+
options: options
|
|
747
|
+
)
|
|
748
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
749
|
+
result = ::Google::Cloud::Sql::V1::InstancesListEntraIdCertificatesResponse.decode_json response.body, ignore_unknown_fields: true
|
|
750
|
+
catch :response do
|
|
751
|
+
yield result, operation if block_given?
|
|
752
|
+
result
|
|
753
|
+
end
|
|
754
|
+
end
|
|
755
|
+
|
|
756
|
+
##
|
|
757
|
+
# Baseline implementation for the patch REST call
|
|
758
|
+
#
|
|
759
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPatchRequest]
|
|
760
|
+
# A request object representing the call parameters. Required.
|
|
761
|
+
# @param options [::Gapic::CallOptions]
|
|
762
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
763
|
+
#
|
|
764
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
765
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
766
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
767
|
+
#
|
|
768
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
769
|
+
# A result object deserialized from the server's reply
|
|
770
|
+
def patch request_pb, options = nil
|
|
771
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
772
|
+
|
|
773
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_patch_request request_pb
|
|
774
|
+
query_string_params = if query_string_params.any?
|
|
775
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
776
|
+
else
|
|
777
|
+
{}
|
|
778
|
+
end
|
|
779
|
+
|
|
780
|
+
response = @client_stub.make_http_request(
|
|
781
|
+
verb,
|
|
782
|
+
uri: uri,
|
|
783
|
+
body: body || "",
|
|
784
|
+
params: query_string_params,
|
|
785
|
+
method_name: "patch",
|
|
786
|
+
options: options
|
|
787
|
+
)
|
|
788
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
789
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
790
|
+
catch :response do
|
|
791
|
+
yield result, operation if block_given?
|
|
792
|
+
result
|
|
793
|
+
end
|
|
794
|
+
end
|
|
795
|
+
|
|
796
|
+
##
|
|
797
|
+
# Baseline implementation for the promote_replica REST call
|
|
798
|
+
#
|
|
799
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPromoteReplicaRequest]
|
|
800
|
+
# A request object representing the call parameters. Required.
|
|
801
|
+
# @param options [::Gapic::CallOptions]
|
|
802
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
803
|
+
#
|
|
804
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
805
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
806
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
807
|
+
#
|
|
808
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
809
|
+
# A result object deserialized from the server's reply
|
|
810
|
+
def promote_replica request_pb, options = nil
|
|
811
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
812
|
+
|
|
813
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_promote_replica_request request_pb
|
|
814
|
+
query_string_params = if query_string_params.any?
|
|
815
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
816
|
+
else
|
|
817
|
+
{}
|
|
818
|
+
end
|
|
819
|
+
|
|
820
|
+
response = @client_stub.make_http_request(
|
|
821
|
+
verb,
|
|
822
|
+
uri: uri,
|
|
823
|
+
body: body || "",
|
|
824
|
+
params: query_string_params,
|
|
825
|
+
method_name: "promote_replica",
|
|
826
|
+
options: options
|
|
827
|
+
)
|
|
828
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
829
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
830
|
+
catch :response do
|
|
831
|
+
yield result, operation if block_given?
|
|
832
|
+
result
|
|
833
|
+
end
|
|
834
|
+
end
|
|
835
|
+
|
|
836
|
+
##
|
|
837
|
+
# Baseline implementation for the switchover REST call
|
|
838
|
+
#
|
|
839
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesSwitchoverRequest]
|
|
840
|
+
# A request object representing the call parameters. Required.
|
|
841
|
+
# @param options [::Gapic::CallOptions]
|
|
842
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
843
|
+
#
|
|
844
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
845
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
846
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
847
|
+
#
|
|
848
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
849
|
+
# A result object deserialized from the server's reply
|
|
850
|
+
def switchover request_pb, options = nil
|
|
851
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
852
|
+
|
|
853
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_switchover_request request_pb
|
|
854
|
+
query_string_params = if query_string_params.any?
|
|
855
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
856
|
+
else
|
|
857
|
+
{}
|
|
858
|
+
end
|
|
859
|
+
|
|
860
|
+
response = @client_stub.make_http_request(
|
|
861
|
+
verb,
|
|
862
|
+
uri: uri,
|
|
863
|
+
body: body || "",
|
|
864
|
+
params: query_string_params,
|
|
865
|
+
method_name: "switchover",
|
|
866
|
+
options: options
|
|
867
|
+
)
|
|
868
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
869
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
870
|
+
catch :response do
|
|
871
|
+
yield result, operation if block_given?
|
|
872
|
+
result
|
|
873
|
+
end
|
|
874
|
+
end
|
|
875
|
+
|
|
876
|
+
##
|
|
877
|
+
# Baseline implementation for the reset_ssl_config REST call
|
|
878
|
+
#
|
|
879
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesResetSslConfigRequest]
|
|
880
|
+
# A request object representing the call parameters. Required.
|
|
881
|
+
# @param options [::Gapic::CallOptions]
|
|
882
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
883
|
+
#
|
|
884
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
885
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
886
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
887
|
+
#
|
|
888
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
889
|
+
# A result object deserialized from the server's reply
|
|
890
|
+
def reset_ssl_config request_pb, options = nil
|
|
891
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
892
|
+
|
|
893
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_reset_ssl_config_request request_pb
|
|
894
|
+
query_string_params = if query_string_params.any?
|
|
895
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
896
|
+
else
|
|
897
|
+
{}
|
|
898
|
+
end
|
|
899
|
+
|
|
900
|
+
response = @client_stub.make_http_request(
|
|
901
|
+
verb,
|
|
902
|
+
uri: uri,
|
|
903
|
+
body: body || "",
|
|
904
|
+
params: query_string_params,
|
|
905
|
+
method_name: "reset_ssl_config",
|
|
906
|
+
options: options
|
|
907
|
+
)
|
|
908
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
909
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
910
|
+
catch :response do
|
|
911
|
+
yield result, operation if block_given?
|
|
912
|
+
result
|
|
913
|
+
end
|
|
914
|
+
end
|
|
915
|
+
|
|
916
|
+
##
|
|
917
|
+
# Baseline implementation for the restart REST call
|
|
918
|
+
#
|
|
919
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRestartRequest]
|
|
920
|
+
# A request object representing the call parameters. Required.
|
|
921
|
+
# @param options [::Gapic::CallOptions]
|
|
922
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
923
|
+
#
|
|
924
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
925
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
926
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
927
|
+
#
|
|
928
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
929
|
+
# A result object deserialized from the server's reply
|
|
930
|
+
def restart request_pb, options = nil
|
|
931
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
932
|
+
|
|
933
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_restart_request request_pb
|
|
934
|
+
query_string_params = if query_string_params.any?
|
|
935
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
936
|
+
else
|
|
937
|
+
{}
|
|
938
|
+
end
|
|
939
|
+
|
|
940
|
+
response = @client_stub.make_http_request(
|
|
941
|
+
verb,
|
|
942
|
+
uri: uri,
|
|
943
|
+
body: body || "",
|
|
944
|
+
params: query_string_params,
|
|
945
|
+
method_name: "restart",
|
|
946
|
+
options: options
|
|
947
|
+
)
|
|
948
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
949
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
950
|
+
catch :response do
|
|
951
|
+
yield result, operation if block_given?
|
|
952
|
+
result
|
|
953
|
+
end
|
|
954
|
+
end
|
|
955
|
+
|
|
956
|
+
##
|
|
957
|
+
# Baseline implementation for the restore_backup REST call
|
|
958
|
+
#
|
|
959
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRestoreBackupRequest]
|
|
960
|
+
# A request object representing the call parameters. Required.
|
|
961
|
+
# @param options [::Gapic::CallOptions]
|
|
962
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
963
|
+
#
|
|
964
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
965
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
966
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
967
|
+
#
|
|
968
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
969
|
+
# A result object deserialized from the server's reply
|
|
970
|
+
def restore_backup request_pb, options = nil
|
|
971
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
972
|
+
|
|
973
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_restore_backup_request request_pb
|
|
974
|
+
query_string_params = if query_string_params.any?
|
|
975
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
976
|
+
else
|
|
977
|
+
{}
|
|
978
|
+
end
|
|
979
|
+
|
|
980
|
+
response = @client_stub.make_http_request(
|
|
981
|
+
verb,
|
|
982
|
+
uri: uri,
|
|
983
|
+
body: body || "",
|
|
984
|
+
params: query_string_params,
|
|
985
|
+
method_name: "restore_backup",
|
|
986
|
+
options: options
|
|
987
|
+
)
|
|
988
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
989
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
990
|
+
catch :response do
|
|
991
|
+
yield result, operation if block_given?
|
|
992
|
+
result
|
|
993
|
+
end
|
|
994
|
+
end
|
|
995
|
+
|
|
996
|
+
##
|
|
997
|
+
# Baseline implementation for the rotate_server_ca REST call
|
|
998
|
+
#
|
|
999
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateServerCaRequest]
|
|
1000
|
+
# A request object representing the call parameters. Required.
|
|
1001
|
+
# @param options [::Gapic::CallOptions]
|
|
1002
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1003
|
+
#
|
|
1004
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1005
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1006
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1007
|
+
#
|
|
1008
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1009
|
+
# A result object deserialized from the server's reply
|
|
1010
|
+
def rotate_server_ca request_pb, options = nil
|
|
1011
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1012
|
+
|
|
1013
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_rotate_server_ca_request request_pb
|
|
1014
|
+
query_string_params = if query_string_params.any?
|
|
1015
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1016
|
+
else
|
|
1017
|
+
{}
|
|
1018
|
+
end
|
|
1019
|
+
|
|
1020
|
+
response = @client_stub.make_http_request(
|
|
1021
|
+
verb,
|
|
1022
|
+
uri: uri,
|
|
1023
|
+
body: body || "",
|
|
1024
|
+
params: query_string_params,
|
|
1025
|
+
method_name: "rotate_server_ca",
|
|
1026
|
+
options: options
|
|
1027
|
+
)
|
|
1028
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1029
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1030
|
+
catch :response do
|
|
1031
|
+
yield result, operation if block_given?
|
|
1032
|
+
result
|
|
1033
|
+
end
|
|
1034
|
+
end
|
|
1035
|
+
|
|
1036
|
+
##
|
|
1037
|
+
# Baseline implementation for the rotate_server_certificate REST call
|
|
1038
|
+
#
|
|
1039
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateServerCertificateRequest]
|
|
1040
|
+
# A request object representing the call parameters. Required.
|
|
1041
|
+
# @param options [::Gapic::CallOptions]
|
|
1042
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1043
|
+
#
|
|
1044
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1045
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1046
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1047
|
+
#
|
|
1048
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1049
|
+
# A result object deserialized from the server's reply
|
|
1050
|
+
def rotate_server_certificate request_pb, options = nil
|
|
1051
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1052
|
+
|
|
1053
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_rotate_server_certificate_request request_pb
|
|
1054
|
+
query_string_params = if query_string_params.any?
|
|
1055
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1056
|
+
else
|
|
1057
|
+
{}
|
|
1058
|
+
end
|
|
1059
|
+
|
|
1060
|
+
response = @client_stub.make_http_request(
|
|
1061
|
+
verb,
|
|
1062
|
+
uri: uri,
|
|
1063
|
+
body: body || "",
|
|
1064
|
+
params: query_string_params,
|
|
1065
|
+
method_name: "rotate_server_certificate",
|
|
1066
|
+
options: options
|
|
1067
|
+
)
|
|
1068
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1069
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1070
|
+
catch :response do
|
|
1071
|
+
yield result, operation if block_given?
|
|
1072
|
+
result
|
|
1073
|
+
end
|
|
1074
|
+
end
|
|
1075
|
+
|
|
1076
|
+
##
|
|
1077
|
+
# Baseline implementation for the rotate_entra_id_certificate REST call
|
|
1078
|
+
#
|
|
1079
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateEntraIdCertificateRequest]
|
|
1080
|
+
# A request object representing the call parameters. Required.
|
|
1081
|
+
# @param options [::Gapic::CallOptions]
|
|
1082
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1083
|
+
#
|
|
1084
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1085
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1086
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1087
|
+
#
|
|
1088
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1089
|
+
# A result object deserialized from the server's reply
|
|
1090
|
+
def rotate_entra_id_certificate request_pb, options = nil
|
|
1091
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1092
|
+
|
|
1093
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_rotate_entra_id_certificate_request request_pb
|
|
1094
|
+
query_string_params = if query_string_params.any?
|
|
1095
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1096
|
+
else
|
|
1097
|
+
{}
|
|
1098
|
+
end
|
|
1099
|
+
|
|
1100
|
+
response = @client_stub.make_http_request(
|
|
1101
|
+
verb,
|
|
1102
|
+
uri: uri,
|
|
1103
|
+
body: body || "",
|
|
1104
|
+
params: query_string_params,
|
|
1105
|
+
method_name: "rotate_entra_id_certificate",
|
|
1106
|
+
options: options
|
|
1107
|
+
)
|
|
1108
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1109
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1110
|
+
catch :response do
|
|
1111
|
+
yield result, operation if block_given?
|
|
1112
|
+
result
|
|
1113
|
+
end
|
|
1114
|
+
end
|
|
1115
|
+
|
|
1116
|
+
##
|
|
1117
|
+
# Baseline implementation for the start_replica REST call
|
|
1118
|
+
#
|
|
1119
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStartReplicaRequest]
|
|
1120
|
+
# A request object representing the call parameters. Required.
|
|
1121
|
+
# @param options [::Gapic::CallOptions]
|
|
1122
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1123
|
+
#
|
|
1124
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1125
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1126
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1127
|
+
#
|
|
1128
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1129
|
+
# A result object deserialized from the server's reply
|
|
1130
|
+
def start_replica request_pb, options = nil
|
|
1131
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1132
|
+
|
|
1133
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_start_replica_request request_pb
|
|
1134
|
+
query_string_params = if query_string_params.any?
|
|
1135
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1136
|
+
else
|
|
1137
|
+
{}
|
|
1138
|
+
end
|
|
1139
|
+
|
|
1140
|
+
response = @client_stub.make_http_request(
|
|
1141
|
+
verb,
|
|
1142
|
+
uri: uri,
|
|
1143
|
+
body: body || "",
|
|
1144
|
+
params: query_string_params,
|
|
1145
|
+
method_name: "start_replica",
|
|
1146
|
+
options: options
|
|
1147
|
+
)
|
|
1148
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1149
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1150
|
+
catch :response do
|
|
1151
|
+
yield result, operation if block_given?
|
|
1152
|
+
result
|
|
1153
|
+
end
|
|
1154
|
+
end
|
|
1155
|
+
|
|
1156
|
+
##
|
|
1157
|
+
# Baseline implementation for the stop_replica REST call
|
|
1158
|
+
#
|
|
1159
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStopReplicaRequest]
|
|
1160
|
+
# A request object representing the call parameters. Required.
|
|
1161
|
+
# @param options [::Gapic::CallOptions]
|
|
1162
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1163
|
+
#
|
|
1164
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1165
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1166
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1167
|
+
#
|
|
1168
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1169
|
+
# A result object deserialized from the server's reply
|
|
1170
|
+
def stop_replica request_pb, options = nil
|
|
1171
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1172
|
+
|
|
1173
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_stop_replica_request request_pb
|
|
1174
|
+
query_string_params = if query_string_params.any?
|
|
1175
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1176
|
+
else
|
|
1177
|
+
{}
|
|
1178
|
+
end
|
|
1179
|
+
|
|
1180
|
+
response = @client_stub.make_http_request(
|
|
1181
|
+
verb,
|
|
1182
|
+
uri: uri,
|
|
1183
|
+
body: body || "",
|
|
1184
|
+
params: query_string_params,
|
|
1185
|
+
method_name: "stop_replica",
|
|
1186
|
+
options: options
|
|
1187
|
+
)
|
|
1188
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1189
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1190
|
+
catch :response do
|
|
1191
|
+
yield result, operation if block_given?
|
|
1192
|
+
result
|
|
1193
|
+
end
|
|
1194
|
+
end
|
|
1195
|
+
|
|
1196
|
+
##
|
|
1197
|
+
# Baseline implementation for the truncate_log REST call
|
|
1198
|
+
#
|
|
1199
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesTruncateLogRequest]
|
|
1200
|
+
# A request object representing the call parameters. Required.
|
|
1201
|
+
# @param options [::Gapic::CallOptions]
|
|
1202
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1203
|
+
#
|
|
1204
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1205
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1206
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1207
|
+
#
|
|
1208
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1209
|
+
# A result object deserialized from the server's reply
|
|
1210
|
+
def truncate_log request_pb, options = nil
|
|
1211
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1212
|
+
|
|
1213
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_truncate_log_request request_pb
|
|
1214
|
+
query_string_params = if query_string_params.any?
|
|
1215
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1216
|
+
else
|
|
1217
|
+
{}
|
|
1218
|
+
end
|
|
1219
|
+
|
|
1220
|
+
response = @client_stub.make_http_request(
|
|
1221
|
+
verb,
|
|
1222
|
+
uri: uri,
|
|
1223
|
+
body: body || "",
|
|
1224
|
+
params: query_string_params,
|
|
1225
|
+
method_name: "truncate_log",
|
|
1226
|
+
options: options
|
|
1227
|
+
)
|
|
1228
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1229
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1230
|
+
catch :response do
|
|
1231
|
+
yield result, operation if block_given?
|
|
1232
|
+
result
|
|
1233
|
+
end
|
|
1234
|
+
end
|
|
1235
|
+
|
|
1236
|
+
##
|
|
1237
|
+
# Baseline implementation for the update REST call
|
|
1238
|
+
#
|
|
1239
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesUpdateRequest]
|
|
1240
|
+
# A request object representing the call parameters. Required.
|
|
1241
|
+
# @param options [::Gapic::CallOptions]
|
|
1242
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1243
|
+
#
|
|
1244
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1245
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1246
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1247
|
+
#
|
|
1248
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1249
|
+
# A result object deserialized from the server's reply
|
|
1250
|
+
def update request_pb, options = nil
|
|
1251
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1252
|
+
|
|
1253
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_request request_pb
|
|
1254
|
+
query_string_params = if query_string_params.any?
|
|
1255
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1256
|
+
else
|
|
1257
|
+
{}
|
|
1258
|
+
end
|
|
1259
|
+
|
|
1260
|
+
response = @client_stub.make_http_request(
|
|
1261
|
+
verb,
|
|
1262
|
+
uri: uri,
|
|
1263
|
+
body: body || "",
|
|
1264
|
+
params: query_string_params,
|
|
1265
|
+
method_name: "update",
|
|
1266
|
+
options: options
|
|
1267
|
+
)
|
|
1268
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1269
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1270
|
+
catch :response do
|
|
1271
|
+
yield result, operation if block_given?
|
|
1272
|
+
result
|
|
1273
|
+
end
|
|
1274
|
+
end
|
|
1275
|
+
|
|
1276
|
+
##
|
|
1277
|
+
# Baseline implementation for the create_ephemeral REST call
|
|
1278
|
+
#
|
|
1279
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesCreateEphemeralCertRequest]
|
|
1280
|
+
# A request object representing the call parameters. Required.
|
|
1281
|
+
# @param options [::Gapic::CallOptions]
|
|
1282
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1283
|
+
#
|
|
1284
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1285
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SslCert]
|
|
1286
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1287
|
+
#
|
|
1288
|
+
# @return [::Google::Cloud::Sql::V1::SslCert]
|
|
1289
|
+
# A result object deserialized from the server's reply
|
|
1290
|
+
def create_ephemeral request_pb, options = nil
|
|
1291
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1292
|
+
|
|
1293
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_ephemeral_request request_pb
|
|
1294
|
+
query_string_params = if query_string_params.any?
|
|
1295
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1296
|
+
else
|
|
1297
|
+
{}
|
|
1298
|
+
end
|
|
1299
|
+
|
|
1300
|
+
response = @client_stub.make_http_request(
|
|
1301
|
+
verb,
|
|
1302
|
+
uri: uri,
|
|
1303
|
+
body: body || "",
|
|
1304
|
+
params: query_string_params,
|
|
1305
|
+
method_name: "create_ephemeral",
|
|
1306
|
+
options: options
|
|
1307
|
+
)
|
|
1308
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1309
|
+
result = ::Google::Cloud::Sql::V1::SslCert.decode_json response.body, ignore_unknown_fields: true
|
|
1310
|
+
catch :response do
|
|
1311
|
+
yield result, operation if block_given?
|
|
1312
|
+
result
|
|
1313
|
+
end
|
|
1314
|
+
end
|
|
1315
|
+
|
|
1316
|
+
##
|
|
1317
|
+
# Baseline implementation for the reschedule_maintenance REST call
|
|
1318
|
+
#
|
|
1319
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRescheduleMaintenanceRequest]
|
|
1320
|
+
# A request object representing the call parameters. Required.
|
|
1321
|
+
# @param options [::Gapic::CallOptions]
|
|
1322
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1323
|
+
#
|
|
1324
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1325
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1326
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1327
|
+
#
|
|
1328
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1329
|
+
# A result object deserialized from the server's reply
|
|
1330
|
+
def reschedule_maintenance request_pb, options = nil
|
|
1331
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1332
|
+
|
|
1333
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_reschedule_maintenance_request request_pb
|
|
1334
|
+
query_string_params = if query_string_params.any?
|
|
1335
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1336
|
+
else
|
|
1337
|
+
{}
|
|
1338
|
+
end
|
|
1339
|
+
|
|
1340
|
+
response = @client_stub.make_http_request(
|
|
1341
|
+
verb,
|
|
1342
|
+
uri: uri,
|
|
1343
|
+
body: body || "",
|
|
1344
|
+
params: query_string_params,
|
|
1345
|
+
method_name: "reschedule_maintenance",
|
|
1346
|
+
options: options
|
|
1347
|
+
)
|
|
1348
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1349
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1350
|
+
catch :response do
|
|
1351
|
+
yield result, operation if block_given?
|
|
1352
|
+
result
|
|
1353
|
+
end
|
|
1354
|
+
end
|
|
1355
|
+
|
|
1356
|
+
##
|
|
1357
|
+
# Baseline implementation for the verify_external_sync_settings REST call
|
|
1358
|
+
#
|
|
1359
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesVerifyExternalSyncSettingsRequest]
|
|
1360
|
+
# A request object representing the call parameters. Required.
|
|
1361
|
+
# @param options [::Gapic::CallOptions]
|
|
1362
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1363
|
+
#
|
|
1364
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1365
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesVerifyExternalSyncSettingsResponse]
|
|
1366
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1367
|
+
#
|
|
1368
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesVerifyExternalSyncSettingsResponse]
|
|
1369
|
+
# A result object deserialized from the server's reply
|
|
1370
|
+
def verify_external_sync_settings request_pb, options = nil
|
|
1371
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1372
|
+
|
|
1373
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_verify_external_sync_settings_request request_pb
|
|
1374
|
+
query_string_params = if query_string_params.any?
|
|
1375
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1376
|
+
else
|
|
1377
|
+
{}
|
|
1378
|
+
end
|
|
1379
|
+
|
|
1380
|
+
response = @client_stub.make_http_request(
|
|
1381
|
+
verb,
|
|
1382
|
+
uri: uri,
|
|
1383
|
+
body: body || "",
|
|
1384
|
+
params: query_string_params,
|
|
1385
|
+
method_name: "verify_external_sync_settings",
|
|
1386
|
+
options: options
|
|
1387
|
+
)
|
|
1388
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1389
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesVerifyExternalSyncSettingsResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1390
|
+
catch :response do
|
|
1391
|
+
yield result, operation if block_given?
|
|
1392
|
+
result
|
|
1393
|
+
end
|
|
1394
|
+
end
|
|
1395
|
+
|
|
1396
|
+
##
|
|
1397
|
+
# Baseline implementation for the start_external_sync REST call
|
|
1398
|
+
#
|
|
1399
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStartExternalSyncRequest]
|
|
1400
|
+
# A request object representing the call parameters. Required.
|
|
1401
|
+
# @param options [::Gapic::CallOptions]
|
|
1402
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1403
|
+
#
|
|
1404
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1405
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1406
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1407
|
+
#
|
|
1408
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1409
|
+
# A result object deserialized from the server's reply
|
|
1410
|
+
def start_external_sync request_pb, options = nil
|
|
1411
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1412
|
+
|
|
1413
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_start_external_sync_request request_pb
|
|
1414
|
+
query_string_params = if query_string_params.any?
|
|
1415
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1416
|
+
else
|
|
1417
|
+
{}
|
|
1418
|
+
end
|
|
1419
|
+
|
|
1420
|
+
response = @client_stub.make_http_request(
|
|
1421
|
+
verb,
|
|
1422
|
+
uri: uri,
|
|
1423
|
+
body: body || "",
|
|
1424
|
+
params: query_string_params,
|
|
1425
|
+
method_name: "start_external_sync",
|
|
1426
|
+
options: options
|
|
1427
|
+
)
|
|
1428
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1429
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1430
|
+
catch :response do
|
|
1431
|
+
yield result, operation if block_given?
|
|
1432
|
+
result
|
|
1433
|
+
end
|
|
1434
|
+
end
|
|
1435
|
+
|
|
1436
|
+
##
|
|
1437
|
+
# Baseline implementation for the perform_disk_shrink REST call
|
|
1438
|
+
#
|
|
1439
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPerformDiskShrinkRequest]
|
|
1440
|
+
# A request object representing the call parameters. Required.
|
|
1441
|
+
# @param options [::Gapic::CallOptions]
|
|
1442
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1443
|
+
#
|
|
1444
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1445
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1446
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1447
|
+
#
|
|
1448
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1449
|
+
# A result object deserialized from the server's reply
|
|
1450
|
+
def perform_disk_shrink request_pb, options = nil
|
|
1451
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1452
|
+
|
|
1453
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_perform_disk_shrink_request request_pb
|
|
1454
|
+
query_string_params = if query_string_params.any?
|
|
1455
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1456
|
+
else
|
|
1457
|
+
{}
|
|
1458
|
+
end
|
|
1459
|
+
|
|
1460
|
+
response = @client_stub.make_http_request(
|
|
1461
|
+
verb,
|
|
1462
|
+
uri: uri,
|
|
1463
|
+
body: body || "",
|
|
1464
|
+
params: query_string_params,
|
|
1465
|
+
method_name: "perform_disk_shrink",
|
|
1466
|
+
options: options
|
|
1467
|
+
)
|
|
1468
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1469
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1470
|
+
catch :response do
|
|
1471
|
+
yield result, operation if block_given?
|
|
1472
|
+
result
|
|
1473
|
+
end
|
|
1474
|
+
end
|
|
1475
|
+
|
|
1476
|
+
##
|
|
1477
|
+
# Baseline implementation for the get_disk_shrink_config REST call
|
|
1478
|
+
#
|
|
1479
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetDiskShrinkConfigRequest]
|
|
1480
|
+
# A request object representing the call parameters. Required.
|
|
1481
|
+
# @param options [::Gapic::CallOptions]
|
|
1482
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1483
|
+
#
|
|
1484
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1485
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesGetDiskShrinkConfigResponse]
|
|
1486
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1487
|
+
#
|
|
1488
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesGetDiskShrinkConfigResponse]
|
|
1489
|
+
# A result object deserialized from the server's reply
|
|
1490
|
+
def get_disk_shrink_config request_pb, options = nil
|
|
1491
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1492
|
+
|
|
1493
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_disk_shrink_config_request request_pb
|
|
1494
|
+
query_string_params = if query_string_params.any?
|
|
1495
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1496
|
+
else
|
|
1497
|
+
{}
|
|
1498
|
+
end
|
|
1499
|
+
|
|
1500
|
+
response = @client_stub.make_http_request(
|
|
1501
|
+
verb,
|
|
1502
|
+
uri: uri,
|
|
1503
|
+
body: body || "",
|
|
1504
|
+
params: query_string_params,
|
|
1505
|
+
method_name: "get_disk_shrink_config",
|
|
1506
|
+
options: options
|
|
1507
|
+
)
|
|
1508
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1509
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesGetDiskShrinkConfigResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1510
|
+
catch :response do
|
|
1511
|
+
yield result, operation if block_given?
|
|
1512
|
+
result
|
|
1513
|
+
end
|
|
1514
|
+
end
|
|
1515
|
+
|
|
1516
|
+
##
|
|
1517
|
+
# Baseline implementation for the reset_replica_size REST call
|
|
1518
|
+
#
|
|
1519
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesResetReplicaSizeRequest]
|
|
1520
|
+
# A request object representing the call parameters. Required.
|
|
1521
|
+
# @param options [::Gapic::CallOptions]
|
|
1522
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1523
|
+
#
|
|
1524
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1525
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1526
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1527
|
+
#
|
|
1528
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1529
|
+
# A result object deserialized from the server's reply
|
|
1530
|
+
def reset_replica_size request_pb, options = nil
|
|
1531
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1532
|
+
|
|
1533
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_reset_replica_size_request request_pb
|
|
1534
|
+
query_string_params = if query_string_params.any?
|
|
1535
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1536
|
+
else
|
|
1537
|
+
{}
|
|
1538
|
+
end
|
|
1539
|
+
|
|
1540
|
+
response = @client_stub.make_http_request(
|
|
1541
|
+
verb,
|
|
1542
|
+
uri: uri,
|
|
1543
|
+
body: body || "",
|
|
1544
|
+
params: query_string_params,
|
|
1545
|
+
method_name: "reset_replica_size",
|
|
1546
|
+
options: options
|
|
1547
|
+
)
|
|
1548
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1549
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1550
|
+
catch :response do
|
|
1551
|
+
yield result, operation if block_given?
|
|
1552
|
+
result
|
|
1553
|
+
end
|
|
1554
|
+
end
|
|
1555
|
+
|
|
1556
|
+
##
|
|
1557
|
+
# Baseline implementation for the get_latest_recovery_time REST call
|
|
1558
|
+
#
|
|
1559
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetLatestRecoveryTimeRequest]
|
|
1560
|
+
# A request object representing the call parameters. Required.
|
|
1561
|
+
# @param options [::Gapic::CallOptions]
|
|
1562
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1563
|
+
#
|
|
1564
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1565
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesGetLatestRecoveryTimeResponse]
|
|
1566
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1567
|
+
#
|
|
1568
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesGetLatestRecoveryTimeResponse]
|
|
1569
|
+
# A result object deserialized from the server's reply
|
|
1570
|
+
def get_latest_recovery_time request_pb, options = nil
|
|
1571
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1572
|
+
|
|
1573
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_latest_recovery_time_request request_pb
|
|
1574
|
+
query_string_params = if query_string_params.any?
|
|
1575
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1576
|
+
else
|
|
1577
|
+
{}
|
|
1578
|
+
end
|
|
1579
|
+
|
|
1580
|
+
response = @client_stub.make_http_request(
|
|
1581
|
+
verb,
|
|
1582
|
+
uri: uri,
|
|
1583
|
+
body: body || "",
|
|
1584
|
+
params: query_string_params,
|
|
1585
|
+
method_name: "get_latest_recovery_time",
|
|
1586
|
+
options: options
|
|
1587
|
+
)
|
|
1588
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1589
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesGetLatestRecoveryTimeResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1590
|
+
catch :response do
|
|
1591
|
+
yield result, operation if block_given?
|
|
1592
|
+
result
|
|
1593
|
+
end
|
|
1594
|
+
end
|
|
1595
|
+
|
|
1596
|
+
##
|
|
1597
|
+
# Baseline implementation for the execute_sql REST call
|
|
1598
|
+
#
|
|
1599
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesExecuteSqlRequest]
|
|
1600
|
+
# A request object representing the call parameters. Required.
|
|
1601
|
+
# @param options [::Gapic::CallOptions]
|
|
1602
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1603
|
+
#
|
|
1604
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1605
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesExecuteSqlResponse]
|
|
1606
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1607
|
+
#
|
|
1608
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesExecuteSqlResponse]
|
|
1609
|
+
# A result object deserialized from the server's reply
|
|
1610
|
+
def execute_sql request_pb, options = nil
|
|
1611
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1612
|
+
|
|
1613
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_execute_sql_request request_pb
|
|
1614
|
+
query_string_params = if query_string_params.any?
|
|
1615
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1616
|
+
else
|
|
1617
|
+
{}
|
|
1618
|
+
end
|
|
1619
|
+
|
|
1620
|
+
response = @client_stub.make_http_request(
|
|
1621
|
+
verb,
|
|
1622
|
+
uri: uri,
|
|
1623
|
+
body: body || "",
|
|
1624
|
+
params: query_string_params,
|
|
1625
|
+
method_name: "execute_sql",
|
|
1626
|
+
options: options
|
|
1627
|
+
)
|
|
1628
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1629
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesExecuteSqlResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1630
|
+
catch :response do
|
|
1631
|
+
yield result, operation if block_given?
|
|
1632
|
+
result
|
|
1633
|
+
end
|
|
1634
|
+
end
|
|
1635
|
+
|
|
1636
|
+
##
|
|
1637
|
+
# Baseline implementation for the acquire_ssrs_lease REST call
|
|
1638
|
+
#
|
|
1639
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAcquireSsrsLeaseRequest]
|
|
1640
|
+
# A request object representing the call parameters. Required.
|
|
1641
|
+
# @param options [::Gapic::CallOptions]
|
|
1642
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1643
|
+
#
|
|
1644
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1645
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesAcquireSsrsLeaseResponse]
|
|
1646
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1647
|
+
#
|
|
1648
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesAcquireSsrsLeaseResponse]
|
|
1649
|
+
# A result object deserialized from the server's reply
|
|
1650
|
+
def acquire_ssrs_lease request_pb, options = nil
|
|
1651
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1652
|
+
|
|
1653
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_acquire_ssrs_lease_request request_pb
|
|
1654
|
+
query_string_params = if query_string_params.any?
|
|
1655
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1656
|
+
else
|
|
1657
|
+
{}
|
|
1658
|
+
end
|
|
1659
|
+
|
|
1660
|
+
response = @client_stub.make_http_request(
|
|
1661
|
+
verb,
|
|
1662
|
+
uri: uri,
|
|
1663
|
+
body: body || "",
|
|
1664
|
+
params: query_string_params,
|
|
1665
|
+
method_name: "acquire_ssrs_lease",
|
|
1666
|
+
options: options
|
|
1667
|
+
)
|
|
1668
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1669
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesAcquireSsrsLeaseResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1670
|
+
catch :response do
|
|
1671
|
+
yield result, operation if block_given?
|
|
1672
|
+
result
|
|
1673
|
+
end
|
|
1674
|
+
end
|
|
1675
|
+
|
|
1676
|
+
##
|
|
1677
|
+
# Baseline implementation for the release_ssrs_lease REST call
|
|
1678
|
+
#
|
|
1679
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesReleaseSsrsLeaseRequest]
|
|
1680
|
+
# A request object representing the call parameters. Required.
|
|
1681
|
+
# @param options [::Gapic::CallOptions]
|
|
1682
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1683
|
+
#
|
|
1684
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1685
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::SqlInstancesReleaseSsrsLeaseResponse]
|
|
1686
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1687
|
+
#
|
|
1688
|
+
# @return [::Google::Cloud::Sql::V1::SqlInstancesReleaseSsrsLeaseResponse]
|
|
1689
|
+
# A result object deserialized from the server's reply
|
|
1690
|
+
def release_ssrs_lease request_pb, options = nil
|
|
1691
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1692
|
+
|
|
1693
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_release_ssrs_lease_request request_pb
|
|
1694
|
+
query_string_params = if query_string_params.any?
|
|
1695
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1696
|
+
else
|
|
1697
|
+
{}
|
|
1698
|
+
end
|
|
1699
|
+
|
|
1700
|
+
response = @client_stub.make_http_request(
|
|
1701
|
+
verb,
|
|
1702
|
+
uri: uri,
|
|
1703
|
+
body: body || "",
|
|
1704
|
+
params: query_string_params,
|
|
1705
|
+
method_name: "release_ssrs_lease",
|
|
1706
|
+
options: options
|
|
1707
|
+
)
|
|
1708
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1709
|
+
result = ::Google::Cloud::Sql::V1::SqlInstancesReleaseSsrsLeaseResponse.decode_json response.body, ignore_unknown_fields: true
|
|
1710
|
+
catch :response do
|
|
1711
|
+
yield result, operation if block_given?
|
|
1712
|
+
result
|
|
1713
|
+
end
|
|
1714
|
+
end
|
|
1715
|
+
|
|
1716
|
+
##
|
|
1717
|
+
# Baseline implementation for the pre_check_major_version_upgrade REST call
|
|
1718
|
+
#
|
|
1719
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPreCheckMajorVersionUpgradeRequest]
|
|
1720
|
+
# A request object representing the call parameters. Required.
|
|
1721
|
+
# @param options [::Gapic::CallOptions]
|
|
1722
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1723
|
+
#
|
|
1724
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1725
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1726
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1727
|
+
#
|
|
1728
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1729
|
+
# A result object deserialized from the server's reply
|
|
1730
|
+
def pre_check_major_version_upgrade request_pb, options = nil
|
|
1731
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1732
|
+
|
|
1733
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_pre_check_major_version_upgrade_request request_pb
|
|
1734
|
+
query_string_params = if query_string_params.any?
|
|
1735
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1736
|
+
else
|
|
1737
|
+
{}
|
|
1738
|
+
end
|
|
1739
|
+
|
|
1740
|
+
response = @client_stub.make_http_request(
|
|
1741
|
+
verb,
|
|
1742
|
+
uri: uri,
|
|
1743
|
+
body: body || "",
|
|
1744
|
+
params: query_string_params,
|
|
1745
|
+
method_name: "pre_check_major_version_upgrade",
|
|
1746
|
+
options: options
|
|
1747
|
+
)
|
|
1748
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1749
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1750
|
+
catch :response do
|
|
1751
|
+
yield result, operation if block_given?
|
|
1752
|
+
result
|
|
1753
|
+
end
|
|
1754
|
+
end
|
|
1755
|
+
|
|
1756
|
+
##
|
|
1757
|
+
# Baseline implementation for the point_in_time_restore REST call
|
|
1758
|
+
#
|
|
1759
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPointInTimeRestoreRequest]
|
|
1760
|
+
# A request object representing the call parameters. Required.
|
|
1761
|
+
# @param options [::Gapic::CallOptions]
|
|
1762
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1763
|
+
#
|
|
1764
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1765
|
+
# @yieldparam result [::Google::Cloud::Sql::V1::Operation]
|
|
1766
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1767
|
+
#
|
|
1768
|
+
# @return [::Google::Cloud::Sql::V1::Operation]
|
|
1769
|
+
# A result object deserialized from the server's reply
|
|
1770
|
+
def point_in_time_restore request_pb, options = nil
|
|
1771
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
1772
|
+
|
|
1773
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_point_in_time_restore_request request_pb
|
|
1774
|
+
query_string_params = if query_string_params.any?
|
|
1775
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
1776
|
+
else
|
|
1777
|
+
{}
|
|
1778
|
+
end
|
|
1779
|
+
|
|
1780
|
+
response = @client_stub.make_http_request(
|
|
1781
|
+
verb,
|
|
1782
|
+
uri: uri,
|
|
1783
|
+
body: body || "",
|
|
1784
|
+
params: query_string_params,
|
|
1785
|
+
method_name: "point_in_time_restore",
|
|
1786
|
+
options: options
|
|
1787
|
+
)
|
|
1788
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
1789
|
+
result = ::Google::Cloud::Sql::V1::Operation.decode_json response.body, ignore_unknown_fields: true
|
|
1790
|
+
catch :response do
|
|
1791
|
+
yield result, operation if block_given?
|
|
1792
|
+
result
|
|
1793
|
+
end
|
|
1794
|
+
end
|
|
1795
|
+
|
|
1796
|
+
##
|
|
1797
|
+
# @private
|
|
1798
|
+
#
|
|
1799
|
+
# GRPC transcoding helper method for the add_server_ca REST call
|
|
1800
|
+
#
|
|
1801
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddServerCaRequest]
|
|
1802
|
+
# A request object representing the call parameters. Required.
|
|
1803
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1804
|
+
# Uri, Body, Query string parameters
|
|
1805
|
+
def self.transcode_add_server_ca_request request_pb
|
|
1806
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1807
|
+
.with_bindings(
|
|
1808
|
+
uri_method: :post,
|
|
1809
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/addServerCa",
|
|
1810
|
+
matches: [
|
|
1811
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1812
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1813
|
+
]
|
|
1814
|
+
)
|
|
1815
|
+
transcoder.transcode request_pb
|
|
1816
|
+
end
|
|
1817
|
+
|
|
1818
|
+
##
|
|
1819
|
+
# @private
|
|
1820
|
+
#
|
|
1821
|
+
# GRPC transcoding helper method for the add_server_certificate REST call
|
|
1822
|
+
#
|
|
1823
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddServerCertificateRequest]
|
|
1824
|
+
# A request object representing the call parameters. Required.
|
|
1825
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1826
|
+
# Uri, Body, Query string parameters
|
|
1827
|
+
def self.transcode_add_server_certificate_request request_pb
|
|
1828
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1829
|
+
.with_bindings(
|
|
1830
|
+
uri_method: :post,
|
|
1831
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/addServerCertificate",
|
|
1832
|
+
matches: [
|
|
1833
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1834
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1835
|
+
]
|
|
1836
|
+
)
|
|
1837
|
+
transcoder.transcode request_pb
|
|
1838
|
+
end
|
|
1839
|
+
|
|
1840
|
+
##
|
|
1841
|
+
# @private
|
|
1842
|
+
#
|
|
1843
|
+
# GRPC transcoding helper method for the add_entra_id_certificate REST call
|
|
1844
|
+
#
|
|
1845
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAddEntraIdCertificateRequest]
|
|
1846
|
+
# A request object representing the call parameters. Required.
|
|
1847
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1848
|
+
# Uri, Body, Query string parameters
|
|
1849
|
+
def self.transcode_add_entra_id_certificate_request request_pb
|
|
1850
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1851
|
+
.with_bindings(
|
|
1852
|
+
uri_method: :post,
|
|
1853
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/addEntraIdCertificate",
|
|
1854
|
+
matches: [
|
|
1855
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1856
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1857
|
+
]
|
|
1858
|
+
)
|
|
1859
|
+
transcoder.transcode request_pb
|
|
1860
|
+
end
|
|
1861
|
+
|
|
1862
|
+
##
|
|
1863
|
+
# @private
|
|
1864
|
+
#
|
|
1865
|
+
# GRPC transcoding helper method for the call_clone REST call
|
|
1866
|
+
#
|
|
1867
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesCloneRequest]
|
|
1868
|
+
# A request object representing the call parameters. Required.
|
|
1869
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1870
|
+
# Uri, Body, Query string parameters
|
|
1871
|
+
def self.transcode_call_clone_request request_pb
|
|
1872
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1873
|
+
.with_bindings(
|
|
1874
|
+
uri_method: :post,
|
|
1875
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/clone",
|
|
1876
|
+
body: "body",
|
|
1877
|
+
matches: [
|
|
1878
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1879
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1880
|
+
]
|
|
1881
|
+
)
|
|
1882
|
+
transcoder.transcode request_pb
|
|
1883
|
+
end
|
|
1884
|
+
|
|
1885
|
+
##
|
|
1886
|
+
# @private
|
|
1887
|
+
#
|
|
1888
|
+
# GRPC transcoding helper method for the delete REST call
|
|
1889
|
+
#
|
|
1890
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDeleteRequest]
|
|
1891
|
+
# A request object representing the call parameters. Required.
|
|
1892
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1893
|
+
# Uri, Body, Query string parameters
|
|
1894
|
+
def self.transcode_delete_request request_pb
|
|
1895
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1896
|
+
.with_bindings(
|
|
1897
|
+
uri_method: :delete,
|
|
1898
|
+
uri_template: "/v1/projects/{project}/instances/{instance}",
|
|
1899
|
+
matches: [
|
|
1900
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1901
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1902
|
+
]
|
|
1903
|
+
)
|
|
1904
|
+
transcoder.transcode request_pb
|
|
1905
|
+
end
|
|
1906
|
+
|
|
1907
|
+
##
|
|
1908
|
+
# @private
|
|
1909
|
+
#
|
|
1910
|
+
# GRPC transcoding helper method for the demote_master REST call
|
|
1911
|
+
#
|
|
1912
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDemoteMasterRequest]
|
|
1913
|
+
# A request object representing the call parameters. Required.
|
|
1914
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1915
|
+
# Uri, Body, Query string parameters
|
|
1916
|
+
def self.transcode_demote_master_request request_pb
|
|
1917
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1918
|
+
.with_bindings(
|
|
1919
|
+
uri_method: :post,
|
|
1920
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/demoteMaster",
|
|
1921
|
+
body: "body",
|
|
1922
|
+
matches: [
|
|
1923
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1924
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1925
|
+
]
|
|
1926
|
+
)
|
|
1927
|
+
transcoder.transcode request_pb
|
|
1928
|
+
end
|
|
1929
|
+
|
|
1930
|
+
##
|
|
1931
|
+
# @private
|
|
1932
|
+
#
|
|
1933
|
+
# GRPC transcoding helper method for the demote REST call
|
|
1934
|
+
#
|
|
1935
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesDemoteRequest]
|
|
1936
|
+
# A request object representing the call parameters. Required.
|
|
1937
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1938
|
+
# Uri, Body, Query string parameters
|
|
1939
|
+
def self.transcode_demote_request request_pb
|
|
1940
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1941
|
+
.with_bindings(
|
|
1942
|
+
uri_method: :post,
|
|
1943
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/demote",
|
|
1944
|
+
body: "body",
|
|
1945
|
+
matches: [
|
|
1946
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1947
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1948
|
+
]
|
|
1949
|
+
)
|
|
1950
|
+
transcoder.transcode request_pb
|
|
1951
|
+
end
|
|
1952
|
+
|
|
1953
|
+
##
|
|
1954
|
+
# @private
|
|
1955
|
+
#
|
|
1956
|
+
# GRPC transcoding helper method for the export REST call
|
|
1957
|
+
#
|
|
1958
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesExportRequest]
|
|
1959
|
+
# A request object representing the call parameters. Required.
|
|
1960
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1961
|
+
# Uri, Body, Query string parameters
|
|
1962
|
+
def self.transcode_export_request request_pb
|
|
1963
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1964
|
+
.with_bindings(
|
|
1965
|
+
uri_method: :post,
|
|
1966
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/export",
|
|
1967
|
+
body: "body",
|
|
1968
|
+
matches: [
|
|
1969
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1970
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1971
|
+
]
|
|
1972
|
+
)
|
|
1973
|
+
transcoder.transcode request_pb
|
|
1974
|
+
end
|
|
1975
|
+
|
|
1976
|
+
##
|
|
1977
|
+
# @private
|
|
1978
|
+
#
|
|
1979
|
+
# GRPC transcoding helper method for the failover REST call
|
|
1980
|
+
#
|
|
1981
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesFailoverRequest]
|
|
1982
|
+
# A request object representing the call parameters. Required.
|
|
1983
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1984
|
+
# Uri, Body, Query string parameters
|
|
1985
|
+
def self.transcode_failover_request request_pb
|
|
1986
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1987
|
+
.with_bindings(
|
|
1988
|
+
uri_method: :post,
|
|
1989
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/failover",
|
|
1990
|
+
body: "body",
|
|
1991
|
+
matches: [
|
|
1992
|
+
["project", %r{^[^/]+/?$}, false],
|
|
1993
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
1994
|
+
]
|
|
1995
|
+
)
|
|
1996
|
+
transcoder.transcode request_pb
|
|
1997
|
+
end
|
|
1998
|
+
|
|
1999
|
+
##
|
|
2000
|
+
# @private
|
|
2001
|
+
#
|
|
2002
|
+
# GRPC transcoding helper method for the reencrypt REST call
|
|
2003
|
+
#
|
|
2004
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesReencryptRequest]
|
|
2005
|
+
# A request object representing the call parameters. Required.
|
|
2006
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2007
|
+
# Uri, Body, Query string parameters
|
|
2008
|
+
def self.transcode_reencrypt_request request_pb
|
|
2009
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2010
|
+
.with_bindings(
|
|
2011
|
+
uri_method: :post,
|
|
2012
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/reencrypt",
|
|
2013
|
+
body: "body",
|
|
2014
|
+
matches: [
|
|
2015
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2016
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2017
|
+
]
|
|
2018
|
+
)
|
|
2019
|
+
transcoder.transcode request_pb
|
|
2020
|
+
end
|
|
2021
|
+
|
|
2022
|
+
##
|
|
2023
|
+
# @private
|
|
2024
|
+
#
|
|
2025
|
+
# GRPC transcoding helper method for the get REST call
|
|
2026
|
+
#
|
|
2027
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetRequest]
|
|
2028
|
+
# A request object representing the call parameters. Required.
|
|
2029
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2030
|
+
# Uri, Body, Query string parameters
|
|
2031
|
+
def self.transcode_get_request request_pb
|
|
2032
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2033
|
+
.with_bindings(
|
|
2034
|
+
uri_method: :get,
|
|
2035
|
+
uri_template: "/v1/projects/{project}/instances/{instance}",
|
|
2036
|
+
matches: [
|
|
2037
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2038
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2039
|
+
]
|
|
2040
|
+
)
|
|
2041
|
+
transcoder.transcode request_pb
|
|
2042
|
+
end
|
|
2043
|
+
|
|
2044
|
+
##
|
|
2045
|
+
# @private
|
|
2046
|
+
#
|
|
2047
|
+
# GRPC transcoding helper method for the import REST call
|
|
2048
|
+
#
|
|
2049
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesImportRequest]
|
|
2050
|
+
# A request object representing the call parameters. Required.
|
|
2051
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2052
|
+
# Uri, Body, Query string parameters
|
|
2053
|
+
def self.transcode_import_request request_pb
|
|
2054
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2055
|
+
.with_bindings(
|
|
2056
|
+
uri_method: :post,
|
|
2057
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/import",
|
|
2058
|
+
body: "body",
|
|
2059
|
+
matches: [
|
|
2060
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2061
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2062
|
+
]
|
|
2063
|
+
)
|
|
2064
|
+
transcoder.transcode request_pb
|
|
2065
|
+
end
|
|
2066
|
+
|
|
2067
|
+
##
|
|
2068
|
+
# @private
|
|
2069
|
+
#
|
|
2070
|
+
# GRPC transcoding helper method for the insert REST call
|
|
2071
|
+
#
|
|
2072
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesInsertRequest]
|
|
2073
|
+
# A request object representing the call parameters. Required.
|
|
2074
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2075
|
+
# Uri, Body, Query string parameters
|
|
2076
|
+
def self.transcode_insert_request request_pb
|
|
2077
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2078
|
+
.with_bindings(
|
|
2079
|
+
uri_method: :post,
|
|
2080
|
+
uri_template: "/v1/projects/{project}/instances",
|
|
2081
|
+
body: "body",
|
|
2082
|
+
matches: [
|
|
2083
|
+
["project", %r{^[^/]+/?$}, false]
|
|
2084
|
+
]
|
|
2085
|
+
)
|
|
2086
|
+
transcoder.transcode request_pb
|
|
2087
|
+
end
|
|
2088
|
+
|
|
2089
|
+
##
|
|
2090
|
+
# @private
|
|
2091
|
+
#
|
|
2092
|
+
# GRPC transcoding helper method for the list REST call
|
|
2093
|
+
#
|
|
2094
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListRequest]
|
|
2095
|
+
# A request object representing the call parameters. Required.
|
|
2096
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2097
|
+
# Uri, Body, Query string parameters
|
|
2098
|
+
def self.transcode_list_request request_pb
|
|
2099
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2100
|
+
.with_bindings(
|
|
2101
|
+
uri_method: :get,
|
|
2102
|
+
uri_template: "/v1/projects/{project}/instances",
|
|
2103
|
+
matches: [
|
|
2104
|
+
["project", %r{^[^/]+/?$}, false]
|
|
2105
|
+
]
|
|
2106
|
+
)
|
|
2107
|
+
transcoder.transcode request_pb
|
|
2108
|
+
end
|
|
2109
|
+
|
|
2110
|
+
##
|
|
2111
|
+
# @private
|
|
2112
|
+
#
|
|
2113
|
+
# GRPC transcoding helper method for the list_server_cas REST call
|
|
2114
|
+
#
|
|
2115
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListServerCasRequest]
|
|
2116
|
+
# A request object representing the call parameters. Required.
|
|
2117
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2118
|
+
# Uri, Body, Query string parameters
|
|
2119
|
+
def self.transcode_list_server_cas_request request_pb
|
|
2120
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2121
|
+
.with_bindings(
|
|
2122
|
+
uri_method: :get,
|
|
2123
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/listServerCas",
|
|
2124
|
+
matches: [
|
|
2125
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2126
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2127
|
+
]
|
|
2128
|
+
)
|
|
2129
|
+
transcoder.transcode request_pb
|
|
2130
|
+
end
|
|
2131
|
+
|
|
2132
|
+
##
|
|
2133
|
+
# @private
|
|
2134
|
+
#
|
|
2135
|
+
# GRPC transcoding helper method for the list_server_certificates REST call
|
|
2136
|
+
#
|
|
2137
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListServerCertificatesRequest]
|
|
2138
|
+
# A request object representing the call parameters. Required.
|
|
2139
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2140
|
+
# Uri, Body, Query string parameters
|
|
2141
|
+
def self.transcode_list_server_certificates_request request_pb
|
|
2142
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2143
|
+
.with_bindings(
|
|
2144
|
+
uri_method: :get,
|
|
2145
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/listServerCertificates",
|
|
2146
|
+
matches: [
|
|
2147
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2148
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2149
|
+
]
|
|
2150
|
+
)
|
|
2151
|
+
transcoder.transcode request_pb
|
|
2152
|
+
end
|
|
2153
|
+
|
|
2154
|
+
##
|
|
2155
|
+
# @private
|
|
2156
|
+
#
|
|
2157
|
+
# GRPC transcoding helper method for the list_entra_id_certificates REST call
|
|
2158
|
+
#
|
|
2159
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesListEntraIdCertificatesRequest]
|
|
2160
|
+
# A request object representing the call parameters. Required.
|
|
2161
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2162
|
+
# Uri, Body, Query string parameters
|
|
2163
|
+
def self.transcode_list_entra_id_certificates_request request_pb
|
|
2164
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2165
|
+
.with_bindings(
|
|
2166
|
+
uri_method: :get,
|
|
2167
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/listEntraIdCertificates",
|
|
2168
|
+
matches: [
|
|
2169
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2170
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2171
|
+
]
|
|
2172
|
+
)
|
|
2173
|
+
transcoder.transcode request_pb
|
|
2174
|
+
end
|
|
2175
|
+
|
|
2176
|
+
##
|
|
2177
|
+
# @private
|
|
2178
|
+
#
|
|
2179
|
+
# GRPC transcoding helper method for the patch REST call
|
|
2180
|
+
#
|
|
2181
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPatchRequest]
|
|
2182
|
+
# A request object representing the call parameters. Required.
|
|
2183
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2184
|
+
# Uri, Body, Query string parameters
|
|
2185
|
+
def self.transcode_patch_request request_pb
|
|
2186
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2187
|
+
.with_bindings(
|
|
2188
|
+
uri_method: :patch,
|
|
2189
|
+
uri_template: "/v1/projects/{project}/instances/{instance}",
|
|
2190
|
+
body: "body",
|
|
2191
|
+
matches: [
|
|
2192
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2193
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2194
|
+
]
|
|
2195
|
+
)
|
|
2196
|
+
transcoder.transcode request_pb
|
|
2197
|
+
end
|
|
2198
|
+
|
|
2199
|
+
##
|
|
2200
|
+
# @private
|
|
2201
|
+
#
|
|
2202
|
+
# GRPC transcoding helper method for the promote_replica REST call
|
|
2203
|
+
#
|
|
2204
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPromoteReplicaRequest]
|
|
2205
|
+
# A request object representing the call parameters. Required.
|
|
2206
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2207
|
+
# Uri, Body, Query string parameters
|
|
2208
|
+
def self.transcode_promote_replica_request request_pb
|
|
2209
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2210
|
+
.with_bindings(
|
|
2211
|
+
uri_method: :post,
|
|
2212
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/promoteReplica",
|
|
2213
|
+
matches: [
|
|
2214
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2215
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2216
|
+
]
|
|
2217
|
+
)
|
|
2218
|
+
transcoder.transcode request_pb
|
|
2219
|
+
end
|
|
2220
|
+
|
|
2221
|
+
##
|
|
2222
|
+
# @private
|
|
2223
|
+
#
|
|
2224
|
+
# GRPC transcoding helper method for the switchover REST call
|
|
2225
|
+
#
|
|
2226
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesSwitchoverRequest]
|
|
2227
|
+
# A request object representing the call parameters. Required.
|
|
2228
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2229
|
+
# Uri, Body, Query string parameters
|
|
2230
|
+
def self.transcode_switchover_request request_pb
|
|
2231
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2232
|
+
.with_bindings(
|
|
2233
|
+
uri_method: :post,
|
|
2234
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/switchover",
|
|
2235
|
+
matches: [
|
|
2236
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2237
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2238
|
+
]
|
|
2239
|
+
)
|
|
2240
|
+
transcoder.transcode request_pb
|
|
2241
|
+
end
|
|
2242
|
+
|
|
2243
|
+
##
|
|
2244
|
+
# @private
|
|
2245
|
+
#
|
|
2246
|
+
# GRPC transcoding helper method for the reset_ssl_config REST call
|
|
2247
|
+
#
|
|
2248
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesResetSslConfigRequest]
|
|
2249
|
+
# A request object representing the call parameters. Required.
|
|
2250
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2251
|
+
# Uri, Body, Query string parameters
|
|
2252
|
+
def self.transcode_reset_ssl_config_request request_pb
|
|
2253
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2254
|
+
.with_bindings(
|
|
2255
|
+
uri_method: :post,
|
|
2256
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/resetSslConfig",
|
|
2257
|
+
matches: [
|
|
2258
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2259
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2260
|
+
]
|
|
2261
|
+
)
|
|
2262
|
+
transcoder.transcode request_pb
|
|
2263
|
+
end
|
|
2264
|
+
|
|
2265
|
+
##
|
|
2266
|
+
# @private
|
|
2267
|
+
#
|
|
2268
|
+
# GRPC transcoding helper method for the restart REST call
|
|
2269
|
+
#
|
|
2270
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRestartRequest]
|
|
2271
|
+
# A request object representing the call parameters. Required.
|
|
2272
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2273
|
+
# Uri, Body, Query string parameters
|
|
2274
|
+
def self.transcode_restart_request request_pb
|
|
2275
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2276
|
+
.with_bindings(
|
|
2277
|
+
uri_method: :post,
|
|
2278
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/restart",
|
|
2279
|
+
matches: [
|
|
2280
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2281
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2282
|
+
]
|
|
2283
|
+
)
|
|
2284
|
+
transcoder.transcode request_pb
|
|
2285
|
+
end
|
|
2286
|
+
|
|
2287
|
+
##
|
|
2288
|
+
# @private
|
|
2289
|
+
#
|
|
2290
|
+
# GRPC transcoding helper method for the restore_backup REST call
|
|
2291
|
+
#
|
|
2292
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRestoreBackupRequest]
|
|
2293
|
+
# A request object representing the call parameters. Required.
|
|
2294
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2295
|
+
# Uri, Body, Query string parameters
|
|
2296
|
+
def self.transcode_restore_backup_request request_pb
|
|
2297
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2298
|
+
.with_bindings(
|
|
2299
|
+
uri_method: :post,
|
|
2300
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/restoreBackup",
|
|
2301
|
+
body: "body",
|
|
2302
|
+
matches: [
|
|
2303
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2304
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2305
|
+
]
|
|
2306
|
+
)
|
|
2307
|
+
transcoder.transcode request_pb
|
|
2308
|
+
end
|
|
2309
|
+
|
|
2310
|
+
##
|
|
2311
|
+
# @private
|
|
2312
|
+
#
|
|
2313
|
+
# GRPC transcoding helper method for the rotate_server_ca REST call
|
|
2314
|
+
#
|
|
2315
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateServerCaRequest]
|
|
2316
|
+
# A request object representing the call parameters. Required.
|
|
2317
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2318
|
+
# Uri, Body, Query string parameters
|
|
2319
|
+
def self.transcode_rotate_server_ca_request request_pb
|
|
2320
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2321
|
+
.with_bindings(
|
|
2322
|
+
uri_method: :post,
|
|
2323
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/rotateServerCa",
|
|
2324
|
+
body: "body",
|
|
2325
|
+
matches: [
|
|
2326
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2327
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2328
|
+
]
|
|
2329
|
+
)
|
|
2330
|
+
transcoder.transcode request_pb
|
|
2331
|
+
end
|
|
2332
|
+
|
|
2333
|
+
##
|
|
2334
|
+
# @private
|
|
2335
|
+
#
|
|
2336
|
+
# GRPC transcoding helper method for the rotate_server_certificate REST call
|
|
2337
|
+
#
|
|
2338
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateServerCertificateRequest]
|
|
2339
|
+
# A request object representing the call parameters. Required.
|
|
2340
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2341
|
+
# Uri, Body, Query string parameters
|
|
2342
|
+
def self.transcode_rotate_server_certificate_request request_pb
|
|
2343
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2344
|
+
.with_bindings(
|
|
2345
|
+
uri_method: :post,
|
|
2346
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/rotateServerCertificate",
|
|
2347
|
+
body: "body",
|
|
2348
|
+
matches: [
|
|
2349
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2350
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2351
|
+
]
|
|
2352
|
+
)
|
|
2353
|
+
transcoder.transcode request_pb
|
|
2354
|
+
end
|
|
2355
|
+
|
|
2356
|
+
##
|
|
2357
|
+
# @private
|
|
2358
|
+
#
|
|
2359
|
+
# GRPC transcoding helper method for the rotate_entra_id_certificate REST call
|
|
2360
|
+
#
|
|
2361
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRotateEntraIdCertificateRequest]
|
|
2362
|
+
# A request object representing the call parameters. Required.
|
|
2363
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2364
|
+
# Uri, Body, Query string parameters
|
|
2365
|
+
def self.transcode_rotate_entra_id_certificate_request request_pb
|
|
2366
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2367
|
+
.with_bindings(
|
|
2368
|
+
uri_method: :post,
|
|
2369
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/rotateEntraIdCertificate",
|
|
2370
|
+
body: "body",
|
|
2371
|
+
matches: [
|
|
2372
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2373
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2374
|
+
]
|
|
2375
|
+
)
|
|
2376
|
+
transcoder.transcode request_pb
|
|
2377
|
+
end
|
|
2378
|
+
|
|
2379
|
+
##
|
|
2380
|
+
# @private
|
|
2381
|
+
#
|
|
2382
|
+
# GRPC transcoding helper method for the start_replica REST call
|
|
2383
|
+
#
|
|
2384
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStartReplicaRequest]
|
|
2385
|
+
# A request object representing the call parameters. Required.
|
|
2386
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2387
|
+
# Uri, Body, Query string parameters
|
|
2388
|
+
def self.transcode_start_replica_request request_pb
|
|
2389
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2390
|
+
.with_bindings(
|
|
2391
|
+
uri_method: :post,
|
|
2392
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/startReplica",
|
|
2393
|
+
matches: [
|
|
2394
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2395
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2396
|
+
]
|
|
2397
|
+
)
|
|
2398
|
+
transcoder.transcode request_pb
|
|
2399
|
+
end
|
|
2400
|
+
|
|
2401
|
+
##
|
|
2402
|
+
# @private
|
|
2403
|
+
#
|
|
2404
|
+
# GRPC transcoding helper method for the stop_replica REST call
|
|
2405
|
+
#
|
|
2406
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStopReplicaRequest]
|
|
2407
|
+
# A request object representing the call parameters. Required.
|
|
2408
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2409
|
+
# Uri, Body, Query string parameters
|
|
2410
|
+
def self.transcode_stop_replica_request request_pb
|
|
2411
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2412
|
+
.with_bindings(
|
|
2413
|
+
uri_method: :post,
|
|
2414
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/stopReplica",
|
|
2415
|
+
matches: [
|
|
2416
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2417
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2418
|
+
]
|
|
2419
|
+
)
|
|
2420
|
+
transcoder.transcode request_pb
|
|
2421
|
+
end
|
|
2422
|
+
|
|
2423
|
+
##
|
|
2424
|
+
# @private
|
|
2425
|
+
#
|
|
2426
|
+
# GRPC transcoding helper method for the truncate_log REST call
|
|
2427
|
+
#
|
|
2428
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesTruncateLogRequest]
|
|
2429
|
+
# A request object representing the call parameters. Required.
|
|
2430
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2431
|
+
# Uri, Body, Query string parameters
|
|
2432
|
+
def self.transcode_truncate_log_request request_pb
|
|
2433
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2434
|
+
.with_bindings(
|
|
2435
|
+
uri_method: :post,
|
|
2436
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/truncateLog",
|
|
2437
|
+
body: "body",
|
|
2438
|
+
matches: [
|
|
2439
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2440
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2441
|
+
]
|
|
2442
|
+
)
|
|
2443
|
+
transcoder.transcode request_pb
|
|
2444
|
+
end
|
|
2445
|
+
|
|
2446
|
+
##
|
|
2447
|
+
# @private
|
|
2448
|
+
#
|
|
2449
|
+
# GRPC transcoding helper method for the update REST call
|
|
2450
|
+
#
|
|
2451
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesUpdateRequest]
|
|
2452
|
+
# A request object representing the call parameters. Required.
|
|
2453
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2454
|
+
# Uri, Body, Query string parameters
|
|
2455
|
+
def self.transcode_update_request request_pb
|
|
2456
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2457
|
+
.with_bindings(
|
|
2458
|
+
uri_method: :put,
|
|
2459
|
+
uri_template: "/v1/projects/{project}/instances/{instance}",
|
|
2460
|
+
body: "body",
|
|
2461
|
+
matches: [
|
|
2462
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2463
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2464
|
+
]
|
|
2465
|
+
)
|
|
2466
|
+
transcoder.transcode request_pb
|
|
2467
|
+
end
|
|
2468
|
+
|
|
2469
|
+
##
|
|
2470
|
+
# @private
|
|
2471
|
+
#
|
|
2472
|
+
# GRPC transcoding helper method for the create_ephemeral REST call
|
|
2473
|
+
#
|
|
2474
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesCreateEphemeralCertRequest]
|
|
2475
|
+
# A request object representing the call parameters. Required.
|
|
2476
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2477
|
+
# Uri, Body, Query string parameters
|
|
2478
|
+
def self.transcode_create_ephemeral_request request_pb
|
|
2479
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2480
|
+
.with_bindings(
|
|
2481
|
+
uri_method: :post,
|
|
2482
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/createEphemeral",
|
|
2483
|
+
body: "body",
|
|
2484
|
+
matches: [
|
|
2485
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2486
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2487
|
+
]
|
|
2488
|
+
)
|
|
2489
|
+
transcoder.transcode request_pb
|
|
2490
|
+
end
|
|
2491
|
+
|
|
2492
|
+
##
|
|
2493
|
+
# @private
|
|
2494
|
+
#
|
|
2495
|
+
# GRPC transcoding helper method for the reschedule_maintenance REST call
|
|
2496
|
+
#
|
|
2497
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesRescheduleMaintenanceRequest]
|
|
2498
|
+
# A request object representing the call parameters. Required.
|
|
2499
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2500
|
+
# Uri, Body, Query string parameters
|
|
2501
|
+
def self.transcode_reschedule_maintenance_request request_pb
|
|
2502
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2503
|
+
.with_bindings(
|
|
2504
|
+
uri_method: :post,
|
|
2505
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/rescheduleMaintenance",
|
|
2506
|
+
body: "body",
|
|
2507
|
+
matches: [
|
|
2508
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2509
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2510
|
+
]
|
|
2511
|
+
)
|
|
2512
|
+
transcoder.transcode request_pb
|
|
2513
|
+
end
|
|
2514
|
+
|
|
2515
|
+
##
|
|
2516
|
+
# @private
|
|
2517
|
+
#
|
|
2518
|
+
# GRPC transcoding helper method for the verify_external_sync_settings REST call
|
|
2519
|
+
#
|
|
2520
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesVerifyExternalSyncSettingsRequest]
|
|
2521
|
+
# A request object representing the call parameters. Required.
|
|
2522
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2523
|
+
# Uri, Body, Query string parameters
|
|
2524
|
+
def self.transcode_verify_external_sync_settings_request request_pb
|
|
2525
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2526
|
+
.with_bindings(
|
|
2527
|
+
uri_method: :post,
|
|
2528
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/verifyExternalSyncSettings",
|
|
2529
|
+
body: "*",
|
|
2530
|
+
matches: [
|
|
2531
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2532
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2533
|
+
]
|
|
2534
|
+
)
|
|
2535
|
+
transcoder.transcode request_pb
|
|
2536
|
+
end
|
|
2537
|
+
|
|
2538
|
+
##
|
|
2539
|
+
# @private
|
|
2540
|
+
#
|
|
2541
|
+
# GRPC transcoding helper method for the start_external_sync REST call
|
|
2542
|
+
#
|
|
2543
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesStartExternalSyncRequest]
|
|
2544
|
+
# A request object representing the call parameters. Required.
|
|
2545
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2546
|
+
# Uri, Body, Query string parameters
|
|
2547
|
+
def self.transcode_start_external_sync_request request_pb
|
|
2548
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2549
|
+
.with_bindings(
|
|
2550
|
+
uri_method: :post,
|
|
2551
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/startExternalSync",
|
|
2552
|
+
body: "*",
|
|
2553
|
+
matches: [
|
|
2554
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2555
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2556
|
+
]
|
|
2557
|
+
)
|
|
2558
|
+
transcoder.transcode request_pb
|
|
2559
|
+
end
|
|
2560
|
+
|
|
2561
|
+
##
|
|
2562
|
+
# @private
|
|
2563
|
+
#
|
|
2564
|
+
# GRPC transcoding helper method for the perform_disk_shrink REST call
|
|
2565
|
+
#
|
|
2566
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPerformDiskShrinkRequest]
|
|
2567
|
+
# A request object representing the call parameters. Required.
|
|
2568
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2569
|
+
# Uri, Body, Query string parameters
|
|
2570
|
+
def self.transcode_perform_disk_shrink_request request_pb
|
|
2571
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2572
|
+
.with_bindings(
|
|
2573
|
+
uri_method: :post,
|
|
2574
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/performDiskShrink",
|
|
2575
|
+
body: "body",
|
|
2576
|
+
matches: [
|
|
2577
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2578
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2579
|
+
]
|
|
2580
|
+
)
|
|
2581
|
+
transcoder.transcode request_pb
|
|
2582
|
+
end
|
|
2583
|
+
|
|
2584
|
+
##
|
|
2585
|
+
# @private
|
|
2586
|
+
#
|
|
2587
|
+
# GRPC transcoding helper method for the get_disk_shrink_config REST call
|
|
2588
|
+
#
|
|
2589
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetDiskShrinkConfigRequest]
|
|
2590
|
+
# A request object representing the call parameters. Required.
|
|
2591
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2592
|
+
# Uri, Body, Query string parameters
|
|
2593
|
+
def self.transcode_get_disk_shrink_config_request request_pb
|
|
2594
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2595
|
+
.with_bindings(
|
|
2596
|
+
uri_method: :get,
|
|
2597
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/getDiskShrinkConfig",
|
|
2598
|
+
matches: [
|
|
2599
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2600
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2601
|
+
]
|
|
2602
|
+
)
|
|
2603
|
+
transcoder.transcode request_pb
|
|
2604
|
+
end
|
|
2605
|
+
|
|
2606
|
+
##
|
|
2607
|
+
# @private
|
|
2608
|
+
#
|
|
2609
|
+
# GRPC transcoding helper method for the reset_replica_size REST call
|
|
2610
|
+
#
|
|
2611
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesResetReplicaSizeRequest]
|
|
2612
|
+
# A request object representing the call parameters. Required.
|
|
2613
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2614
|
+
# Uri, Body, Query string parameters
|
|
2615
|
+
def self.transcode_reset_replica_size_request request_pb
|
|
2616
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2617
|
+
.with_bindings(
|
|
2618
|
+
uri_method: :post,
|
|
2619
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/resetReplicaSize",
|
|
2620
|
+
body: "*",
|
|
2621
|
+
matches: [
|
|
2622
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2623
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2624
|
+
]
|
|
2625
|
+
)
|
|
2626
|
+
transcoder.transcode request_pb
|
|
2627
|
+
end
|
|
2628
|
+
|
|
2629
|
+
##
|
|
2630
|
+
# @private
|
|
2631
|
+
#
|
|
2632
|
+
# GRPC transcoding helper method for the get_latest_recovery_time REST call
|
|
2633
|
+
#
|
|
2634
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesGetLatestRecoveryTimeRequest]
|
|
2635
|
+
# A request object representing the call parameters. Required.
|
|
2636
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2637
|
+
# Uri, Body, Query string parameters
|
|
2638
|
+
def self.transcode_get_latest_recovery_time_request request_pb
|
|
2639
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2640
|
+
.with_bindings(
|
|
2641
|
+
uri_method: :get,
|
|
2642
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/getLatestRecoveryTime",
|
|
2643
|
+
matches: [
|
|
2644
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2645
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2646
|
+
]
|
|
2647
|
+
)
|
|
2648
|
+
transcoder.transcode request_pb
|
|
2649
|
+
end
|
|
2650
|
+
|
|
2651
|
+
##
|
|
2652
|
+
# @private
|
|
2653
|
+
#
|
|
2654
|
+
# GRPC transcoding helper method for the execute_sql REST call
|
|
2655
|
+
#
|
|
2656
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesExecuteSqlRequest]
|
|
2657
|
+
# A request object representing the call parameters. Required.
|
|
2658
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2659
|
+
# Uri, Body, Query string parameters
|
|
2660
|
+
def self.transcode_execute_sql_request request_pb
|
|
2661
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2662
|
+
.with_bindings(
|
|
2663
|
+
uri_method: :post,
|
|
2664
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/executeSql",
|
|
2665
|
+
body: "body",
|
|
2666
|
+
matches: [
|
|
2667
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2668
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2669
|
+
]
|
|
2670
|
+
)
|
|
2671
|
+
transcoder.transcode request_pb
|
|
2672
|
+
end
|
|
2673
|
+
|
|
2674
|
+
##
|
|
2675
|
+
# @private
|
|
2676
|
+
#
|
|
2677
|
+
# GRPC transcoding helper method for the acquire_ssrs_lease REST call
|
|
2678
|
+
#
|
|
2679
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesAcquireSsrsLeaseRequest]
|
|
2680
|
+
# A request object representing the call parameters. Required.
|
|
2681
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2682
|
+
# Uri, Body, Query string parameters
|
|
2683
|
+
def self.transcode_acquire_ssrs_lease_request request_pb
|
|
2684
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2685
|
+
.with_bindings(
|
|
2686
|
+
uri_method: :post,
|
|
2687
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/acquireSsrsLease",
|
|
2688
|
+
body: "body",
|
|
2689
|
+
matches: [
|
|
2690
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2691
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2692
|
+
]
|
|
2693
|
+
)
|
|
2694
|
+
transcoder.transcode request_pb
|
|
2695
|
+
end
|
|
2696
|
+
|
|
2697
|
+
##
|
|
2698
|
+
# @private
|
|
2699
|
+
#
|
|
2700
|
+
# GRPC transcoding helper method for the release_ssrs_lease REST call
|
|
2701
|
+
#
|
|
2702
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesReleaseSsrsLeaseRequest]
|
|
2703
|
+
# A request object representing the call parameters. Required.
|
|
2704
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2705
|
+
# Uri, Body, Query string parameters
|
|
2706
|
+
def self.transcode_release_ssrs_lease_request request_pb
|
|
2707
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2708
|
+
.with_bindings(
|
|
2709
|
+
uri_method: :post,
|
|
2710
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/releaseSsrsLease",
|
|
2711
|
+
matches: [
|
|
2712
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2713
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2714
|
+
]
|
|
2715
|
+
)
|
|
2716
|
+
transcoder.transcode request_pb
|
|
2717
|
+
end
|
|
2718
|
+
|
|
2719
|
+
##
|
|
2720
|
+
# @private
|
|
2721
|
+
#
|
|
2722
|
+
# GRPC transcoding helper method for the pre_check_major_version_upgrade REST call
|
|
2723
|
+
#
|
|
2724
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPreCheckMajorVersionUpgradeRequest]
|
|
2725
|
+
# A request object representing the call parameters. Required.
|
|
2726
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2727
|
+
# Uri, Body, Query string parameters
|
|
2728
|
+
def self.transcode_pre_check_major_version_upgrade_request request_pb
|
|
2729
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2730
|
+
.with_bindings(
|
|
2731
|
+
uri_method: :post,
|
|
2732
|
+
uri_template: "/v1/projects/{project}/instances/{instance}/preCheckMajorVersionUpgrade",
|
|
2733
|
+
body: "body",
|
|
2734
|
+
matches: [
|
|
2735
|
+
["project", %r{^[^/]+/?$}, false],
|
|
2736
|
+
["instance", %r{^[^/]+/?$}, false]
|
|
2737
|
+
]
|
|
2738
|
+
)
|
|
2739
|
+
transcoder.transcode request_pb
|
|
2740
|
+
end
|
|
2741
|
+
|
|
2742
|
+
##
|
|
2743
|
+
# @private
|
|
2744
|
+
#
|
|
2745
|
+
# GRPC transcoding helper method for the point_in_time_restore REST call
|
|
2746
|
+
#
|
|
2747
|
+
# @param request_pb [::Google::Cloud::Sql::V1::SqlInstancesPointInTimeRestoreRequest]
|
|
2748
|
+
# A request object representing the call parameters. Required.
|
|
2749
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
2750
|
+
# Uri, Body, Query string parameters
|
|
2751
|
+
def self.transcode_point_in_time_restore_request request_pb
|
|
2752
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
2753
|
+
.with_bindings(
|
|
2754
|
+
uri_method: :post,
|
|
2755
|
+
uri_template: "/v1/{parent}:pointInTimeRestore",
|
|
2756
|
+
body: "context",
|
|
2757
|
+
matches: [
|
|
2758
|
+
["parent", %r{^projects/[^/]+/?$}, false]
|
|
2759
|
+
]
|
|
2760
|
+
)
|
|
2761
|
+
transcoder.transcode request_pb
|
|
2762
|
+
end
|
|
2763
|
+
end
|
|
2764
|
+
end
|
|
2765
|
+
end
|
|
2766
|
+
end
|
|
2767
|
+
end
|
|
2768
|
+
end
|
|
2769
|
+
end
|