google-cloud-vm_migration-v1 0.4.0 → 0.6.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/README.md +2 -2
- data/lib/google/cloud/vm_migration/v1/bindings_override.rb +102 -0
- data/lib/google/cloud/vm_migration/v1/rest.rb +38 -0
- data/lib/google/cloud/vm_migration/v1/version.rb +1 -1
- data/lib/google/cloud/vm_migration/v1/vm_migration/client.rb +146 -164
- data/lib/google/cloud/vm_migration/v1/vm_migration/operations.rb +14 -16
- data/lib/google/cloud/vm_migration/v1/vm_migration/rest/client.rb +4031 -0
- data/lib/google/cloud/vm_migration/v1/vm_migration/rest/operations.rb +793 -0
- data/lib/google/cloud/vm_migration/v1/vm_migration/rest/service_stub.rb +2783 -0
- data/lib/google/cloud/vm_migration/v1/vm_migration/rest.rb +54 -0
- data/lib/google/cloud/vm_migration/v1/vm_migration.rb +6 -0
- data/lib/google/cloud/vm_migration/v1.rb +5 -0
- data/lib/google/cloud/vmmigration/v1/vmmigration_pb.rb +29 -814
- data/proto_docs/google/api/client.rb +67 -4
- data/proto_docs/google/protobuf/any.rb +7 -4
- data/proto_docs/google/protobuf/timestamp.rb +1 -3
- metadata +17 -11
@@ -0,0 +1,4031 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2023 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/errors"
|
20
|
+
require "google/cloud/vmmigration/v1/vmmigration_pb"
|
21
|
+
require "google/cloud/vm_migration/v1/vm_migration/rest/service_stub"
|
22
|
+
require "google/cloud/location/rest"
|
23
|
+
require "google/iam/v1/rest"
|
24
|
+
|
25
|
+
module Google
|
26
|
+
module Cloud
|
27
|
+
module VMMigration
|
28
|
+
module V1
|
29
|
+
module VMMigration
|
30
|
+
module Rest
|
31
|
+
##
|
32
|
+
# REST client for the VmMigration service.
|
33
|
+
#
|
34
|
+
# VM Migration Service
|
35
|
+
#
|
36
|
+
class Client
|
37
|
+
include Paths
|
38
|
+
|
39
|
+
# @private
|
40
|
+
attr_reader :vm_migration_stub
|
41
|
+
|
42
|
+
##
|
43
|
+
# Configure the VmMigration Client class.
|
44
|
+
#
|
45
|
+
# See {::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client::Configuration}
|
46
|
+
# for a description of the configuration fields.
|
47
|
+
#
|
48
|
+
# @example
|
49
|
+
#
|
50
|
+
# # Modify the configuration for all VmMigration clients
|
51
|
+
# ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client.configure do |config|
|
52
|
+
# config.timeout = 10.0
|
53
|
+
# end
|
54
|
+
#
|
55
|
+
# @yield [config] Configure the Client client.
|
56
|
+
# @yieldparam config [Client::Configuration]
|
57
|
+
#
|
58
|
+
# @return [Client::Configuration]
|
59
|
+
#
|
60
|
+
def self.configure
|
61
|
+
@configure ||= begin
|
62
|
+
namespace = ["Google", "Cloud", "VMMigration", "V1"]
|
63
|
+
parent_config = while namespace.any?
|
64
|
+
parent_name = namespace.join "::"
|
65
|
+
parent_const = const_get parent_name
|
66
|
+
break parent_const.configure if parent_const.respond_to? :configure
|
67
|
+
namespace.pop
|
68
|
+
end
|
69
|
+
default_config = Client::Configuration.new parent_config
|
70
|
+
|
71
|
+
default_config.timeout = 60.0
|
72
|
+
|
73
|
+
default_config.rpcs.create_source.timeout = 900.0
|
74
|
+
|
75
|
+
default_config.rpcs.fetch_inventory.timeout = 300.0
|
76
|
+
|
77
|
+
default_config.rpcs.create_utilization_report.timeout = 300.0
|
78
|
+
|
79
|
+
default_config
|
80
|
+
end
|
81
|
+
yield @configure if block_given?
|
82
|
+
@configure
|
83
|
+
end
|
84
|
+
|
85
|
+
##
|
86
|
+
# Configure the VmMigration Client instance.
|
87
|
+
#
|
88
|
+
# The configuration is set to the derived mode, meaning that values can be changed,
|
89
|
+
# but structural changes (adding new fields, etc.) are not allowed. Structural changes
|
90
|
+
# should be made on {Client.configure}.
|
91
|
+
#
|
92
|
+
# See {::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client::Configuration}
|
93
|
+
# for a description of the configuration fields.
|
94
|
+
#
|
95
|
+
# @yield [config] Configure the Client client.
|
96
|
+
# @yieldparam config [Client::Configuration]
|
97
|
+
#
|
98
|
+
# @return [Client::Configuration]
|
99
|
+
#
|
100
|
+
def configure
|
101
|
+
yield @config if block_given?
|
102
|
+
@config
|
103
|
+
end
|
104
|
+
|
105
|
+
##
|
106
|
+
# Create a new VmMigration REST client object.
|
107
|
+
#
|
108
|
+
# @example
|
109
|
+
#
|
110
|
+
# # Create a client using the default configuration
|
111
|
+
# client = ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client.new
|
112
|
+
#
|
113
|
+
# # Create a client using a custom configuration
|
114
|
+
# client = ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client.new do |config|
|
115
|
+
# config.timeout = 10.0
|
116
|
+
# end
|
117
|
+
#
|
118
|
+
# @yield [config] Configure the VmMigration client.
|
119
|
+
# @yieldparam config [Client::Configuration]
|
120
|
+
#
|
121
|
+
def initialize
|
122
|
+
# Create the configuration object
|
123
|
+
@config = Configuration.new Client.configure
|
124
|
+
|
125
|
+
# Yield the configuration if needed
|
126
|
+
yield @config if block_given?
|
127
|
+
|
128
|
+
# Create credentials
|
129
|
+
credentials = @config.credentials
|
130
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
131
|
+
# but only if the default endpoint does not have a region prefix.
|
132
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
133
|
+
!@config.endpoint.split(".").first.include?("-")
|
134
|
+
credentials ||= Credentials.default scope: @config.scope,
|
135
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
136
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
137
|
+
credentials = Credentials.new credentials, scope: @config.scope
|
138
|
+
end
|
139
|
+
|
140
|
+
@quota_project_id = @config.quota_project
|
141
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
142
|
+
|
143
|
+
@operations_client = ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Operations.new do |config|
|
144
|
+
config.credentials = credentials
|
145
|
+
config.quota_project = @quota_project_id
|
146
|
+
config.endpoint = @config.endpoint
|
147
|
+
end
|
148
|
+
|
149
|
+
@location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
|
150
|
+
config.credentials = credentials
|
151
|
+
config.quota_project = @quota_project_id
|
152
|
+
config.endpoint = @config.endpoint
|
153
|
+
config.bindings_override = @config.bindings_override
|
154
|
+
end
|
155
|
+
|
156
|
+
@iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
|
157
|
+
config.credentials = credentials
|
158
|
+
config.quota_project = @quota_project_id
|
159
|
+
config.endpoint = @config.endpoint
|
160
|
+
end
|
161
|
+
|
162
|
+
@vm_migration_stub = ::Google::Cloud::VMMigration::V1::VMMigration::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
|
163
|
+
end
|
164
|
+
|
165
|
+
##
|
166
|
+
# Get the associated client for long-running operations.
|
167
|
+
#
|
168
|
+
# @return [::Google::Cloud::VMMigration::V1::VMMigration::Rest::Operations]
|
169
|
+
#
|
170
|
+
attr_reader :operations_client
|
171
|
+
|
172
|
+
##
|
173
|
+
# Get the associated client for mix-in of the Locations.
|
174
|
+
#
|
175
|
+
# @return [Google::Cloud::Location::Locations::Rest::Client]
|
176
|
+
#
|
177
|
+
attr_reader :location_client
|
178
|
+
|
179
|
+
##
|
180
|
+
# Get the associated client for mix-in of the IAMPolicy.
|
181
|
+
#
|
182
|
+
# @return [Google::Iam::V1::IAMPolicy::Rest::Client]
|
183
|
+
#
|
184
|
+
attr_reader :iam_policy_client
|
185
|
+
|
186
|
+
# Service calls
|
187
|
+
|
188
|
+
##
|
189
|
+
# Lists Sources in a given project and location.
|
190
|
+
#
|
191
|
+
# @overload list_sources(request, options = nil)
|
192
|
+
# Pass arguments to `list_sources` via a request object, either of type
|
193
|
+
# {::Google::Cloud::VMMigration::V1::ListSourcesRequest} or an equivalent Hash.
|
194
|
+
#
|
195
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListSourcesRequest, ::Hash]
|
196
|
+
# A request object representing the call parameters. Required. To specify no
|
197
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
198
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
199
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
200
|
+
#
|
201
|
+
# @overload list_sources(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
202
|
+
# Pass arguments to `list_sources` via keyword arguments. Note that at
|
203
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
204
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
205
|
+
#
|
206
|
+
# @param parent [::String]
|
207
|
+
# Required. The parent, which owns this collection of sources.
|
208
|
+
# @param page_size [::Integer]
|
209
|
+
# Optional. The maximum number of sources to return. The service may return
|
210
|
+
# fewer than this value. If unspecified, at most 500 sources will be
|
211
|
+
# returned. The maximum value is 1000; values above 1000 will be coerced to
|
212
|
+
# 1000.
|
213
|
+
# @param page_token [::String]
|
214
|
+
# Required. A page token, received from a previous `ListSources` call.
|
215
|
+
# Provide this to retrieve the subsequent page.
|
216
|
+
#
|
217
|
+
# When paginating, all other parameters provided to `ListSources` must
|
218
|
+
# match the call that provided the page token.
|
219
|
+
# @param filter [::String]
|
220
|
+
# Optional. The filter request.
|
221
|
+
# @param order_by [::String]
|
222
|
+
# Optional. the order by fields for the result.
|
223
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
224
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListSourcesResponse]
|
225
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
226
|
+
#
|
227
|
+
# @return [::Google::Cloud::VMMigration::V1::ListSourcesResponse]
|
228
|
+
#
|
229
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
230
|
+
def list_sources request, options = nil
|
231
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
232
|
+
|
233
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListSourcesRequest
|
234
|
+
|
235
|
+
# Converts hash and nil to an options object
|
236
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
237
|
+
|
238
|
+
# Customize the options with defaults
|
239
|
+
call_metadata = @config.rpcs.list_sources.metadata.to_h
|
240
|
+
|
241
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
242
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
243
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
244
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
245
|
+
transports_version_send: [:rest]
|
246
|
+
|
247
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
248
|
+
|
249
|
+
options.apply_defaults timeout: @config.rpcs.list_sources.timeout,
|
250
|
+
metadata: call_metadata,
|
251
|
+
retry_policy: @config.rpcs.list_sources.retry_policy
|
252
|
+
|
253
|
+
options.apply_defaults timeout: @config.timeout,
|
254
|
+
metadata: @config.metadata,
|
255
|
+
retry_policy: @config.retry_policy
|
256
|
+
|
257
|
+
@vm_migration_stub.list_sources request, options do |result, operation|
|
258
|
+
yield result, operation if block_given?
|
259
|
+
return result
|
260
|
+
end
|
261
|
+
rescue ::Gapic::Rest::Error => e
|
262
|
+
raise ::Google::Cloud::Error.from_error(e)
|
263
|
+
end
|
264
|
+
|
265
|
+
##
|
266
|
+
# Gets details of a single Source.
|
267
|
+
#
|
268
|
+
# @overload get_source(request, options = nil)
|
269
|
+
# Pass arguments to `get_source` via a request object, either of type
|
270
|
+
# {::Google::Cloud::VMMigration::V1::GetSourceRequest} or an equivalent Hash.
|
271
|
+
#
|
272
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetSourceRequest, ::Hash]
|
273
|
+
# A request object representing the call parameters. Required. To specify no
|
274
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
275
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
276
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
277
|
+
#
|
278
|
+
# @overload get_source(name: nil)
|
279
|
+
# Pass arguments to `get_source` via keyword arguments. Note that at
|
280
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
281
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
282
|
+
#
|
283
|
+
# @param name [::String]
|
284
|
+
# Required. The Source name.
|
285
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
286
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::Source]
|
287
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
288
|
+
#
|
289
|
+
# @return [::Google::Cloud::VMMigration::V1::Source]
|
290
|
+
#
|
291
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
292
|
+
def get_source request, options = nil
|
293
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
294
|
+
|
295
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetSourceRequest
|
296
|
+
|
297
|
+
# Converts hash and nil to an options object
|
298
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
299
|
+
|
300
|
+
# Customize the options with defaults
|
301
|
+
call_metadata = @config.rpcs.get_source.metadata.to_h
|
302
|
+
|
303
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
304
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
305
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
306
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
307
|
+
transports_version_send: [:rest]
|
308
|
+
|
309
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
310
|
+
|
311
|
+
options.apply_defaults timeout: @config.rpcs.get_source.timeout,
|
312
|
+
metadata: call_metadata,
|
313
|
+
retry_policy: @config.rpcs.get_source.retry_policy
|
314
|
+
|
315
|
+
options.apply_defaults timeout: @config.timeout,
|
316
|
+
metadata: @config.metadata,
|
317
|
+
retry_policy: @config.retry_policy
|
318
|
+
|
319
|
+
@vm_migration_stub.get_source request, options do |result, operation|
|
320
|
+
yield result, operation if block_given?
|
321
|
+
return result
|
322
|
+
end
|
323
|
+
rescue ::Gapic::Rest::Error => e
|
324
|
+
raise ::Google::Cloud::Error.from_error(e)
|
325
|
+
end
|
326
|
+
|
327
|
+
##
|
328
|
+
# Creates a new Source in a given project and location.
|
329
|
+
#
|
330
|
+
# @overload create_source(request, options = nil)
|
331
|
+
# Pass arguments to `create_source` via a request object, either of type
|
332
|
+
# {::Google::Cloud::VMMigration::V1::CreateSourceRequest} or an equivalent Hash.
|
333
|
+
#
|
334
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateSourceRequest, ::Hash]
|
335
|
+
# A request object representing the call parameters. Required. To specify no
|
336
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
337
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
338
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
339
|
+
#
|
340
|
+
# @overload create_source(parent: nil, source_id: nil, source: nil, request_id: nil)
|
341
|
+
# Pass arguments to `create_source` via keyword arguments. Note that at
|
342
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
343
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
344
|
+
#
|
345
|
+
# @param parent [::String]
|
346
|
+
# Required. The Source's parent.
|
347
|
+
# @param source_id [::String]
|
348
|
+
# Required. The source identifier.
|
349
|
+
# @param source [::Google::Cloud::VMMigration::V1::Source, ::Hash]
|
350
|
+
# Required. The create request body.
|
351
|
+
# @param request_id [::String]
|
352
|
+
# A request ID to identify requests. Specify a unique request ID
|
353
|
+
# so that if you must retry your request, the server will know to ignore
|
354
|
+
# the request if it has already been completed. The server will guarantee
|
355
|
+
# that for at least 60 minutes since the first request.
|
356
|
+
#
|
357
|
+
# For example, consider a situation where you make an initial request and t
|
358
|
+
# he request times out. If you make the request again with the same request
|
359
|
+
# ID, the server can check if original operation with the same request ID
|
360
|
+
# was received, and if so, will ignore the second request. This prevents
|
361
|
+
# clients from accidentally creating duplicate commitments.
|
362
|
+
#
|
363
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
364
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
365
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
366
|
+
# @yieldparam result [::Gapic::Operation]
|
367
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
368
|
+
#
|
369
|
+
# @return [::Gapic::Operation]
|
370
|
+
#
|
371
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
372
|
+
def create_source request, options = nil
|
373
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
374
|
+
|
375
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateSourceRequest
|
376
|
+
|
377
|
+
# Converts hash and nil to an options object
|
378
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
379
|
+
|
380
|
+
# Customize the options with defaults
|
381
|
+
call_metadata = @config.rpcs.create_source.metadata.to_h
|
382
|
+
|
383
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
384
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
385
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
386
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
387
|
+
transports_version_send: [:rest]
|
388
|
+
|
389
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
390
|
+
|
391
|
+
options.apply_defaults timeout: @config.rpcs.create_source.timeout,
|
392
|
+
metadata: call_metadata,
|
393
|
+
retry_policy: @config.rpcs.create_source.retry_policy
|
394
|
+
|
395
|
+
options.apply_defaults timeout: @config.timeout,
|
396
|
+
metadata: @config.metadata,
|
397
|
+
retry_policy: @config.retry_policy
|
398
|
+
|
399
|
+
@vm_migration_stub.create_source request, options do |result, operation|
|
400
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
401
|
+
yield result, operation if block_given?
|
402
|
+
return result
|
403
|
+
end
|
404
|
+
rescue ::Gapic::Rest::Error => e
|
405
|
+
raise ::Google::Cloud::Error.from_error(e)
|
406
|
+
end
|
407
|
+
|
408
|
+
##
|
409
|
+
# Updates the parameters of a single Source.
|
410
|
+
#
|
411
|
+
# @overload update_source(request, options = nil)
|
412
|
+
# Pass arguments to `update_source` via a request object, either of type
|
413
|
+
# {::Google::Cloud::VMMigration::V1::UpdateSourceRequest} or an equivalent Hash.
|
414
|
+
#
|
415
|
+
# @param request [::Google::Cloud::VMMigration::V1::UpdateSourceRequest, ::Hash]
|
416
|
+
# A request object representing the call parameters. Required. To specify no
|
417
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
418
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
419
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
420
|
+
#
|
421
|
+
# @overload update_source(update_mask: nil, source: nil, request_id: nil)
|
422
|
+
# Pass arguments to `update_source` via keyword arguments. Note that at
|
423
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
424
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
425
|
+
#
|
426
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
427
|
+
# Field mask is used to specify the fields to be overwritten in the
|
428
|
+
# Source resource by the update.
|
429
|
+
# The fields specified in the update_mask are relative to the resource, not
|
430
|
+
# the full request. A field will be overwritten if it is in the mask. If the
|
431
|
+
# user does not provide a mask then all fields will be overwritten.
|
432
|
+
# @param source [::Google::Cloud::VMMigration::V1::Source, ::Hash]
|
433
|
+
# Required. The update request body.
|
434
|
+
# @param request_id [::String]
|
435
|
+
# A request ID to identify requests. Specify a unique request ID
|
436
|
+
# so that if you must retry your request, the server will know to ignore
|
437
|
+
# the request if it has already been completed. The server will guarantee
|
438
|
+
# that for at least 60 minutes since the first request.
|
439
|
+
#
|
440
|
+
# For example, consider a situation where you make an initial request and t
|
441
|
+
# he request times out. If you make the request again with the same request
|
442
|
+
# ID, the server can check if original operation with the same request ID
|
443
|
+
# was received, and if so, will ignore the second request. This prevents
|
444
|
+
# clients from accidentally creating duplicate commitments.
|
445
|
+
#
|
446
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
447
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
448
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
449
|
+
# @yieldparam result [::Gapic::Operation]
|
450
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
451
|
+
#
|
452
|
+
# @return [::Gapic::Operation]
|
453
|
+
#
|
454
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
455
|
+
def update_source request, options = nil
|
456
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
457
|
+
|
458
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::UpdateSourceRequest
|
459
|
+
|
460
|
+
# Converts hash and nil to an options object
|
461
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
462
|
+
|
463
|
+
# Customize the options with defaults
|
464
|
+
call_metadata = @config.rpcs.update_source.metadata.to_h
|
465
|
+
|
466
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
467
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
468
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
469
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
470
|
+
transports_version_send: [:rest]
|
471
|
+
|
472
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
473
|
+
|
474
|
+
options.apply_defaults timeout: @config.rpcs.update_source.timeout,
|
475
|
+
metadata: call_metadata,
|
476
|
+
retry_policy: @config.rpcs.update_source.retry_policy
|
477
|
+
|
478
|
+
options.apply_defaults timeout: @config.timeout,
|
479
|
+
metadata: @config.metadata,
|
480
|
+
retry_policy: @config.retry_policy
|
481
|
+
|
482
|
+
@vm_migration_stub.update_source request, options do |result, operation|
|
483
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
484
|
+
yield result, operation if block_given?
|
485
|
+
return result
|
486
|
+
end
|
487
|
+
rescue ::Gapic::Rest::Error => e
|
488
|
+
raise ::Google::Cloud::Error.from_error(e)
|
489
|
+
end
|
490
|
+
|
491
|
+
##
|
492
|
+
# Deletes a single Source.
|
493
|
+
#
|
494
|
+
# @overload delete_source(request, options = nil)
|
495
|
+
# Pass arguments to `delete_source` via a request object, either of type
|
496
|
+
# {::Google::Cloud::VMMigration::V1::DeleteSourceRequest} or an equivalent Hash.
|
497
|
+
#
|
498
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteSourceRequest, ::Hash]
|
499
|
+
# A request object representing the call parameters. Required. To specify no
|
500
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
501
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
502
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
503
|
+
#
|
504
|
+
# @overload delete_source(name: nil, request_id: nil)
|
505
|
+
# Pass arguments to `delete_source` via keyword arguments. Note that at
|
506
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
507
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
508
|
+
#
|
509
|
+
# @param name [::String]
|
510
|
+
# Required. The Source name.
|
511
|
+
# @param request_id [::String]
|
512
|
+
# Optional. A request ID to identify requests. Specify a unique request ID
|
513
|
+
# so that if you must retry your request, the server will know to ignore
|
514
|
+
# the request if it has already been completed. The server will guarantee
|
515
|
+
# that for at least 60 minutes after the first request.
|
516
|
+
#
|
517
|
+
# For example, consider a situation where you make an initial request and t
|
518
|
+
# he request times out. If you make the request again with the same request
|
519
|
+
# ID, the server can check if original operation with the same request ID
|
520
|
+
# was received, and if so, will ignore the second request. This prevents
|
521
|
+
# clients from accidentally creating duplicate commitments.
|
522
|
+
#
|
523
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
524
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
525
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
526
|
+
# @yieldparam result [::Gapic::Operation]
|
527
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
528
|
+
#
|
529
|
+
# @return [::Gapic::Operation]
|
530
|
+
#
|
531
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
532
|
+
def delete_source request, options = nil
|
533
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
534
|
+
|
535
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteSourceRequest
|
536
|
+
|
537
|
+
# Converts hash and nil to an options object
|
538
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
539
|
+
|
540
|
+
# Customize the options with defaults
|
541
|
+
call_metadata = @config.rpcs.delete_source.metadata.to_h
|
542
|
+
|
543
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
544
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
545
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
546
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
547
|
+
transports_version_send: [:rest]
|
548
|
+
|
549
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
550
|
+
|
551
|
+
options.apply_defaults timeout: @config.rpcs.delete_source.timeout,
|
552
|
+
metadata: call_metadata,
|
553
|
+
retry_policy: @config.rpcs.delete_source.retry_policy
|
554
|
+
|
555
|
+
options.apply_defaults timeout: @config.timeout,
|
556
|
+
metadata: @config.metadata,
|
557
|
+
retry_policy: @config.retry_policy
|
558
|
+
|
559
|
+
@vm_migration_stub.delete_source request, options do |result, operation|
|
560
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
561
|
+
yield result, operation if block_given?
|
562
|
+
return result
|
563
|
+
end
|
564
|
+
rescue ::Gapic::Rest::Error => e
|
565
|
+
raise ::Google::Cloud::Error.from_error(e)
|
566
|
+
end
|
567
|
+
|
568
|
+
##
|
569
|
+
# List remote source's inventory of VMs.
|
570
|
+
# The remote source is the onprem vCenter (remote in the sense it's not in
|
571
|
+
# Compute Engine). The inventory describes the list of existing VMs in that
|
572
|
+
# source. Note that this operation lists the VMs on the remote source, as
|
573
|
+
# opposed to listing the MigratingVms resources in the vmmigration service.
|
574
|
+
#
|
575
|
+
# @overload fetch_inventory(request, options = nil)
|
576
|
+
# Pass arguments to `fetch_inventory` via a request object, either of type
|
577
|
+
# {::Google::Cloud::VMMigration::V1::FetchInventoryRequest} or an equivalent Hash.
|
578
|
+
#
|
579
|
+
# @param request [::Google::Cloud::VMMigration::V1::FetchInventoryRequest, ::Hash]
|
580
|
+
# A request object representing the call parameters. Required. To specify no
|
581
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
582
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
583
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
584
|
+
#
|
585
|
+
# @overload fetch_inventory(source: nil, force_refresh: nil)
|
586
|
+
# Pass arguments to `fetch_inventory` via keyword arguments. Note that at
|
587
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
588
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
589
|
+
#
|
590
|
+
# @param source [::String]
|
591
|
+
# Required. The name of the Source.
|
592
|
+
# @param force_refresh [::Boolean]
|
593
|
+
# If this flag is set to true, the source will be queried instead of using
|
594
|
+
# cached results. Using this flag will make the call slower.
|
595
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
596
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::FetchInventoryResponse]
|
597
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
598
|
+
#
|
599
|
+
# @return [::Google::Cloud::VMMigration::V1::FetchInventoryResponse]
|
600
|
+
#
|
601
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
602
|
+
def fetch_inventory request, options = nil
|
603
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
604
|
+
|
605
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::FetchInventoryRequest
|
606
|
+
|
607
|
+
# Converts hash and nil to an options object
|
608
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
609
|
+
|
610
|
+
# Customize the options with defaults
|
611
|
+
call_metadata = @config.rpcs.fetch_inventory.metadata.to_h
|
612
|
+
|
613
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
614
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
615
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
616
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
617
|
+
transports_version_send: [:rest]
|
618
|
+
|
619
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
620
|
+
|
621
|
+
options.apply_defaults timeout: @config.rpcs.fetch_inventory.timeout,
|
622
|
+
metadata: call_metadata,
|
623
|
+
retry_policy: @config.rpcs.fetch_inventory.retry_policy
|
624
|
+
|
625
|
+
options.apply_defaults timeout: @config.timeout,
|
626
|
+
metadata: @config.metadata,
|
627
|
+
retry_policy: @config.retry_policy
|
628
|
+
|
629
|
+
@vm_migration_stub.fetch_inventory request, options do |result, operation|
|
630
|
+
yield result, operation if block_given?
|
631
|
+
return result
|
632
|
+
end
|
633
|
+
rescue ::Gapic::Rest::Error => e
|
634
|
+
raise ::Google::Cloud::Error.from_error(e)
|
635
|
+
end
|
636
|
+
|
637
|
+
##
|
638
|
+
# Lists Utilization Reports of the given Source.
|
639
|
+
#
|
640
|
+
# @overload list_utilization_reports(request, options = nil)
|
641
|
+
# Pass arguments to `list_utilization_reports` via a request object, either of type
|
642
|
+
# {::Google::Cloud::VMMigration::V1::ListUtilizationReportsRequest} or an equivalent Hash.
|
643
|
+
#
|
644
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListUtilizationReportsRequest, ::Hash]
|
645
|
+
# A request object representing the call parameters. Required. To specify no
|
646
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
647
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
648
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
649
|
+
#
|
650
|
+
# @overload list_utilization_reports(parent: nil, view: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
651
|
+
# Pass arguments to `list_utilization_reports` via keyword arguments. Note that at
|
652
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
653
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
654
|
+
#
|
655
|
+
# @param parent [::String]
|
656
|
+
# Required. The Utilization Reports parent.
|
657
|
+
# @param view [::Google::Cloud::VMMigration::V1::UtilizationReportView]
|
658
|
+
# Optional. The level of details of each report.
|
659
|
+
# Defaults to BASIC.
|
660
|
+
# @param page_size [::Integer]
|
661
|
+
# Optional. The maximum number of reports to return. The service may return
|
662
|
+
# fewer than this value. If unspecified, at most 500 reports will be
|
663
|
+
# returned. The maximum value is 1000; values above 1000 will be coerced to
|
664
|
+
# 1000.
|
665
|
+
# @param page_token [::String]
|
666
|
+
# Required. A page token, received from a previous `ListUtilizationReports`
|
667
|
+
# call. Provide this to retrieve the subsequent page.
|
668
|
+
#
|
669
|
+
# When paginating, all other parameters provided to `ListUtilizationReports`
|
670
|
+
# must match the call that provided the page token.
|
671
|
+
# @param filter [::String]
|
672
|
+
# Optional. The filter request.
|
673
|
+
# @param order_by [::String]
|
674
|
+
# Optional. the order by fields for the result.
|
675
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
676
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListUtilizationReportsResponse]
|
677
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
678
|
+
#
|
679
|
+
# @return [::Google::Cloud::VMMigration::V1::ListUtilizationReportsResponse]
|
680
|
+
#
|
681
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
682
|
+
def list_utilization_reports request, options = nil
|
683
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
684
|
+
|
685
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListUtilizationReportsRequest
|
686
|
+
|
687
|
+
# Converts hash and nil to an options object
|
688
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
689
|
+
|
690
|
+
# Customize the options with defaults
|
691
|
+
call_metadata = @config.rpcs.list_utilization_reports.metadata.to_h
|
692
|
+
|
693
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
694
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
695
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
696
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
697
|
+
transports_version_send: [:rest]
|
698
|
+
|
699
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
700
|
+
|
701
|
+
options.apply_defaults timeout: @config.rpcs.list_utilization_reports.timeout,
|
702
|
+
metadata: call_metadata,
|
703
|
+
retry_policy: @config.rpcs.list_utilization_reports.retry_policy
|
704
|
+
|
705
|
+
options.apply_defaults timeout: @config.timeout,
|
706
|
+
metadata: @config.metadata,
|
707
|
+
retry_policy: @config.retry_policy
|
708
|
+
|
709
|
+
@vm_migration_stub.list_utilization_reports request, options do |result, operation|
|
710
|
+
yield result, operation if block_given?
|
711
|
+
return result
|
712
|
+
end
|
713
|
+
rescue ::Gapic::Rest::Error => e
|
714
|
+
raise ::Google::Cloud::Error.from_error(e)
|
715
|
+
end
|
716
|
+
|
717
|
+
##
|
718
|
+
# Gets a single Utilization Report.
|
719
|
+
#
|
720
|
+
# @overload get_utilization_report(request, options = nil)
|
721
|
+
# Pass arguments to `get_utilization_report` via a request object, either of type
|
722
|
+
# {::Google::Cloud::VMMigration::V1::GetUtilizationReportRequest} or an equivalent Hash.
|
723
|
+
#
|
724
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetUtilizationReportRequest, ::Hash]
|
725
|
+
# A request object representing the call parameters. Required. To specify no
|
726
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
727
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
728
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
729
|
+
#
|
730
|
+
# @overload get_utilization_report(name: nil, view: nil)
|
731
|
+
# Pass arguments to `get_utilization_report` via keyword arguments. Note that at
|
732
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
733
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
734
|
+
#
|
735
|
+
# @param name [::String]
|
736
|
+
# Required. The Utilization Report name.
|
737
|
+
# @param view [::Google::Cloud::VMMigration::V1::UtilizationReportView]
|
738
|
+
# Optional. The level of details of the report.
|
739
|
+
# Defaults to FULL
|
740
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
741
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::UtilizationReport]
|
742
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
743
|
+
#
|
744
|
+
# @return [::Google::Cloud::VMMigration::V1::UtilizationReport]
|
745
|
+
#
|
746
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
747
|
+
def get_utilization_report request, options = nil
|
748
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
749
|
+
|
750
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetUtilizationReportRequest
|
751
|
+
|
752
|
+
# Converts hash and nil to an options object
|
753
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
754
|
+
|
755
|
+
# Customize the options with defaults
|
756
|
+
call_metadata = @config.rpcs.get_utilization_report.metadata.to_h
|
757
|
+
|
758
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
759
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
760
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
761
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
762
|
+
transports_version_send: [:rest]
|
763
|
+
|
764
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
765
|
+
|
766
|
+
options.apply_defaults timeout: @config.rpcs.get_utilization_report.timeout,
|
767
|
+
metadata: call_metadata,
|
768
|
+
retry_policy: @config.rpcs.get_utilization_report.retry_policy
|
769
|
+
|
770
|
+
options.apply_defaults timeout: @config.timeout,
|
771
|
+
metadata: @config.metadata,
|
772
|
+
retry_policy: @config.retry_policy
|
773
|
+
|
774
|
+
@vm_migration_stub.get_utilization_report request, options do |result, operation|
|
775
|
+
yield result, operation if block_given?
|
776
|
+
return result
|
777
|
+
end
|
778
|
+
rescue ::Gapic::Rest::Error => e
|
779
|
+
raise ::Google::Cloud::Error.from_error(e)
|
780
|
+
end
|
781
|
+
|
782
|
+
##
|
783
|
+
# Creates a new UtilizationReport.
|
784
|
+
#
|
785
|
+
# @overload create_utilization_report(request, options = nil)
|
786
|
+
# Pass arguments to `create_utilization_report` via a request object, either of type
|
787
|
+
# {::Google::Cloud::VMMigration::V1::CreateUtilizationReportRequest} or an equivalent Hash.
|
788
|
+
#
|
789
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateUtilizationReportRequest, ::Hash]
|
790
|
+
# A request object representing the call parameters. Required. To specify no
|
791
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
792
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
793
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
794
|
+
#
|
795
|
+
# @overload create_utilization_report(parent: nil, utilization_report: nil, utilization_report_id: nil, request_id: nil)
|
796
|
+
# Pass arguments to `create_utilization_report` via keyword arguments. Note that at
|
797
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
798
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
799
|
+
#
|
800
|
+
# @param parent [::String]
|
801
|
+
# Required. The Utilization Report's parent.
|
802
|
+
# @param utilization_report [::Google::Cloud::VMMigration::V1::UtilizationReport, ::Hash]
|
803
|
+
# Required. The report to create.
|
804
|
+
# @param utilization_report_id [::String]
|
805
|
+
# Required. The ID to use for the report, which will become the final
|
806
|
+
# component of the reports's resource name.
|
807
|
+
#
|
808
|
+
# This value maximum length is 63 characters, and valid characters
|
809
|
+
# are /[a-z][0-9]-/. It must start with an english letter and must not
|
810
|
+
# end with a hyphen.
|
811
|
+
# @param request_id [::String]
|
812
|
+
# A request ID to identify requests. Specify a unique request ID
|
813
|
+
# so that if you must retry your request, the server will know to ignore
|
814
|
+
# the request if it has already been completed. The server will guarantee
|
815
|
+
# that for at least 60 minutes since the first request.
|
816
|
+
#
|
817
|
+
# For example, consider a situation where you make an initial request and t
|
818
|
+
# he request times out. If you make the request again with the same request
|
819
|
+
# ID, the server can check if original operation with the same request ID
|
820
|
+
# was received, and if so, will ignore the second request. This prevents
|
821
|
+
# clients from accidentally creating duplicate commitments.
|
822
|
+
#
|
823
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
824
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
825
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
826
|
+
# @yieldparam result [::Gapic::Operation]
|
827
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
828
|
+
#
|
829
|
+
# @return [::Gapic::Operation]
|
830
|
+
#
|
831
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
832
|
+
def create_utilization_report request, options = nil
|
833
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
834
|
+
|
835
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateUtilizationReportRequest
|
836
|
+
|
837
|
+
# Converts hash and nil to an options object
|
838
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
839
|
+
|
840
|
+
# Customize the options with defaults
|
841
|
+
call_metadata = @config.rpcs.create_utilization_report.metadata.to_h
|
842
|
+
|
843
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
844
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
845
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
846
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
847
|
+
transports_version_send: [:rest]
|
848
|
+
|
849
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
850
|
+
|
851
|
+
options.apply_defaults timeout: @config.rpcs.create_utilization_report.timeout,
|
852
|
+
metadata: call_metadata,
|
853
|
+
retry_policy: @config.rpcs.create_utilization_report.retry_policy
|
854
|
+
|
855
|
+
options.apply_defaults timeout: @config.timeout,
|
856
|
+
metadata: @config.metadata,
|
857
|
+
retry_policy: @config.retry_policy
|
858
|
+
|
859
|
+
@vm_migration_stub.create_utilization_report request, options do |result, operation|
|
860
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
861
|
+
yield result, operation if block_given?
|
862
|
+
return result
|
863
|
+
end
|
864
|
+
rescue ::Gapic::Rest::Error => e
|
865
|
+
raise ::Google::Cloud::Error.from_error(e)
|
866
|
+
end
|
867
|
+
|
868
|
+
##
|
869
|
+
# Deletes a single Utilization Report.
|
870
|
+
#
|
871
|
+
# @overload delete_utilization_report(request, options = nil)
|
872
|
+
# Pass arguments to `delete_utilization_report` via a request object, either of type
|
873
|
+
# {::Google::Cloud::VMMigration::V1::DeleteUtilizationReportRequest} or an equivalent Hash.
|
874
|
+
#
|
875
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteUtilizationReportRequest, ::Hash]
|
876
|
+
# A request object representing the call parameters. Required. To specify no
|
877
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
878
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
879
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
880
|
+
#
|
881
|
+
# @overload delete_utilization_report(name: nil, request_id: nil)
|
882
|
+
# Pass arguments to `delete_utilization_report` via keyword arguments. Note that at
|
883
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
884
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
885
|
+
#
|
886
|
+
# @param name [::String]
|
887
|
+
# Required. The Utilization Report name.
|
888
|
+
# @param request_id [::String]
|
889
|
+
# Optional. A request ID to identify requests. Specify a unique request ID
|
890
|
+
# so that if you must retry your request, the server will know to ignore
|
891
|
+
# the request if it has already been completed. The server will guarantee
|
892
|
+
# that for at least 60 minutes after the first request.
|
893
|
+
#
|
894
|
+
# For example, consider a situation where you make an initial request and t
|
895
|
+
# he request times out. If you make the request again with the same request
|
896
|
+
# ID, the server can check if original operation with the same request ID
|
897
|
+
# was received, and if so, will ignore the second request. This prevents
|
898
|
+
# clients from accidentally creating duplicate commitments.
|
899
|
+
#
|
900
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
901
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
902
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
903
|
+
# @yieldparam result [::Gapic::Operation]
|
904
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
905
|
+
#
|
906
|
+
# @return [::Gapic::Operation]
|
907
|
+
#
|
908
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
909
|
+
def delete_utilization_report request, options = nil
|
910
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
911
|
+
|
912
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteUtilizationReportRequest
|
913
|
+
|
914
|
+
# Converts hash and nil to an options object
|
915
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
916
|
+
|
917
|
+
# Customize the options with defaults
|
918
|
+
call_metadata = @config.rpcs.delete_utilization_report.metadata.to_h
|
919
|
+
|
920
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
921
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
922
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
923
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
924
|
+
transports_version_send: [:rest]
|
925
|
+
|
926
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
927
|
+
|
928
|
+
options.apply_defaults timeout: @config.rpcs.delete_utilization_report.timeout,
|
929
|
+
metadata: call_metadata,
|
930
|
+
retry_policy: @config.rpcs.delete_utilization_report.retry_policy
|
931
|
+
|
932
|
+
options.apply_defaults timeout: @config.timeout,
|
933
|
+
metadata: @config.metadata,
|
934
|
+
retry_policy: @config.retry_policy
|
935
|
+
|
936
|
+
@vm_migration_stub.delete_utilization_report request, options do |result, operation|
|
937
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
938
|
+
yield result, operation if block_given?
|
939
|
+
return result
|
940
|
+
end
|
941
|
+
rescue ::Gapic::Rest::Error => e
|
942
|
+
raise ::Google::Cloud::Error.from_error(e)
|
943
|
+
end
|
944
|
+
|
945
|
+
##
|
946
|
+
# Lists DatacenterConnectors in a given Source.
|
947
|
+
#
|
948
|
+
# @overload list_datacenter_connectors(request, options = nil)
|
949
|
+
# Pass arguments to `list_datacenter_connectors` via a request object, either of type
|
950
|
+
# {::Google::Cloud::VMMigration::V1::ListDatacenterConnectorsRequest} or an equivalent Hash.
|
951
|
+
#
|
952
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListDatacenterConnectorsRequest, ::Hash]
|
953
|
+
# A request object representing the call parameters. Required. To specify no
|
954
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
955
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
956
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
957
|
+
#
|
958
|
+
# @overload list_datacenter_connectors(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
959
|
+
# Pass arguments to `list_datacenter_connectors` via keyword arguments. Note that at
|
960
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
961
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
962
|
+
#
|
963
|
+
# @param parent [::String]
|
964
|
+
# Required. The parent, which owns this collection of connectors.
|
965
|
+
# @param page_size [::Integer]
|
966
|
+
# Optional. The maximum number of connectors to return. The service may
|
967
|
+
# return fewer than this value. If unspecified, at most 500 sources will be
|
968
|
+
# returned. The maximum value is 1000; values above 1000 will be coerced to
|
969
|
+
# 1000.
|
970
|
+
# @param page_token [::String]
|
971
|
+
# Required. A page token, received from a previous `ListDatacenterConnectors`
|
972
|
+
# call. Provide this to retrieve the subsequent page.
|
973
|
+
#
|
974
|
+
# When paginating, all other parameters provided to
|
975
|
+
# `ListDatacenterConnectors` must match the call that provided the page
|
976
|
+
# token.
|
977
|
+
# @param filter [::String]
|
978
|
+
# Optional. The filter request.
|
979
|
+
# @param order_by [::String]
|
980
|
+
# Optional. the order by fields for the result.
|
981
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
982
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListDatacenterConnectorsResponse]
|
983
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
984
|
+
#
|
985
|
+
# @return [::Google::Cloud::VMMigration::V1::ListDatacenterConnectorsResponse]
|
986
|
+
#
|
987
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
988
|
+
def list_datacenter_connectors request, options = nil
|
989
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
990
|
+
|
991
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListDatacenterConnectorsRequest
|
992
|
+
|
993
|
+
# Converts hash and nil to an options object
|
994
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
995
|
+
|
996
|
+
# Customize the options with defaults
|
997
|
+
call_metadata = @config.rpcs.list_datacenter_connectors.metadata.to_h
|
998
|
+
|
999
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1000
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1001
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1002
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1003
|
+
transports_version_send: [:rest]
|
1004
|
+
|
1005
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1006
|
+
|
1007
|
+
options.apply_defaults timeout: @config.rpcs.list_datacenter_connectors.timeout,
|
1008
|
+
metadata: call_metadata,
|
1009
|
+
retry_policy: @config.rpcs.list_datacenter_connectors.retry_policy
|
1010
|
+
|
1011
|
+
options.apply_defaults timeout: @config.timeout,
|
1012
|
+
metadata: @config.metadata,
|
1013
|
+
retry_policy: @config.retry_policy
|
1014
|
+
|
1015
|
+
@vm_migration_stub.list_datacenter_connectors request, options do |result, operation|
|
1016
|
+
yield result, operation if block_given?
|
1017
|
+
return result
|
1018
|
+
end
|
1019
|
+
rescue ::Gapic::Rest::Error => e
|
1020
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1021
|
+
end
|
1022
|
+
|
1023
|
+
##
|
1024
|
+
# Gets details of a single DatacenterConnector.
|
1025
|
+
#
|
1026
|
+
# @overload get_datacenter_connector(request, options = nil)
|
1027
|
+
# Pass arguments to `get_datacenter_connector` via a request object, either of type
|
1028
|
+
# {::Google::Cloud::VMMigration::V1::GetDatacenterConnectorRequest} or an equivalent Hash.
|
1029
|
+
#
|
1030
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetDatacenterConnectorRequest, ::Hash]
|
1031
|
+
# A request object representing the call parameters. Required. To specify no
|
1032
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1033
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1034
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1035
|
+
#
|
1036
|
+
# @overload get_datacenter_connector(name: nil)
|
1037
|
+
# Pass arguments to `get_datacenter_connector` via keyword arguments. Note that at
|
1038
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1039
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1040
|
+
#
|
1041
|
+
# @param name [::String]
|
1042
|
+
# Required. The name of the DatacenterConnector.
|
1043
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1044
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::DatacenterConnector]
|
1045
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1046
|
+
#
|
1047
|
+
# @return [::Google::Cloud::VMMigration::V1::DatacenterConnector]
|
1048
|
+
#
|
1049
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1050
|
+
def get_datacenter_connector request, options = nil
|
1051
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1052
|
+
|
1053
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetDatacenterConnectorRequest
|
1054
|
+
|
1055
|
+
# Converts hash and nil to an options object
|
1056
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1057
|
+
|
1058
|
+
# Customize the options with defaults
|
1059
|
+
call_metadata = @config.rpcs.get_datacenter_connector.metadata.to_h
|
1060
|
+
|
1061
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1062
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1063
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1064
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1065
|
+
transports_version_send: [:rest]
|
1066
|
+
|
1067
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1068
|
+
|
1069
|
+
options.apply_defaults timeout: @config.rpcs.get_datacenter_connector.timeout,
|
1070
|
+
metadata: call_metadata,
|
1071
|
+
retry_policy: @config.rpcs.get_datacenter_connector.retry_policy
|
1072
|
+
|
1073
|
+
options.apply_defaults timeout: @config.timeout,
|
1074
|
+
metadata: @config.metadata,
|
1075
|
+
retry_policy: @config.retry_policy
|
1076
|
+
|
1077
|
+
@vm_migration_stub.get_datacenter_connector request, options do |result, operation|
|
1078
|
+
yield result, operation if block_given?
|
1079
|
+
return result
|
1080
|
+
end
|
1081
|
+
rescue ::Gapic::Rest::Error => e
|
1082
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1083
|
+
end
|
1084
|
+
|
1085
|
+
##
|
1086
|
+
# Creates a new DatacenterConnector in a given Source.
|
1087
|
+
#
|
1088
|
+
# @overload create_datacenter_connector(request, options = nil)
|
1089
|
+
# Pass arguments to `create_datacenter_connector` via a request object, either of type
|
1090
|
+
# {::Google::Cloud::VMMigration::V1::CreateDatacenterConnectorRequest} or an equivalent Hash.
|
1091
|
+
#
|
1092
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateDatacenterConnectorRequest, ::Hash]
|
1093
|
+
# A request object representing the call parameters. Required. To specify no
|
1094
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1095
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1096
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1097
|
+
#
|
1098
|
+
# @overload create_datacenter_connector(parent: nil, datacenter_connector_id: nil, datacenter_connector: nil, request_id: nil)
|
1099
|
+
# Pass arguments to `create_datacenter_connector` via keyword arguments. Note that at
|
1100
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1101
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1102
|
+
#
|
1103
|
+
# @param parent [::String]
|
1104
|
+
# Required. The DatacenterConnector's parent.
|
1105
|
+
# Required. The Source in where the new DatacenterConnector will be created.
|
1106
|
+
# For example:
|
1107
|
+
# `projects/my-project/locations/us-central1/sources/my-source`
|
1108
|
+
# @param datacenter_connector_id [::String]
|
1109
|
+
# Required. The datacenterConnector identifier.
|
1110
|
+
# @param datacenter_connector [::Google::Cloud::VMMigration::V1::DatacenterConnector, ::Hash]
|
1111
|
+
# Required. The create request body.
|
1112
|
+
# @param request_id [::String]
|
1113
|
+
# A request ID to identify requests. Specify a unique request ID
|
1114
|
+
# so that if you must retry your request, the server will know to ignore
|
1115
|
+
# the request if it has already been completed. The server will guarantee
|
1116
|
+
# that for at least 60 minutes since the first request.
|
1117
|
+
#
|
1118
|
+
# For example, consider a situation where you make an initial request and t
|
1119
|
+
# he request times out. If you make the request again with the same request
|
1120
|
+
# ID, the server can check if original operation with the same request ID
|
1121
|
+
# was received, and if so, will ignore the second request. This prevents
|
1122
|
+
# clients from accidentally creating duplicate commitments.
|
1123
|
+
#
|
1124
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1125
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1126
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1127
|
+
# @yieldparam result [::Gapic::Operation]
|
1128
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1129
|
+
#
|
1130
|
+
# @return [::Gapic::Operation]
|
1131
|
+
#
|
1132
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1133
|
+
def create_datacenter_connector request, options = nil
|
1134
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1135
|
+
|
1136
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateDatacenterConnectorRequest
|
1137
|
+
|
1138
|
+
# Converts hash and nil to an options object
|
1139
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1140
|
+
|
1141
|
+
# Customize the options with defaults
|
1142
|
+
call_metadata = @config.rpcs.create_datacenter_connector.metadata.to_h
|
1143
|
+
|
1144
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1145
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1146
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1147
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1148
|
+
transports_version_send: [:rest]
|
1149
|
+
|
1150
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1151
|
+
|
1152
|
+
options.apply_defaults timeout: @config.rpcs.create_datacenter_connector.timeout,
|
1153
|
+
metadata: call_metadata,
|
1154
|
+
retry_policy: @config.rpcs.create_datacenter_connector.retry_policy
|
1155
|
+
|
1156
|
+
options.apply_defaults timeout: @config.timeout,
|
1157
|
+
metadata: @config.metadata,
|
1158
|
+
retry_policy: @config.retry_policy
|
1159
|
+
|
1160
|
+
@vm_migration_stub.create_datacenter_connector request, options do |result, operation|
|
1161
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1162
|
+
yield result, operation if block_given?
|
1163
|
+
return result
|
1164
|
+
end
|
1165
|
+
rescue ::Gapic::Rest::Error => e
|
1166
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1167
|
+
end
|
1168
|
+
|
1169
|
+
##
|
1170
|
+
# Deletes a single DatacenterConnector.
|
1171
|
+
#
|
1172
|
+
# @overload delete_datacenter_connector(request, options = nil)
|
1173
|
+
# Pass arguments to `delete_datacenter_connector` via a request object, either of type
|
1174
|
+
# {::Google::Cloud::VMMigration::V1::DeleteDatacenterConnectorRequest} or an equivalent Hash.
|
1175
|
+
#
|
1176
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteDatacenterConnectorRequest, ::Hash]
|
1177
|
+
# A request object representing the call parameters. Required. To specify no
|
1178
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1179
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1180
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1181
|
+
#
|
1182
|
+
# @overload delete_datacenter_connector(name: nil, request_id: nil)
|
1183
|
+
# Pass arguments to `delete_datacenter_connector` via keyword arguments. Note that at
|
1184
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1185
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1186
|
+
#
|
1187
|
+
# @param name [::String]
|
1188
|
+
# Required. The DatacenterConnector name.
|
1189
|
+
# @param request_id [::String]
|
1190
|
+
# A request ID to identify requests. Specify a unique request ID
|
1191
|
+
# so that if you must retry your request, the server will know to ignore
|
1192
|
+
# the request if it has already been completed. The server will guarantee
|
1193
|
+
# that for at least 60 minutes after the first request.
|
1194
|
+
#
|
1195
|
+
# For example, consider a situation where you make an initial request and t
|
1196
|
+
# he request times out. If you make the request again with the same request
|
1197
|
+
# ID, the server can check if original operation with the same request ID
|
1198
|
+
# was received, and if so, will ignore the second request. This prevents
|
1199
|
+
# clients from accidentally creating duplicate commitments.
|
1200
|
+
#
|
1201
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1202
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1203
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1204
|
+
# @yieldparam result [::Gapic::Operation]
|
1205
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1206
|
+
#
|
1207
|
+
# @return [::Gapic::Operation]
|
1208
|
+
#
|
1209
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1210
|
+
def delete_datacenter_connector request, options = nil
|
1211
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1212
|
+
|
1213
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteDatacenterConnectorRequest
|
1214
|
+
|
1215
|
+
# Converts hash and nil to an options object
|
1216
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1217
|
+
|
1218
|
+
# Customize the options with defaults
|
1219
|
+
call_metadata = @config.rpcs.delete_datacenter_connector.metadata.to_h
|
1220
|
+
|
1221
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1222
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1223
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1224
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1225
|
+
transports_version_send: [:rest]
|
1226
|
+
|
1227
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1228
|
+
|
1229
|
+
options.apply_defaults timeout: @config.rpcs.delete_datacenter_connector.timeout,
|
1230
|
+
metadata: call_metadata,
|
1231
|
+
retry_policy: @config.rpcs.delete_datacenter_connector.retry_policy
|
1232
|
+
|
1233
|
+
options.apply_defaults timeout: @config.timeout,
|
1234
|
+
metadata: @config.metadata,
|
1235
|
+
retry_policy: @config.retry_policy
|
1236
|
+
|
1237
|
+
@vm_migration_stub.delete_datacenter_connector request, options do |result, operation|
|
1238
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1239
|
+
yield result, operation if block_given?
|
1240
|
+
return result
|
1241
|
+
end
|
1242
|
+
rescue ::Gapic::Rest::Error => e
|
1243
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1244
|
+
end
|
1245
|
+
|
1246
|
+
##
|
1247
|
+
# Upgrades the appliance relate to this DatacenterConnector to the in-place
|
1248
|
+
# updateable version.
|
1249
|
+
#
|
1250
|
+
# @overload upgrade_appliance(request, options = nil)
|
1251
|
+
# Pass arguments to `upgrade_appliance` via a request object, either of type
|
1252
|
+
# {::Google::Cloud::VMMigration::V1::UpgradeApplianceRequest} or an equivalent Hash.
|
1253
|
+
#
|
1254
|
+
# @param request [::Google::Cloud::VMMigration::V1::UpgradeApplianceRequest, ::Hash]
|
1255
|
+
# A request object representing the call parameters. Required. To specify no
|
1256
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1257
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1258
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1259
|
+
#
|
1260
|
+
# @overload upgrade_appliance(datacenter_connector: nil, request_id: nil)
|
1261
|
+
# Pass arguments to `upgrade_appliance` via keyword arguments. Note that at
|
1262
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1263
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1264
|
+
#
|
1265
|
+
# @param datacenter_connector [::String]
|
1266
|
+
# Required. The DatacenterConnector name.
|
1267
|
+
# @param request_id [::String]
|
1268
|
+
# A request ID to identify requests. Specify a unique request ID
|
1269
|
+
# so that if you must retry your request, the server will know to ignore
|
1270
|
+
# the request if it has already been completed. The server will guarantee
|
1271
|
+
# that for at least 60 minutes after the first request.
|
1272
|
+
#
|
1273
|
+
# For example, consider a situation where you make an initial request and t
|
1274
|
+
# he request times out. If you make the request again with the same request
|
1275
|
+
# ID, the server can check if original operation with the same request ID
|
1276
|
+
# was received, and if so, will ignore the second request. This prevents
|
1277
|
+
# clients from accidentally creating duplicate commitments.
|
1278
|
+
#
|
1279
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1280
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1281
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1282
|
+
# @yieldparam result [::Gapic::Operation]
|
1283
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1284
|
+
#
|
1285
|
+
# @return [::Gapic::Operation]
|
1286
|
+
#
|
1287
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1288
|
+
def upgrade_appliance request, options = nil
|
1289
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1290
|
+
|
1291
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::UpgradeApplianceRequest
|
1292
|
+
|
1293
|
+
# Converts hash and nil to an options object
|
1294
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1295
|
+
|
1296
|
+
# Customize the options with defaults
|
1297
|
+
call_metadata = @config.rpcs.upgrade_appliance.metadata.to_h
|
1298
|
+
|
1299
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1300
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1301
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1302
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1303
|
+
transports_version_send: [:rest]
|
1304
|
+
|
1305
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1306
|
+
|
1307
|
+
options.apply_defaults timeout: @config.rpcs.upgrade_appliance.timeout,
|
1308
|
+
metadata: call_metadata,
|
1309
|
+
retry_policy: @config.rpcs.upgrade_appliance.retry_policy
|
1310
|
+
|
1311
|
+
options.apply_defaults timeout: @config.timeout,
|
1312
|
+
metadata: @config.metadata,
|
1313
|
+
retry_policy: @config.retry_policy
|
1314
|
+
|
1315
|
+
@vm_migration_stub.upgrade_appliance request, options do |result, operation|
|
1316
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1317
|
+
yield result, operation if block_given?
|
1318
|
+
return result
|
1319
|
+
end
|
1320
|
+
rescue ::Gapic::Rest::Error => e
|
1321
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1322
|
+
end
|
1323
|
+
|
1324
|
+
##
|
1325
|
+
# Creates a new MigratingVm in a given Source.
|
1326
|
+
#
|
1327
|
+
# @overload create_migrating_vm(request, options = nil)
|
1328
|
+
# Pass arguments to `create_migrating_vm` via a request object, either of type
|
1329
|
+
# {::Google::Cloud::VMMigration::V1::CreateMigratingVmRequest} or an equivalent Hash.
|
1330
|
+
#
|
1331
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateMigratingVmRequest, ::Hash]
|
1332
|
+
# A request object representing the call parameters. Required. To specify no
|
1333
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1334
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1335
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1336
|
+
#
|
1337
|
+
# @overload create_migrating_vm(parent: nil, migrating_vm_id: nil, migrating_vm: nil, request_id: nil)
|
1338
|
+
# Pass arguments to `create_migrating_vm` via keyword arguments. Note that at
|
1339
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1340
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1341
|
+
#
|
1342
|
+
# @param parent [::String]
|
1343
|
+
# Required. The MigratingVm's parent.
|
1344
|
+
# @param migrating_vm_id [::String]
|
1345
|
+
# Required. The migratingVm identifier.
|
1346
|
+
# @param migrating_vm [::Google::Cloud::VMMigration::V1::MigratingVm, ::Hash]
|
1347
|
+
# Required. The create request body.
|
1348
|
+
# @param request_id [::String]
|
1349
|
+
# A request ID to identify requests. Specify a unique request ID
|
1350
|
+
# so that if you must retry your request, the server will know to ignore
|
1351
|
+
# the request if it has already been completed. The server will guarantee
|
1352
|
+
# that for at least 60 minutes since the first request.
|
1353
|
+
#
|
1354
|
+
# For example, consider a situation where you make an initial request and t
|
1355
|
+
# he request times out. If you make the request again with the same request
|
1356
|
+
# ID, the server can check if original operation with the same request ID
|
1357
|
+
# was received, and if so, will ignore the second request. This prevents
|
1358
|
+
# clients from accidentally creating duplicate commitments.
|
1359
|
+
#
|
1360
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1361
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1362
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1363
|
+
# @yieldparam result [::Gapic::Operation]
|
1364
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1365
|
+
#
|
1366
|
+
# @return [::Gapic::Operation]
|
1367
|
+
#
|
1368
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1369
|
+
def create_migrating_vm request, options = nil
|
1370
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1371
|
+
|
1372
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateMigratingVmRequest
|
1373
|
+
|
1374
|
+
# Converts hash and nil to an options object
|
1375
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1376
|
+
|
1377
|
+
# Customize the options with defaults
|
1378
|
+
call_metadata = @config.rpcs.create_migrating_vm.metadata.to_h
|
1379
|
+
|
1380
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1381
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1382
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1383
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1384
|
+
transports_version_send: [:rest]
|
1385
|
+
|
1386
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1387
|
+
|
1388
|
+
options.apply_defaults timeout: @config.rpcs.create_migrating_vm.timeout,
|
1389
|
+
metadata: call_metadata,
|
1390
|
+
retry_policy: @config.rpcs.create_migrating_vm.retry_policy
|
1391
|
+
|
1392
|
+
options.apply_defaults timeout: @config.timeout,
|
1393
|
+
metadata: @config.metadata,
|
1394
|
+
retry_policy: @config.retry_policy
|
1395
|
+
|
1396
|
+
@vm_migration_stub.create_migrating_vm request, options do |result, operation|
|
1397
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1398
|
+
yield result, operation if block_given?
|
1399
|
+
return result
|
1400
|
+
end
|
1401
|
+
rescue ::Gapic::Rest::Error => e
|
1402
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1403
|
+
end
|
1404
|
+
|
1405
|
+
##
|
1406
|
+
# Lists MigratingVms in a given Source.
|
1407
|
+
#
|
1408
|
+
# @overload list_migrating_vms(request, options = nil)
|
1409
|
+
# Pass arguments to `list_migrating_vms` via a request object, either of type
|
1410
|
+
# {::Google::Cloud::VMMigration::V1::ListMigratingVmsRequest} or an equivalent Hash.
|
1411
|
+
#
|
1412
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListMigratingVmsRequest, ::Hash]
|
1413
|
+
# A request object representing the call parameters. Required. To specify no
|
1414
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1415
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1416
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1417
|
+
#
|
1418
|
+
# @overload list_migrating_vms(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil, view: nil)
|
1419
|
+
# Pass arguments to `list_migrating_vms` via keyword arguments. Note that at
|
1420
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1421
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1422
|
+
#
|
1423
|
+
# @param parent [::String]
|
1424
|
+
# Required. The parent, which owns this collection of MigratingVms.
|
1425
|
+
# @param page_size [::Integer]
|
1426
|
+
# Optional. The maximum number of migrating VMs to return. The service may
|
1427
|
+
# return fewer than this value. If unspecified, at most 500 migrating VMs
|
1428
|
+
# will be returned. The maximum value is 1000; values above 1000 will be
|
1429
|
+
# coerced to 1000.
|
1430
|
+
# @param page_token [::String]
|
1431
|
+
# Required. A page token, received from a previous `ListMigratingVms` call.
|
1432
|
+
# Provide this to retrieve the subsequent page.
|
1433
|
+
#
|
1434
|
+
# When paginating, all other parameters provided to `ListMigratingVms`
|
1435
|
+
# must match the call that provided the page token.
|
1436
|
+
# @param filter [::String]
|
1437
|
+
# Optional. The filter request.
|
1438
|
+
# @param order_by [::String]
|
1439
|
+
# Optional. the order by fields for the result.
|
1440
|
+
# @param view [::Google::Cloud::VMMigration::V1::MigratingVmView]
|
1441
|
+
# Optional. The level of details of each migrating VM.
|
1442
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1443
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListMigratingVmsResponse]
|
1444
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1445
|
+
#
|
1446
|
+
# @return [::Google::Cloud::VMMigration::V1::ListMigratingVmsResponse]
|
1447
|
+
#
|
1448
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1449
|
+
def list_migrating_vms request, options = nil
|
1450
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1451
|
+
|
1452
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListMigratingVmsRequest
|
1453
|
+
|
1454
|
+
# Converts hash and nil to an options object
|
1455
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1456
|
+
|
1457
|
+
# Customize the options with defaults
|
1458
|
+
call_metadata = @config.rpcs.list_migrating_vms.metadata.to_h
|
1459
|
+
|
1460
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1461
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1462
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1463
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1464
|
+
transports_version_send: [:rest]
|
1465
|
+
|
1466
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1467
|
+
|
1468
|
+
options.apply_defaults timeout: @config.rpcs.list_migrating_vms.timeout,
|
1469
|
+
metadata: call_metadata,
|
1470
|
+
retry_policy: @config.rpcs.list_migrating_vms.retry_policy
|
1471
|
+
|
1472
|
+
options.apply_defaults timeout: @config.timeout,
|
1473
|
+
metadata: @config.metadata,
|
1474
|
+
retry_policy: @config.retry_policy
|
1475
|
+
|
1476
|
+
@vm_migration_stub.list_migrating_vms request, options do |result, operation|
|
1477
|
+
yield result, operation if block_given?
|
1478
|
+
return result
|
1479
|
+
end
|
1480
|
+
rescue ::Gapic::Rest::Error => e
|
1481
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1482
|
+
end
|
1483
|
+
|
1484
|
+
##
|
1485
|
+
# Gets details of a single MigratingVm.
|
1486
|
+
#
|
1487
|
+
# @overload get_migrating_vm(request, options = nil)
|
1488
|
+
# Pass arguments to `get_migrating_vm` via a request object, either of type
|
1489
|
+
# {::Google::Cloud::VMMigration::V1::GetMigratingVmRequest} or an equivalent Hash.
|
1490
|
+
#
|
1491
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetMigratingVmRequest, ::Hash]
|
1492
|
+
# A request object representing the call parameters. Required. To specify no
|
1493
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1494
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1495
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1496
|
+
#
|
1497
|
+
# @overload get_migrating_vm(name: nil, view: nil)
|
1498
|
+
# Pass arguments to `get_migrating_vm` via keyword arguments. Note that at
|
1499
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1500
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1501
|
+
#
|
1502
|
+
# @param name [::String]
|
1503
|
+
# Required. The name of the MigratingVm.
|
1504
|
+
# @param view [::Google::Cloud::VMMigration::V1::MigratingVmView]
|
1505
|
+
# Optional. The level of details of the migrating VM.
|
1506
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1507
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::MigratingVm]
|
1508
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1509
|
+
#
|
1510
|
+
# @return [::Google::Cloud::VMMigration::V1::MigratingVm]
|
1511
|
+
#
|
1512
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1513
|
+
def get_migrating_vm request, options = nil
|
1514
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1515
|
+
|
1516
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetMigratingVmRequest
|
1517
|
+
|
1518
|
+
# Converts hash and nil to an options object
|
1519
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1520
|
+
|
1521
|
+
# Customize the options with defaults
|
1522
|
+
call_metadata = @config.rpcs.get_migrating_vm.metadata.to_h
|
1523
|
+
|
1524
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1525
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1526
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1527
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1528
|
+
transports_version_send: [:rest]
|
1529
|
+
|
1530
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1531
|
+
|
1532
|
+
options.apply_defaults timeout: @config.rpcs.get_migrating_vm.timeout,
|
1533
|
+
metadata: call_metadata,
|
1534
|
+
retry_policy: @config.rpcs.get_migrating_vm.retry_policy
|
1535
|
+
|
1536
|
+
options.apply_defaults timeout: @config.timeout,
|
1537
|
+
metadata: @config.metadata,
|
1538
|
+
retry_policy: @config.retry_policy
|
1539
|
+
|
1540
|
+
@vm_migration_stub.get_migrating_vm request, options do |result, operation|
|
1541
|
+
yield result, operation if block_given?
|
1542
|
+
return result
|
1543
|
+
end
|
1544
|
+
rescue ::Gapic::Rest::Error => e
|
1545
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1546
|
+
end
|
1547
|
+
|
1548
|
+
##
|
1549
|
+
# Updates the parameters of a single MigratingVm.
|
1550
|
+
#
|
1551
|
+
# @overload update_migrating_vm(request, options = nil)
|
1552
|
+
# Pass arguments to `update_migrating_vm` via a request object, either of type
|
1553
|
+
# {::Google::Cloud::VMMigration::V1::UpdateMigratingVmRequest} or an equivalent Hash.
|
1554
|
+
#
|
1555
|
+
# @param request [::Google::Cloud::VMMigration::V1::UpdateMigratingVmRequest, ::Hash]
|
1556
|
+
# A request object representing the call parameters. Required. To specify no
|
1557
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1558
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1559
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1560
|
+
#
|
1561
|
+
# @overload update_migrating_vm(update_mask: nil, migrating_vm: nil, request_id: nil)
|
1562
|
+
# Pass arguments to `update_migrating_vm` via keyword arguments. Note that at
|
1563
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1564
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1565
|
+
#
|
1566
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
1567
|
+
# Field mask is used to specify the fields to be overwritten in the
|
1568
|
+
# MigratingVm resource by the update.
|
1569
|
+
# The fields specified in the update_mask are relative to the resource, not
|
1570
|
+
# the full request. A field will be overwritten if it is in the mask. If the
|
1571
|
+
# user does not provide a mask then all fields will be overwritten.
|
1572
|
+
# @param migrating_vm [::Google::Cloud::VMMigration::V1::MigratingVm, ::Hash]
|
1573
|
+
# Required. The update request body.
|
1574
|
+
# @param request_id [::String]
|
1575
|
+
# A request ID to identify requests. Specify a unique request ID
|
1576
|
+
# so that if you must retry your request, the server will know to ignore
|
1577
|
+
# the request if it has already been completed. The server will guarantee
|
1578
|
+
# that for at least 60 minutes since the first request.
|
1579
|
+
#
|
1580
|
+
# For example, consider a situation where you make an initial request and t
|
1581
|
+
# he request times out. If you make the request again with the same request
|
1582
|
+
# ID, the server can check if original operation with the same request ID
|
1583
|
+
# was received, and if so, will ignore the second request. This prevents
|
1584
|
+
# clients from accidentally creating duplicate commitments.
|
1585
|
+
#
|
1586
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1587
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1588
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1589
|
+
# @yieldparam result [::Gapic::Operation]
|
1590
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1591
|
+
#
|
1592
|
+
# @return [::Gapic::Operation]
|
1593
|
+
#
|
1594
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1595
|
+
def update_migrating_vm request, options = nil
|
1596
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1597
|
+
|
1598
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::UpdateMigratingVmRequest
|
1599
|
+
|
1600
|
+
# Converts hash and nil to an options object
|
1601
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1602
|
+
|
1603
|
+
# Customize the options with defaults
|
1604
|
+
call_metadata = @config.rpcs.update_migrating_vm.metadata.to_h
|
1605
|
+
|
1606
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1607
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1608
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1609
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1610
|
+
transports_version_send: [:rest]
|
1611
|
+
|
1612
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1613
|
+
|
1614
|
+
options.apply_defaults timeout: @config.rpcs.update_migrating_vm.timeout,
|
1615
|
+
metadata: call_metadata,
|
1616
|
+
retry_policy: @config.rpcs.update_migrating_vm.retry_policy
|
1617
|
+
|
1618
|
+
options.apply_defaults timeout: @config.timeout,
|
1619
|
+
metadata: @config.metadata,
|
1620
|
+
retry_policy: @config.retry_policy
|
1621
|
+
|
1622
|
+
@vm_migration_stub.update_migrating_vm request, options do |result, operation|
|
1623
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1624
|
+
yield result, operation if block_given?
|
1625
|
+
return result
|
1626
|
+
end
|
1627
|
+
rescue ::Gapic::Rest::Error => e
|
1628
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1629
|
+
end
|
1630
|
+
|
1631
|
+
##
|
1632
|
+
# Deletes a single MigratingVm.
|
1633
|
+
#
|
1634
|
+
# @overload delete_migrating_vm(request, options = nil)
|
1635
|
+
# Pass arguments to `delete_migrating_vm` via a request object, either of type
|
1636
|
+
# {::Google::Cloud::VMMigration::V1::DeleteMigratingVmRequest} or an equivalent Hash.
|
1637
|
+
#
|
1638
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteMigratingVmRequest, ::Hash]
|
1639
|
+
# A request object representing the call parameters. Required. To specify no
|
1640
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1641
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1642
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1643
|
+
#
|
1644
|
+
# @overload delete_migrating_vm(name: nil)
|
1645
|
+
# Pass arguments to `delete_migrating_vm` via keyword arguments. Note that at
|
1646
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1647
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1648
|
+
#
|
1649
|
+
# @param name [::String]
|
1650
|
+
# Required. The name of the MigratingVm.
|
1651
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1652
|
+
# @yieldparam result [::Gapic::Operation]
|
1653
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1654
|
+
#
|
1655
|
+
# @return [::Gapic::Operation]
|
1656
|
+
#
|
1657
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1658
|
+
def delete_migrating_vm request, options = nil
|
1659
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1660
|
+
|
1661
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteMigratingVmRequest
|
1662
|
+
|
1663
|
+
# Converts hash and nil to an options object
|
1664
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1665
|
+
|
1666
|
+
# Customize the options with defaults
|
1667
|
+
call_metadata = @config.rpcs.delete_migrating_vm.metadata.to_h
|
1668
|
+
|
1669
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1670
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1671
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1672
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1673
|
+
transports_version_send: [:rest]
|
1674
|
+
|
1675
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1676
|
+
|
1677
|
+
options.apply_defaults timeout: @config.rpcs.delete_migrating_vm.timeout,
|
1678
|
+
metadata: call_metadata,
|
1679
|
+
retry_policy: @config.rpcs.delete_migrating_vm.retry_policy
|
1680
|
+
|
1681
|
+
options.apply_defaults timeout: @config.timeout,
|
1682
|
+
metadata: @config.metadata,
|
1683
|
+
retry_policy: @config.retry_policy
|
1684
|
+
|
1685
|
+
@vm_migration_stub.delete_migrating_vm request, options do |result, operation|
|
1686
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1687
|
+
yield result, operation if block_given?
|
1688
|
+
return result
|
1689
|
+
end
|
1690
|
+
rescue ::Gapic::Rest::Error => e
|
1691
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1692
|
+
end
|
1693
|
+
|
1694
|
+
##
|
1695
|
+
# Starts migration for a VM. Starts the process of uploading
|
1696
|
+
# data and creating snapshots, in replication cycles scheduled by the policy.
|
1697
|
+
#
|
1698
|
+
# @overload start_migration(request, options = nil)
|
1699
|
+
# Pass arguments to `start_migration` via a request object, either of type
|
1700
|
+
# {::Google::Cloud::VMMigration::V1::StartMigrationRequest} or an equivalent Hash.
|
1701
|
+
#
|
1702
|
+
# @param request [::Google::Cloud::VMMigration::V1::StartMigrationRequest, ::Hash]
|
1703
|
+
# A request object representing the call parameters. Required. To specify no
|
1704
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1705
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1706
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1707
|
+
#
|
1708
|
+
# @overload start_migration(migrating_vm: nil)
|
1709
|
+
# Pass arguments to `start_migration` via keyword arguments. Note that at
|
1710
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1711
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1712
|
+
#
|
1713
|
+
# @param migrating_vm [::String]
|
1714
|
+
# Required. The name of the MigratingVm.
|
1715
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1716
|
+
# @yieldparam result [::Gapic::Operation]
|
1717
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1718
|
+
#
|
1719
|
+
# @return [::Gapic::Operation]
|
1720
|
+
#
|
1721
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1722
|
+
def start_migration request, options = nil
|
1723
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1724
|
+
|
1725
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::StartMigrationRequest
|
1726
|
+
|
1727
|
+
# Converts hash and nil to an options object
|
1728
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1729
|
+
|
1730
|
+
# Customize the options with defaults
|
1731
|
+
call_metadata = @config.rpcs.start_migration.metadata.to_h
|
1732
|
+
|
1733
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1734
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1735
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1736
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1737
|
+
transports_version_send: [:rest]
|
1738
|
+
|
1739
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1740
|
+
|
1741
|
+
options.apply_defaults timeout: @config.rpcs.start_migration.timeout,
|
1742
|
+
metadata: call_metadata,
|
1743
|
+
retry_policy: @config.rpcs.start_migration.retry_policy
|
1744
|
+
|
1745
|
+
options.apply_defaults timeout: @config.timeout,
|
1746
|
+
metadata: @config.metadata,
|
1747
|
+
retry_policy: @config.retry_policy
|
1748
|
+
|
1749
|
+
@vm_migration_stub.start_migration request, options do |result, operation|
|
1750
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1751
|
+
yield result, operation if block_given?
|
1752
|
+
return result
|
1753
|
+
end
|
1754
|
+
rescue ::Gapic::Rest::Error => e
|
1755
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1756
|
+
end
|
1757
|
+
|
1758
|
+
##
|
1759
|
+
# Resumes a migration for a VM. When called on a paused migration, will start
|
1760
|
+
# the process of uploading data and creating snapshots; when called on a
|
1761
|
+
# completed cut-over migration, will update the migration to active state and
|
1762
|
+
# start the process of uploading data and creating snapshots.
|
1763
|
+
#
|
1764
|
+
# @overload resume_migration(request, options = nil)
|
1765
|
+
# Pass arguments to `resume_migration` via a request object, either of type
|
1766
|
+
# {::Google::Cloud::VMMigration::V1::ResumeMigrationRequest} or an equivalent Hash.
|
1767
|
+
#
|
1768
|
+
# @param request [::Google::Cloud::VMMigration::V1::ResumeMigrationRequest, ::Hash]
|
1769
|
+
# A request object representing the call parameters. Required. To specify no
|
1770
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1771
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1772
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1773
|
+
#
|
1774
|
+
# @overload resume_migration(migrating_vm: nil)
|
1775
|
+
# Pass arguments to `resume_migration` via keyword arguments. Note that at
|
1776
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1777
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1778
|
+
#
|
1779
|
+
# @param migrating_vm [::String]
|
1780
|
+
# Required. The name of the MigratingVm.
|
1781
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1782
|
+
# @yieldparam result [::Gapic::Operation]
|
1783
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1784
|
+
#
|
1785
|
+
# @return [::Gapic::Operation]
|
1786
|
+
#
|
1787
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1788
|
+
def resume_migration request, options = nil
|
1789
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1790
|
+
|
1791
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ResumeMigrationRequest
|
1792
|
+
|
1793
|
+
# Converts hash and nil to an options object
|
1794
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1795
|
+
|
1796
|
+
# Customize the options with defaults
|
1797
|
+
call_metadata = @config.rpcs.resume_migration.metadata.to_h
|
1798
|
+
|
1799
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1800
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1801
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1802
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1803
|
+
transports_version_send: [:rest]
|
1804
|
+
|
1805
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1806
|
+
|
1807
|
+
options.apply_defaults timeout: @config.rpcs.resume_migration.timeout,
|
1808
|
+
metadata: call_metadata,
|
1809
|
+
retry_policy: @config.rpcs.resume_migration.retry_policy
|
1810
|
+
|
1811
|
+
options.apply_defaults timeout: @config.timeout,
|
1812
|
+
metadata: @config.metadata,
|
1813
|
+
retry_policy: @config.retry_policy
|
1814
|
+
|
1815
|
+
@vm_migration_stub.resume_migration request, options do |result, operation|
|
1816
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1817
|
+
yield result, operation if block_given?
|
1818
|
+
return result
|
1819
|
+
end
|
1820
|
+
rescue ::Gapic::Rest::Error => e
|
1821
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1822
|
+
end
|
1823
|
+
|
1824
|
+
##
|
1825
|
+
# Pauses a migration for a VM. If cycle tasks are running they will be
|
1826
|
+
# cancelled, preserving source task data. Further replication cycles will not
|
1827
|
+
# be triggered while the VM is paused.
|
1828
|
+
#
|
1829
|
+
# @overload pause_migration(request, options = nil)
|
1830
|
+
# Pass arguments to `pause_migration` via a request object, either of type
|
1831
|
+
# {::Google::Cloud::VMMigration::V1::PauseMigrationRequest} or an equivalent Hash.
|
1832
|
+
#
|
1833
|
+
# @param request [::Google::Cloud::VMMigration::V1::PauseMigrationRequest, ::Hash]
|
1834
|
+
# A request object representing the call parameters. Required. To specify no
|
1835
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1836
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1837
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1838
|
+
#
|
1839
|
+
# @overload pause_migration(migrating_vm: nil)
|
1840
|
+
# Pass arguments to `pause_migration` via keyword arguments. Note that at
|
1841
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1842
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1843
|
+
#
|
1844
|
+
# @param migrating_vm [::String]
|
1845
|
+
# Required. The name of the MigratingVm.
|
1846
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1847
|
+
# @yieldparam result [::Gapic::Operation]
|
1848
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1849
|
+
#
|
1850
|
+
# @return [::Gapic::Operation]
|
1851
|
+
#
|
1852
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1853
|
+
def pause_migration request, options = nil
|
1854
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1855
|
+
|
1856
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::PauseMigrationRequest
|
1857
|
+
|
1858
|
+
# Converts hash and nil to an options object
|
1859
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1860
|
+
|
1861
|
+
# Customize the options with defaults
|
1862
|
+
call_metadata = @config.rpcs.pause_migration.metadata.to_h
|
1863
|
+
|
1864
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1865
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1866
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1867
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1868
|
+
transports_version_send: [:rest]
|
1869
|
+
|
1870
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1871
|
+
|
1872
|
+
options.apply_defaults timeout: @config.rpcs.pause_migration.timeout,
|
1873
|
+
metadata: call_metadata,
|
1874
|
+
retry_policy: @config.rpcs.pause_migration.retry_policy
|
1875
|
+
|
1876
|
+
options.apply_defaults timeout: @config.timeout,
|
1877
|
+
metadata: @config.metadata,
|
1878
|
+
retry_policy: @config.retry_policy
|
1879
|
+
|
1880
|
+
@vm_migration_stub.pause_migration request, options do |result, operation|
|
1881
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1882
|
+
yield result, operation if block_given?
|
1883
|
+
return result
|
1884
|
+
end
|
1885
|
+
rescue ::Gapic::Rest::Error => e
|
1886
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1887
|
+
end
|
1888
|
+
|
1889
|
+
##
|
1890
|
+
# Marks a migration as completed, deleting migration resources that are no
|
1891
|
+
# longer being used. Only applicable after cutover is done.
|
1892
|
+
#
|
1893
|
+
# @overload finalize_migration(request, options = nil)
|
1894
|
+
# Pass arguments to `finalize_migration` via a request object, either of type
|
1895
|
+
# {::Google::Cloud::VMMigration::V1::FinalizeMigrationRequest} or an equivalent Hash.
|
1896
|
+
#
|
1897
|
+
# @param request [::Google::Cloud::VMMigration::V1::FinalizeMigrationRequest, ::Hash]
|
1898
|
+
# A request object representing the call parameters. Required. To specify no
|
1899
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1900
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1901
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1902
|
+
#
|
1903
|
+
# @overload finalize_migration(migrating_vm: nil)
|
1904
|
+
# Pass arguments to `finalize_migration` via keyword arguments. Note that at
|
1905
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1906
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1907
|
+
#
|
1908
|
+
# @param migrating_vm [::String]
|
1909
|
+
# Required. The name of the MigratingVm.
|
1910
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1911
|
+
# @yieldparam result [::Gapic::Operation]
|
1912
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1913
|
+
#
|
1914
|
+
# @return [::Gapic::Operation]
|
1915
|
+
#
|
1916
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1917
|
+
def finalize_migration request, options = nil
|
1918
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1919
|
+
|
1920
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::FinalizeMigrationRequest
|
1921
|
+
|
1922
|
+
# Converts hash and nil to an options object
|
1923
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1924
|
+
|
1925
|
+
# Customize the options with defaults
|
1926
|
+
call_metadata = @config.rpcs.finalize_migration.metadata.to_h
|
1927
|
+
|
1928
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
1929
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1930
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1931
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
1932
|
+
transports_version_send: [:rest]
|
1933
|
+
|
1934
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1935
|
+
|
1936
|
+
options.apply_defaults timeout: @config.rpcs.finalize_migration.timeout,
|
1937
|
+
metadata: call_metadata,
|
1938
|
+
retry_policy: @config.rpcs.finalize_migration.retry_policy
|
1939
|
+
|
1940
|
+
options.apply_defaults timeout: @config.timeout,
|
1941
|
+
metadata: @config.metadata,
|
1942
|
+
retry_policy: @config.retry_policy
|
1943
|
+
|
1944
|
+
@vm_migration_stub.finalize_migration request, options do |result, operation|
|
1945
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
1946
|
+
yield result, operation if block_given?
|
1947
|
+
return result
|
1948
|
+
end
|
1949
|
+
rescue ::Gapic::Rest::Error => e
|
1950
|
+
raise ::Google::Cloud::Error.from_error(e)
|
1951
|
+
end
|
1952
|
+
|
1953
|
+
##
|
1954
|
+
# Initiates a Clone of a specific migrating VM.
|
1955
|
+
#
|
1956
|
+
# @overload create_clone_job(request, options = nil)
|
1957
|
+
# Pass arguments to `create_clone_job` via a request object, either of type
|
1958
|
+
# {::Google::Cloud::VMMigration::V1::CreateCloneJobRequest} or an equivalent Hash.
|
1959
|
+
#
|
1960
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateCloneJobRequest, ::Hash]
|
1961
|
+
# A request object representing the call parameters. Required. To specify no
|
1962
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1963
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1964
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1965
|
+
#
|
1966
|
+
# @overload create_clone_job(parent: nil, clone_job_id: nil, clone_job: nil, request_id: nil)
|
1967
|
+
# Pass arguments to `create_clone_job` via keyword arguments. Note that at
|
1968
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1969
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1970
|
+
#
|
1971
|
+
# @param parent [::String]
|
1972
|
+
# Required. The Clone's parent.
|
1973
|
+
# @param clone_job_id [::String]
|
1974
|
+
# Required. The clone job identifier.
|
1975
|
+
# @param clone_job [::Google::Cloud::VMMigration::V1::CloneJob, ::Hash]
|
1976
|
+
# Required. The clone request body.
|
1977
|
+
# @param request_id [::String]
|
1978
|
+
# A request ID to identify requests. Specify a unique request ID
|
1979
|
+
# so that if you must retry your request, the server will know to ignore
|
1980
|
+
# the request if it has already been completed. The server will guarantee
|
1981
|
+
# that for at least 60 minutes since the first request.
|
1982
|
+
#
|
1983
|
+
# For example, consider a situation where you make an initial request and t
|
1984
|
+
# he request times out. If you make the request again with the same request
|
1985
|
+
# ID, the server can check if original operation with the same request ID
|
1986
|
+
# was received, and if so, will ignore the second request. This prevents
|
1987
|
+
# clients from accidentally creating duplicate commitments.
|
1988
|
+
#
|
1989
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
1990
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
1991
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1992
|
+
# @yieldparam result [::Gapic::Operation]
|
1993
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1994
|
+
#
|
1995
|
+
# @return [::Gapic::Operation]
|
1996
|
+
#
|
1997
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1998
|
+
def create_clone_job request, options = nil
|
1999
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2000
|
+
|
2001
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateCloneJobRequest
|
2002
|
+
|
2003
|
+
# Converts hash and nil to an options object
|
2004
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2005
|
+
|
2006
|
+
# Customize the options with defaults
|
2007
|
+
call_metadata = @config.rpcs.create_clone_job.metadata.to_h
|
2008
|
+
|
2009
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2010
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2011
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2012
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2013
|
+
transports_version_send: [:rest]
|
2014
|
+
|
2015
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2016
|
+
|
2017
|
+
options.apply_defaults timeout: @config.rpcs.create_clone_job.timeout,
|
2018
|
+
metadata: call_metadata,
|
2019
|
+
retry_policy: @config.rpcs.create_clone_job.retry_policy
|
2020
|
+
|
2021
|
+
options.apply_defaults timeout: @config.timeout,
|
2022
|
+
metadata: @config.metadata,
|
2023
|
+
retry_policy: @config.retry_policy
|
2024
|
+
|
2025
|
+
@vm_migration_stub.create_clone_job request, options do |result, operation|
|
2026
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2027
|
+
yield result, operation if block_given?
|
2028
|
+
return result
|
2029
|
+
end
|
2030
|
+
rescue ::Gapic::Rest::Error => e
|
2031
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2032
|
+
end
|
2033
|
+
|
2034
|
+
##
|
2035
|
+
# Initiates the cancellation of a running clone job.
|
2036
|
+
#
|
2037
|
+
# @overload cancel_clone_job(request, options = nil)
|
2038
|
+
# Pass arguments to `cancel_clone_job` via a request object, either of type
|
2039
|
+
# {::Google::Cloud::VMMigration::V1::CancelCloneJobRequest} or an equivalent Hash.
|
2040
|
+
#
|
2041
|
+
# @param request [::Google::Cloud::VMMigration::V1::CancelCloneJobRequest, ::Hash]
|
2042
|
+
# A request object representing the call parameters. Required. To specify no
|
2043
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2044
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2045
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2046
|
+
#
|
2047
|
+
# @overload cancel_clone_job(name: nil)
|
2048
|
+
# Pass arguments to `cancel_clone_job` via keyword arguments. Note that at
|
2049
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2050
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2051
|
+
#
|
2052
|
+
# @param name [::String]
|
2053
|
+
# Required. The clone job id
|
2054
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2055
|
+
# @yieldparam result [::Gapic::Operation]
|
2056
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2057
|
+
#
|
2058
|
+
# @return [::Gapic::Operation]
|
2059
|
+
#
|
2060
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2061
|
+
def cancel_clone_job request, options = nil
|
2062
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2063
|
+
|
2064
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CancelCloneJobRequest
|
2065
|
+
|
2066
|
+
# Converts hash and nil to an options object
|
2067
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2068
|
+
|
2069
|
+
# Customize the options with defaults
|
2070
|
+
call_metadata = @config.rpcs.cancel_clone_job.metadata.to_h
|
2071
|
+
|
2072
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2073
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2074
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2075
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2076
|
+
transports_version_send: [:rest]
|
2077
|
+
|
2078
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2079
|
+
|
2080
|
+
options.apply_defaults timeout: @config.rpcs.cancel_clone_job.timeout,
|
2081
|
+
metadata: call_metadata,
|
2082
|
+
retry_policy: @config.rpcs.cancel_clone_job.retry_policy
|
2083
|
+
|
2084
|
+
options.apply_defaults timeout: @config.timeout,
|
2085
|
+
metadata: @config.metadata,
|
2086
|
+
retry_policy: @config.retry_policy
|
2087
|
+
|
2088
|
+
@vm_migration_stub.cancel_clone_job request, options do |result, operation|
|
2089
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2090
|
+
yield result, operation if block_given?
|
2091
|
+
return result
|
2092
|
+
end
|
2093
|
+
rescue ::Gapic::Rest::Error => e
|
2094
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2095
|
+
end
|
2096
|
+
|
2097
|
+
##
|
2098
|
+
# Lists CloneJobs of a given migrating VM.
|
2099
|
+
#
|
2100
|
+
# @overload list_clone_jobs(request, options = nil)
|
2101
|
+
# Pass arguments to `list_clone_jobs` via a request object, either of type
|
2102
|
+
# {::Google::Cloud::VMMigration::V1::ListCloneJobsRequest} or an equivalent Hash.
|
2103
|
+
#
|
2104
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListCloneJobsRequest, ::Hash]
|
2105
|
+
# A request object representing the call parameters. Required. To specify no
|
2106
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2107
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2108
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2109
|
+
#
|
2110
|
+
# @overload list_clone_jobs(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
2111
|
+
# Pass arguments to `list_clone_jobs` via keyword arguments. Note that at
|
2112
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2113
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2114
|
+
#
|
2115
|
+
# @param parent [::String]
|
2116
|
+
# Required. The parent, which owns this collection of source VMs.
|
2117
|
+
# @param page_size [::Integer]
|
2118
|
+
# Optional. The maximum number of clone jobs to return. The service may
|
2119
|
+
# return fewer than this value. If unspecified, at most 500 clone jobs will
|
2120
|
+
# be returned. The maximum value is 1000; values above 1000 will be coerced
|
2121
|
+
# to 1000.
|
2122
|
+
# @param page_token [::String]
|
2123
|
+
# Required. A page token, received from a previous `ListCloneJobs` call.
|
2124
|
+
# Provide this to retrieve the subsequent page.
|
2125
|
+
#
|
2126
|
+
# When paginating, all other parameters provided to `ListCloneJobs` must
|
2127
|
+
# match the call that provided the page token.
|
2128
|
+
# @param filter [::String]
|
2129
|
+
# Optional. The filter request.
|
2130
|
+
# @param order_by [::String]
|
2131
|
+
# Optional. the order by fields for the result.
|
2132
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2133
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListCloneJobsResponse]
|
2134
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2135
|
+
#
|
2136
|
+
# @return [::Google::Cloud::VMMigration::V1::ListCloneJobsResponse]
|
2137
|
+
#
|
2138
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2139
|
+
def list_clone_jobs request, options = nil
|
2140
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2141
|
+
|
2142
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListCloneJobsRequest
|
2143
|
+
|
2144
|
+
# Converts hash and nil to an options object
|
2145
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2146
|
+
|
2147
|
+
# Customize the options with defaults
|
2148
|
+
call_metadata = @config.rpcs.list_clone_jobs.metadata.to_h
|
2149
|
+
|
2150
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2151
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2152
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2153
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2154
|
+
transports_version_send: [:rest]
|
2155
|
+
|
2156
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2157
|
+
|
2158
|
+
options.apply_defaults timeout: @config.rpcs.list_clone_jobs.timeout,
|
2159
|
+
metadata: call_metadata,
|
2160
|
+
retry_policy: @config.rpcs.list_clone_jobs.retry_policy
|
2161
|
+
|
2162
|
+
options.apply_defaults timeout: @config.timeout,
|
2163
|
+
metadata: @config.metadata,
|
2164
|
+
retry_policy: @config.retry_policy
|
2165
|
+
|
2166
|
+
@vm_migration_stub.list_clone_jobs request, options do |result, operation|
|
2167
|
+
yield result, operation if block_given?
|
2168
|
+
return result
|
2169
|
+
end
|
2170
|
+
rescue ::Gapic::Rest::Error => e
|
2171
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2172
|
+
end
|
2173
|
+
|
2174
|
+
##
|
2175
|
+
# Gets details of a single CloneJob.
|
2176
|
+
#
|
2177
|
+
# @overload get_clone_job(request, options = nil)
|
2178
|
+
# Pass arguments to `get_clone_job` via a request object, either of type
|
2179
|
+
# {::Google::Cloud::VMMigration::V1::GetCloneJobRequest} or an equivalent Hash.
|
2180
|
+
#
|
2181
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetCloneJobRequest, ::Hash]
|
2182
|
+
# A request object representing the call parameters. Required. To specify no
|
2183
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2184
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2185
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2186
|
+
#
|
2187
|
+
# @overload get_clone_job(name: nil)
|
2188
|
+
# Pass arguments to `get_clone_job` via keyword arguments. Note that at
|
2189
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2190
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2191
|
+
#
|
2192
|
+
# @param name [::String]
|
2193
|
+
# Required. The name of the CloneJob.
|
2194
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2195
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::CloneJob]
|
2196
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2197
|
+
#
|
2198
|
+
# @return [::Google::Cloud::VMMigration::V1::CloneJob]
|
2199
|
+
#
|
2200
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2201
|
+
def get_clone_job request, options = nil
|
2202
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2203
|
+
|
2204
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetCloneJobRequest
|
2205
|
+
|
2206
|
+
# Converts hash and nil to an options object
|
2207
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2208
|
+
|
2209
|
+
# Customize the options with defaults
|
2210
|
+
call_metadata = @config.rpcs.get_clone_job.metadata.to_h
|
2211
|
+
|
2212
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2213
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2214
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2215
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2216
|
+
transports_version_send: [:rest]
|
2217
|
+
|
2218
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2219
|
+
|
2220
|
+
options.apply_defaults timeout: @config.rpcs.get_clone_job.timeout,
|
2221
|
+
metadata: call_metadata,
|
2222
|
+
retry_policy: @config.rpcs.get_clone_job.retry_policy
|
2223
|
+
|
2224
|
+
options.apply_defaults timeout: @config.timeout,
|
2225
|
+
metadata: @config.metadata,
|
2226
|
+
retry_policy: @config.retry_policy
|
2227
|
+
|
2228
|
+
@vm_migration_stub.get_clone_job request, options do |result, operation|
|
2229
|
+
yield result, operation if block_given?
|
2230
|
+
return result
|
2231
|
+
end
|
2232
|
+
rescue ::Gapic::Rest::Error => e
|
2233
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2234
|
+
end
|
2235
|
+
|
2236
|
+
##
|
2237
|
+
# Initiates a Cutover of a specific migrating VM.
|
2238
|
+
# The returned LRO is completed when the cutover job resource is created
|
2239
|
+
# and the job is initiated.
|
2240
|
+
#
|
2241
|
+
# @overload create_cutover_job(request, options = nil)
|
2242
|
+
# Pass arguments to `create_cutover_job` via a request object, either of type
|
2243
|
+
# {::Google::Cloud::VMMigration::V1::CreateCutoverJobRequest} or an equivalent Hash.
|
2244
|
+
#
|
2245
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateCutoverJobRequest, ::Hash]
|
2246
|
+
# A request object representing the call parameters. Required. To specify no
|
2247
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2248
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2249
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2250
|
+
#
|
2251
|
+
# @overload create_cutover_job(parent: nil, cutover_job_id: nil, cutover_job: nil, request_id: nil)
|
2252
|
+
# Pass arguments to `create_cutover_job` via keyword arguments. Note that at
|
2253
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2254
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2255
|
+
#
|
2256
|
+
# @param parent [::String]
|
2257
|
+
# Required. The Cutover's parent.
|
2258
|
+
# @param cutover_job_id [::String]
|
2259
|
+
# Required. The cutover job identifier.
|
2260
|
+
# @param cutover_job [::Google::Cloud::VMMigration::V1::CutoverJob, ::Hash]
|
2261
|
+
# Required. The cutover request body.
|
2262
|
+
# @param request_id [::String]
|
2263
|
+
# A request ID to identify requests. Specify a unique request ID
|
2264
|
+
# so that if you must retry your request, the server will know to ignore
|
2265
|
+
# the request if it has already been completed. The server will guarantee
|
2266
|
+
# that for at least 60 minutes since the first request.
|
2267
|
+
#
|
2268
|
+
# For example, consider a situation where you make an initial request and t
|
2269
|
+
# he request times out. If you make the request again with the same request
|
2270
|
+
# ID, the server can check if original operation with the same request ID
|
2271
|
+
# was received, and if so, will ignore the second request. This prevents
|
2272
|
+
# clients from accidentally creating duplicate commitments.
|
2273
|
+
#
|
2274
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
2275
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
2276
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2277
|
+
# @yieldparam result [::Gapic::Operation]
|
2278
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2279
|
+
#
|
2280
|
+
# @return [::Gapic::Operation]
|
2281
|
+
#
|
2282
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2283
|
+
def create_cutover_job request, options = nil
|
2284
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2285
|
+
|
2286
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateCutoverJobRequest
|
2287
|
+
|
2288
|
+
# Converts hash and nil to an options object
|
2289
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2290
|
+
|
2291
|
+
# Customize the options with defaults
|
2292
|
+
call_metadata = @config.rpcs.create_cutover_job.metadata.to_h
|
2293
|
+
|
2294
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2295
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2296
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2297
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2298
|
+
transports_version_send: [:rest]
|
2299
|
+
|
2300
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2301
|
+
|
2302
|
+
options.apply_defaults timeout: @config.rpcs.create_cutover_job.timeout,
|
2303
|
+
metadata: call_metadata,
|
2304
|
+
retry_policy: @config.rpcs.create_cutover_job.retry_policy
|
2305
|
+
|
2306
|
+
options.apply_defaults timeout: @config.timeout,
|
2307
|
+
metadata: @config.metadata,
|
2308
|
+
retry_policy: @config.retry_policy
|
2309
|
+
|
2310
|
+
@vm_migration_stub.create_cutover_job request, options do |result, operation|
|
2311
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2312
|
+
yield result, operation if block_given?
|
2313
|
+
return result
|
2314
|
+
end
|
2315
|
+
rescue ::Gapic::Rest::Error => e
|
2316
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2317
|
+
end
|
2318
|
+
|
2319
|
+
##
|
2320
|
+
# Initiates the cancellation of a running cutover job.
|
2321
|
+
#
|
2322
|
+
# @overload cancel_cutover_job(request, options = nil)
|
2323
|
+
# Pass arguments to `cancel_cutover_job` via a request object, either of type
|
2324
|
+
# {::Google::Cloud::VMMigration::V1::CancelCutoverJobRequest} or an equivalent Hash.
|
2325
|
+
#
|
2326
|
+
# @param request [::Google::Cloud::VMMigration::V1::CancelCutoverJobRequest, ::Hash]
|
2327
|
+
# A request object representing the call parameters. Required. To specify no
|
2328
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2329
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2330
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2331
|
+
#
|
2332
|
+
# @overload cancel_cutover_job(name: nil)
|
2333
|
+
# Pass arguments to `cancel_cutover_job` via keyword arguments. Note that at
|
2334
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2335
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2336
|
+
#
|
2337
|
+
# @param name [::String]
|
2338
|
+
# Required. The cutover job id
|
2339
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2340
|
+
# @yieldparam result [::Gapic::Operation]
|
2341
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2342
|
+
#
|
2343
|
+
# @return [::Gapic::Operation]
|
2344
|
+
#
|
2345
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2346
|
+
def cancel_cutover_job request, options = nil
|
2347
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2348
|
+
|
2349
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CancelCutoverJobRequest
|
2350
|
+
|
2351
|
+
# Converts hash and nil to an options object
|
2352
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2353
|
+
|
2354
|
+
# Customize the options with defaults
|
2355
|
+
call_metadata = @config.rpcs.cancel_cutover_job.metadata.to_h
|
2356
|
+
|
2357
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2358
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2359
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2360
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2361
|
+
transports_version_send: [:rest]
|
2362
|
+
|
2363
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2364
|
+
|
2365
|
+
options.apply_defaults timeout: @config.rpcs.cancel_cutover_job.timeout,
|
2366
|
+
metadata: call_metadata,
|
2367
|
+
retry_policy: @config.rpcs.cancel_cutover_job.retry_policy
|
2368
|
+
|
2369
|
+
options.apply_defaults timeout: @config.timeout,
|
2370
|
+
metadata: @config.metadata,
|
2371
|
+
retry_policy: @config.retry_policy
|
2372
|
+
|
2373
|
+
@vm_migration_stub.cancel_cutover_job request, options do |result, operation|
|
2374
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2375
|
+
yield result, operation if block_given?
|
2376
|
+
return result
|
2377
|
+
end
|
2378
|
+
rescue ::Gapic::Rest::Error => e
|
2379
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2380
|
+
end
|
2381
|
+
|
2382
|
+
##
|
2383
|
+
# Lists CutoverJobs of a given migrating VM.
|
2384
|
+
#
|
2385
|
+
# @overload list_cutover_jobs(request, options = nil)
|
2386
|
+
# Pass arguments to `list_cutover_jobs` via a request object, either of type
|
2387
|
+
# {::Google::Cloud::VMMigration::V1::ListCutoverJobsRequest} or an equivalent Hash.
|
2388
|
+
#
|
2389
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListCutoverJobsRequest, ::Hash]
|
2390
|
+
# A request object representing the call parameters. Required. To specify no
|
2391
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2392
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2393
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2394
|
+
#
|
2395
|
+
# @overload list_cutover_jobs(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
2396
|
+
# Pass arguments to `list_cutover_jobs` via keyword arguments. Note that at
|
2397
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2398
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2399
|
+
#
|
2400
|
+
# @param parent [::String]
|
2401
|
+
# Required. The parent, which owns this collection of migrating VMs.
|
2402
|
+
# @param page_size [::Integer]
|
2403
|
+
# Optional. The maximum number of cutover jobs to return. The service may
|
2404
|
+
# return fewer than this value. If unspecified, at most 500 cutover jobs will
|
2405
|
+
# be returned. The maximum value is 1000; values above 1000 will be coerced
|
2406
|
+
# to 1000.
|
2407
|
+
# @param page_token [::String]
|
2408
|
+
# Required. A page token, received from a previous `ListCutoverJobs` call.
|
2409
|
+
# Provide this to retrieve the subsequent page.
|
2410
|
+
#
|
2411
|
+
# When paginating, all other parameters provided to `ListCutoverJobs` must
|
2412
|
+
# match the call that provided the page token.
|
2413
|
+
# @param filter [::String]
|
2414
|
+
# Optional. The filter request.
|
2415
|
+
# @param order_by [::String]
|
2416
|
+
# Optional. the order by fields for the result.
|
2417
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2418
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListCutoverJobsResponse]
|
2419
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2420
|
+
#
|
2421
|
+
# @return [::Google::Cloud::VMMigration::V1::ListCutoverJobsResponse]
|
2422
|
+
#
|
2423
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2424
|
+
def list_cutover_jobs request, options = nil
|
2425
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2426
|
+
|
2427
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListCutoverJobsRequest
|
2428
|
+
|
2429
|
+
# Converts hash and nil to an options object
|
2430
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2431
|
+
|
2432
|
+
# Customize the options with defaults
|
2433
|
+
call_metadata = @config.rpcs.list_cutover_jobs.metadata.to_h
|
2434
|
+
|
2435
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2436
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2437
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2438
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2439
|
+
transports_version_send: [:rest]
|
2440
|
+
|
2441
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2442
|
+
|
2443
|
+
options.apply_defaults timeout: @config.rpcs.list_cutover_jobs.timeout,
|
2444
|
+
metadata: call_metadata,
|
2445
|
+
retry_policy: @config.rpcs.list_cutover_jobs.retry_policy
|
2446
|
+
|
2447
|
+
options.apply_defaults timeout: @config.timeout,
|
2448
|
+
metadata: @config.metadata,
|
2449
|
+
retry_policy: @config.retry_policy
|
2450
|
+
|
2451
|
+
@vm_migration_stub.list_cutover_jobs request, options do |result, operation|
|
2452
|
+
yield result, operation if block_given?
|
2453
|
+
return result
|
2454
|
+
end
|
2455
|
+
rescue ::Gapic::Rest::Error => e
|
2456
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2457
|
+
end
|
2458
|
+
|
2459
|
+
##
|
2460
|
+
# Gets details of a single CutoverJob.
|
2461
|
+
#
|
2462
|
+
# @overload get_cutover_job(request, options = nil)
|
2463
|
+
# Pass arguments to `get_cutover_job` via a request object, either of type
|
2464
|
+
# {::Google::Cloud::VMMigration::V1::GetCutoverJobRequest} or an equivalent Hash.
|
2465
|
+
#
|
2466
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetCutoverJobRequest, ::Hash]
|
2467
|
+
# A request object representing the call parameters. Required. To specify no
|
2468
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2469
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2470
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2471
|
+
#
|
2472
|
+
# @overload get_cutover_job(name: nil)
|
2473
|
+
# Pass arguments to `get_cutover_job` via keyword arguments. Note that at
|
2474
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2475
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2476
|
+
#
|
2477
|
+
# @param name [::String]
|
2478
|
+
# Required. The name of the CutoverJob.
|
2479
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2480
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::CutoverJob]
|
2481
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2482
|
+
#
|
2483
|
+
# @return [::Google::Cloud::VMMigration::V1::CutoverJob]
|
2484
|
+
#
|
2485
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2486
|
+
def get_cutover_job request, options = nil
|
2487
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2488
|
+
|
2489
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetCutoverJobRequest
|
2490
|
+
|
2491
|
+
# Converts hash and nil to an options object
|
2492
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2493
|
+
|
2494
|
+
# Customize the options with defaults
|
2495
|
+
call_metadata = @config.rpcs.get_cutover_job.metadata.to_h
|
2496
|
+
|
2497
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2498
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2499
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2500
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2501
|
+
transports_version_send: [:rest]
|
2502
|
+
|
2503
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2504
|
+
|
2505
|
+
options.apply_defaults timeout: @config.rpcs.get_cutover_job.timeout,
|
2506
|
+
metadata: call_metadata,
|
2507
|
+
retry_policy: @config.rpcs.get_cutover_job.retry_policy
|
2508
|
+
|
2509
|
+
options.apply_defaults timeout: @config.timeout,
|
2510
|
+
metadata: @config.metadata,
|
2511
|
+
retry_policy: @config.retry_policy
|
2512
|
+
|
2513
|
+
@vm_migration_stub.get_cutover_job request, options do |result, operation|
|
2514
|
+
yield result, operation if block_given?
|
2515
|
+
return result
|
2516
|
+
end
|
2517
|
+
rescue ::Gapic::Rest::Error => e
|
2518
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2519
|
+
end
|
2520
|
+
|
2521
|
+
##
|
2522
|
+
# Lists Groups in a given project and location.
|
2523
|
+
#
|
2524
|
+
# @overload list_groups(request, options = nil)
|
2525
|
+
# Pass arguments to `list_groups` via a request object, either of type
|
2526
|
+
# {::Google::Cloud::VMMigration::V1::ListGroupsRequest} or an equivalent Hash.
|
2527
|
+
#
|
2528
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListGroupsRequest, ::Hash]
|
2529
|
+
# A request object representing the call parameters. Required. To specify no
|
2530
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2531
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2532
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2533
|
+
#
|
2534
|
+
# @overload list_groups(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
2535
|
+
# Pass arguments to `list_groups` via keyword arguments. Note that at
|
2536
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2537
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2538
|
+
#
|
2539
|
+
# @param parent [::String]
|
2540
|
+
# Required. The parent, which owns this collection of groups.
|
2541
|
+
# @param page_size [::Integer]
|
2542
|
+
# Optional. The maximum number of groups to return. The service may return
|
2543
|
+
# fewer than this value. If unspecified, at most 500 groups will be
|
2544
|
+
# returned. The maximum value is 1000; values above 1000 will be coerced to
|
2545
|
+
# 1000.
|
2546
|
+
# @param page_token [::String]
|
2547
|
+
# Required. A page token, received from a previous `ListGroups` call.
|
2548
|
+
# Provide this to retrieve the subsequent page.
|
2549
|
+
#
|
2550
|
+
# When paginating, all other parameters provided to `ListGroups` must
|
2551
|
+
# match the call that provided the page token.
|
2552
|
+
# @param filter [::String]
|
2553
|
+
# Optional. The filter request.
|
2554
|
+
# @param order_by [::String]
|
2555
|
+
# Optional. the order by fields for the result.
|
2556
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2557
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListGroupsResponse]
|
2558
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2559
|
+
#
|
2560
|
+
# @return [::Google::Cloud::VMMigration::V1::ListGroupsResponse]
|
2561
|
+
#
|
2562
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2563
|
+
def list_groups request, options = nil
|
2564
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2565
|
+
|
2566
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListGroupsRequest
|
2567
|
+
|
2568
|
+
# Converts hash and nil to an options object
|
2569
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2570
|
+
|
2571
|
+
# Customize the options with defaults
|
2572
|
+
call_metadata = @config.rpcs.list_groups.metadata.to_h
|
2573
|
+
|
2574
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2575
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2576
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2577
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2578
|
+
transports_version_send: [:rest]
|
2579
|
+
|
2580
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2581
|
+
|
2582
|
+
options.apply_defaults timeout: @config.rpcs.list_groups.timeout,
|
2583
|
+
metadata: call_metadata,
|
2584
|
+
retry_policy: @config.rpcs.list_groups.retry_policy
|
2585
|
+
|
2586
|
+
options.apply_defaults timeout: @config.timeout,
|
2587
|
+
metadata: @config.metadata,
|
2588
|
+
retry_policy: @config.retry_policy
|
2589
|
+
|
2590
|
+
@vm_migration_stub.list_groups request, options do |result, operation|
|
2591
|
+
yield result, operation if block_given?
|
2592
|
+
return result
|
2593
|
+
end
|
2594
|
+
rescue ::Gapic::Rest::Error => e
|
2595
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2596
|
+
end
|
2597
|
+
|
2598
|
+
##
|
2599
|
+
# Gets details of a single Group.
|
2600
|
+
#
|
2601
|
+
# @overload get_group(request, options = nil)
|
2602
|
+
# Pass arguments to `get_group` via a request object, either of type
|
2603
|
+
# {::Google::Cloud::VMMigration::V1::GetGroupRequest} or an equivalent Hash.
|
2604
|
+
#
|
2605
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetGroupRequest, ::Hash]
|
2606
|
+
# A request object representing the call parameters. Required. To specify no
|
2607
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2608
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2609
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2610
|
+
#
|
2611
|
+
# @overload get_group(name: nil)
|
2612
|
+
# Pass arguments to `get_group` via keyword arguments. Note that at
|
2613
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2614
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2615
|
+
#
|
2616
|
+
# @param name [::String]
|
2617
|
+
# Required. The group name.
|
2618
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2619
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::Group]
|
2620
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2621
|
+
#
|
2622
|
+
# @return [::Google::Cloud::VMMigration::V1::Group]
|
2623
|
+
#
|
2624
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2625
|
+
def get_group request, options = nil
|
2626
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2627
|
+
|
2628
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetGroupRequest
|
2629
|
+
|
2630
|
+
# Converts hash and nil to an options object
|
2631
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2632
|
+
|
2633
|
+
# Customize the options with defaults
|
2634
|
+
call_metadata = @config.rpcs.get_group.metadata.to_h
|
2635
|
+
|
2636
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2637
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2638
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2639
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2640
|
+
transports_version_send: [:rest]
|
2641
|
+
|
2642
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2643
|
+
|
2644
|
+
options.apply_defaults timeout: @config.rpcs.get_group.timeout,
|
2645
|
+
metadata: call_metadata,
|
2646
|
+
retry_policy: @config.rpcs.get_group.retry_policy
|
2647
|
+
|
2648
|
+
options.apply_defaults timeout: @config.timeout,
|
2649
|
+
metadata: @config.metadata,
|
2650
|
+
retry_policy: @config.retry_policy
|
2651
|
+
|
2652
|
+
@vm_migration_stub.get_group request, options do |result, operation|
|
2653
|
+
yield result, operation if block_given?
|
2654
|
+
return result
|
2655
|
+
end
|
2656
|
+
rescue ::Gapic::Rest::Error => e
|
2657
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2658
|
+
end
|
2659
|
+
|
2660
|
+
##
|
2661
|
+
# Creates a new Group in a given project and location.
|
2662
|
+
#
|
2663
|
+
# @overload create_group(request, options = nil)
|
2664
|
+
# Pass arguments to `create_group` via a request object, either of type
|
2665
|
+
# {::Google::Cloud::VMMigration::V1::CreateGroupRequest} or an equivalent Hash.
|
2666
|
+
#
|
2667
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateGroupRequest, ::Hash]
|
2668
|
+
# A request object representing the call parameters. Required. To specify no
|
2669
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2670
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2671
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2672
|
+
#
|
2673
|
+
# @overload create_group(parent: nil, group_id: nil, group: nil, request_id: nil)
|
2674
|
+
# Pass arguments to `create_group` via keyword arguments. Note that at
|
2675
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2676
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2677
|
+
#
|
2678
|
+
# @param parent [::String]
|
2679
|
+
# Required. The Group's parent.
|
2680
|
+
# @param group_id [::String]
|
2681
|
+
# Required. The group identifier.
|
2682
|
+
# @param group [::Google::Cloud::VMMigration::V1::Group, ::Hash]
|
2683
|
+
# Required. The create request body.
|
2684
|
+
# @param request_id [::String]
|
2685
|
+
# A request ID to identify requests. Specify a unique request ID
|
2686
|
+
# so that if you must retry your request, the server will know to ignore
|
2687
|
+
# the request if it has already been completed. The server will guarantee
|
2688
|
+
# that for at least 60 minutes since the first request.
|
2689
|
+
#
|
2690
|
+
# For example, consider a situation where you make an initial request and t
|
2691
|
+
# he request times out. If you make the request again with the same request
|
2692
|
+
# ID, the server can check if original operation with the same request ID
|
2693
|
+
# was received, and if so, will ignore the second request. This prevents
|
2694
|
+
# clients from accidentally creating duplicate commitments.
|
2695
|
+
#
|
2696
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
2697
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
2698
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2699
|
+
# @yieldparam result [::Gapic::Operation]
|
2700
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2701
|
+
#
|
2702
|
+
# @return [::Gapic::Operation]
|
2703
|
+
#
|
2704
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2705
|
+
def create_group request, options = nil
|
2706
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2707
|
+
|
2708
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateGroupRequest
|
2709
|
+
|
2710
|
+
# Converts hash and nil to an options object
|
2711
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2712
|
+
|
2713
|
+
# Customize the options with defaults
|
2714
|
+
call_metadata = @config.rpcs.create_group.metadata.to_h
|
2715
|
+
|
2716
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2717
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2718
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2719
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2720
|
+
transports_version_send: [:rest]
|
2721
|
+
|
2722
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2723
|
+
|
2724
|
+
options.apply_defaults timeout: @config.rpcs.create_group.timeout,
|
2725
|
+
metadata: call_metadata,
|
2726
|
+
retry_policy: @config.rpcs.create_group.retry_policy
|
2727
|
+
|
2728
|
+
options.apply_defaults timeout: @config.timeout,
|
2729
|
+
metadata: @config.metadata,
|
2730
|
+
retry_policy: @config.retry_policy
|
2731
|
+
|
2732
|
+
@vm_migration_stub.create_group request, options do |result, operation|
|
2733
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2734
|
+
yield result, operation if block_given?
|
2735
|
+
return result
|
2736
|
+
end
|
2737
|
+
rescue ::Gapic::Rest::Error => e
|
2738
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2739
|
+
end
|
2740
|
+
|
2741
|
+
##
|
2742
|
+
# Updates the parameters of a single Group.
|
2743
|
+
#
|
2744
|
+
# @overload update_group(request, options = nil)
|
2745
|
+
# Pass arguments to `update_group` via a request object, either of type
|
2746
|
+
# {::Google::Cloud::VMMigration::V1::UpdateGroupRequest} or an equivalent Hash.
|
2747
|
+
#
|
2748
|
+
# @param request [::Google::Cloud::VMMigration::V1::UpdateGroupRequest, ::Hash]
|
2749
|
+
# A request object representing the call parameters. Required. To specify no
|
2750
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2751
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2752
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2753
|
+
#
|
2754
|
+
# @overload update_group(update_mask: nil, group: nil, request_id: nil)
|
2755
|
+
# Pass arguments to `update_group` via keyword arguments. Note that at
|
2756
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2757
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2758
|
+
#
|
2759
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
2760
|
+
# Field mask is used to specify the fields to be overwritten in the
|
2761
|
+
# Group resource by the update.
|
2762
|
+
# The fields specified in the update_mask are relative to the resource, not
|
2763
|
+
# the full request. A field will be overwritten if it is in the mask. If the
|
2764
|
+
# user does not provide a mask then all fields will be overwritten.
|
2765
|
+
# @param group [::Google::Cloud::VMMigration::V1::Group, ::Hash]
|
2766
|
+
# Required. The update request body.
|
2767
|
+
# @param request_id [::String]
|
2768
|
+
# A request ID to identify requests. Specify a unique request ID
|
2769
|
+
# so that if you must retry your request, the server will know to ignore
|
2770
|
+
# the request if it has already been completed. The server will guarantee
|
2771
|
+
# that for at least 60 minutes since the first request.
|
2772
|
+
#
|
2773
|
+
# For example, consider a situation where you make an initial request and t
|
2774
|
+
# he request times out. If you make the request again with the same request
|
2775
|
+
# ID, the server can check if original operation with the same request ID
|
2776
|
+
# was received, and if so, will ignore the second request. This prevents
|
2777
|
+
# clients from accidentally creating duplicate commitments.
|
2778
|
+
#
|
2779
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
2780
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
2781
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2782
|
+
# @yieldparam result [::Gapic::Operation]
|
2783
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2784
|
+
#
|
2785
|
+
# @return [::Gapic::Operation]
|
2786
|
+
#
|
2787
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2788
|
+
def update_group request, options = nil
|
2789
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2790
|
+
|
2791
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::UpdateGroupRequest
|
2792
|
+
|
2793
|
+
# Converts hash and nil to an options object
|
2794
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2795
|
+
|
2796
|
+
# Customize the options with defaults
|
2797
|
+
call_metadata = @config.rpcs.update_group.metadata.to_h
|
2798
|
+
|
2799
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2800
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2801
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2802
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2803
|
+
transports_version_send: [:rest]
|
2804
|
+
|
2805
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2806
|
+
|
2807
|
+
options.apply_defaults timeout: @config.rpcs.update_group.timeout,
|
2808
|
+
metadata: call_metadata,
|
2809
|
+
retry_policy: @config.rpcs.update_group.retry_policy
|
2810
|
+
|
2811
|
+
options.apply_defaults timeout: @config.timeout,
|
2812
|
+
metadata: @config.metadata,
|
2813
|
+
retry_policy: @config.retry_policy
|
2814
|
+
|
2815
|
+
@vm_migration_stub.update_group request, options do |result, operation|
|
2816
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2817
|
+
yield result, operation if block_given?
|
2818
|
+
return result
|
2819
|
+
end
|
2820
|
+
rescue ::Gapic::Rest::Error => e
|
2821
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2822
|
+
end
|
2823
|
+
|
2824
|
+
##
|
2825
|
+
# Deletes a single Group.
|
2826
|
+
#
|
2827
|
+
# @overload delete_group(request, options = nil)
|
2828
|
+
# Pass arguments to `delete_group` via a request object, either of type
|
2829
|
+
# {::Google::Cloud::VMMigration::V1::DeleteGroupRequest} or an equivalent Hash.
|
2830
|
+
#
|
2831
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteGroupRequest, ::Hash]
|
2832
|
+
# A request object representing the call parameters. Required. To specify no
|
2833
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2834
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2835
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2836
|
+
#
|
2837
|
+
# @overload delete_group(name: nil, request_id: nil)
|
2838
|
+
# Pass arguments to `delete_group` via keyword arguments. Note that at
|
2839
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2840
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2841
|
+
#
|
2842
|
+
# @param name [::String]
|
2843
|
+
# Required. The Group name.
|
2844
|
+
# @param request_id [::String]
|
2845
|
+
# Optional. A request ID to identify requests. Specify a unique request ID
|
2846
|
+
# so that if you must retry your request, the server will know to ignore
|
2847
|
+
# the request if it has already been completed. The server will guarantee
|
2848
|
+
# that for at least 60 minutes after the first request.
|
2849
|
+
#
|
2850
|
+
# For example, consider a situation where you make an initial request and t
|
2851
|
+
# he request times out. If you make the request again with the same request
|
2852
|
+
# ID, the server can check if original operation with the same request ID
|
2853
|
+
# was received, and if so, will ignore the second request. This prevents
|
2854
|
+
# clients from accidentally creating duplicate commitments.
|
2855
|
+
#
|
2856
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
2857
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
2858
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2859
|
+
# @yieldparam result [::Gapic::Operation]
|
2860
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2861
|
+
#
|
2862
|
+
# @return [::Gapic::Operation]
|
2863
|
+
#
|
2864
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2865
|
+
def delete_group request, options = nil
|
2866
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2867
|
+
|
2868
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteGroupRequest
|
2869
|
+
|
2870
|
+
# Converts hash and nil to an options object
|
2871
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2872
|
+
|
2873
|
+
# Customize the options with defaults
|
2874
|
+
call_metadata = @config.rpcs.delete_group.metadata.to_h
|
2875
|
+
|
2876
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2877
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2878
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2879
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2880
|
+
transports_version_send: [:rest]
|
2881
|
+
|
2882
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2883
|
+
|
2884
|
+
options.apply_defaults timeout: @config.rpcs.delete_group.timeout,
|
2885
|
+
metadata: call_metadata,
|
2886
|
+
retry_policy: @config.rpcs.delete_group.retry_policy
|
2887
|
+
|
2888
|
+
options.apply_defaults timeout: @config.timeout,
|
2889
|
+
metadata: @config.metadata,
|
2890
|
+
retry_policy: @config.retry_policy
|
2891
|
+
|
2892
|
+
@vm_migration_stub.delete_group request, options do |result, operation|
|
2893
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2894
|
+
yield result, operation if block_given?
|
2895
|
+
return result
|
2896
|
+
end
|
2897
|
+
rescue ::Gapic::Rest::Error => e
|
2898
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2899
|
+
end
|
2900
|
+
|
2901
|
+
##
|
2902
|
+
# Adds a MigratingVm to a Group.
|
2903
|
+
#
|
2904
|
+
# @overload add_group_migration(request, options = nil)
|
2905
|
+
# Pass arguments to `add_group_migration` via a request object, either of type
|
2906
|
+
# {::Google::Cloud::VMMigration::V1::AddGroupMigrationRequest} or an equivalent Hash.
|
2907
|
+
#
|
2908
|
+
# @param request [::Google::Cloud::VMMigration::V1::AddGroupMigrationRequest, ::Hash]
|
2909
|
+
# A request object representing the call parameters. Required. To specify no
|
2910
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2911
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2912
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2913
|
+
#
|
2914
|
+
# @overload add_group_migration(group: nil, migrating_vm: nil)
|
2915
|
+
# Pass arguments to `add_group_migration` via keyword arguments. Note that at
|
2916
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2917
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2918
|
+
#
|
2919
|
+
# @param group [::String]
|
2920
|
+
# Required. The full path name of the Group to add to.
|
2921
|
+
# @param migrating_vm [::String]
|
2922
|
+
# The full path name of the MigratingVm to add.
|
2923
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2924
|
+
# @yieldparam result [::Gapic::Operation]
|
2925
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2926
|
+
#
|
2927
|
+
# @return [::Gapic::Operation]
|
2928
|
+
#
|
2929
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2930
|
+
def add_group_migration request, options = nil
|
2931
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2932
|
+
|
2933
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::AddGroupMigrationRequest
|
2934
|
+
|
2935
|
+
# Converts hash and nil to an options object
|
2936
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2937
|
+
|
2938
|
+
# Customize the options with defaults
|
2939
|
+
call_metadata = @config.rpcs.add_group_migration.metadata.to_h
|
2940
|
+
|
2941
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
2942
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2943
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2944
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
2945
|
+
transports_version_send: [:rest]
|
2946
|
+
|
2947
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2948
|
+
|
2949
|
+
options.apply_defaults timeout: @config.rpcs.add_group_migration.timeout,
|
2950
|
+
metadata: call_metadata,
|
2951
|
+
retry_policy: @config.rpcs.add_group_migration.retry_policy
|
2952
|
+
|
2953
|
+
options.apply_defaults timeout: @config.timeout,
|
2954
|
+
metadata: @config.metadata,
|
2955
|
+
retry_policy: @config.retry_policy
|
2956
|
+
|
2957
|
+
@vm_migration_stub.add_group_migration request, options do |result, operation|
|
2958
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
2959
|
+
yield result, operation if block_given?
|
2960
|
+
return result
|
2961
|
+
end
|
2962
|
+
rescue ::Gapic::Rest::Error => e
|
2963
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2964
|
+
end
|
2965
|
+
|
2966
|
+
##
|
2967
|
+
# Removes a MigratingVm from a Group.
|
2968
|
+
#
|
2969
|
+
# @overload remove_group_migration(request, options = nil)
|
2970
|
+
# Pass arguments to `remove_group_migration` via a request object, either of type
|
2971
|
+
# {::Google::Cloud::VMMigration::V1::RemoveGroupMigrationRequest} or an equivalent Hash.
|
2972
|
+
#
|
2973
|
+
# @param request [::Google::Cloud::VMMigration::V1::RemoveGroupMigrationRequest, ::Hash]
|
2974
|
+
# A request object representing the call parameters. Required. To specify no
|
2975
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2976
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2977
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2978
|
+
#
|
2979
|
+
# @overload remove_group_migration(group: nil, migrating_vm: nil)
|
2980
|
+
# Pass arguments to `remove_group_migration` via keyword arguments. Note that at
|
2981
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2982
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2983
|
+
#
|
2984
|
+
# @param group [::String]
|
2985
|
+
# Required. The name of the Group.
|
2986
|
+
# @param migrating_vm [::String]
|
2987
|
+
# The MigratingVm to remove.
|
2988
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2989
|
+
# @yieldparam result [::Gapic::Operation]
|
2990
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2991
|
+
#
|
2992
|
+
# @return [::Gapic::Operation]
|
2993
|
+
#
|
2994
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2995
|
+
def remove_group_migration request, options = nil
|
2996
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2997
|
+
|
2998
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::RemoveGroupMigrationRequest
|
2999
|
+
|
3000
|
+
# Converts hash and nil to an options object
|
3001
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3002
|
+
|
3003
|
+
# Customize the options with defaults
|
3004
|
+
call_metadata = @config.rpcs.remove_group_migration.metadata.to_h
|
3005
|
+
|
3006
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3007
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3008
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3009
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3010
|
+
transports_version_send: [:rest]
|
3011
|
+
|
3012
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3013
|
+
|
3014
|
+
options.apply_defaults timeout: @config.rpcs.remove_group_migration.timeout,
|
3015
|
+
metadata: call_metadata,
|
3016
|
+
retry_policy: @config.rpcs.remove_group_migration.retry_policy
|
3017
|
+
|
3018
|
+
options.apply_defaults timeout: @config.timeout,
|
3019
|
+
metadata: @config.metadata,
|
3020
|
+
retry_policy: @config.retry_policy
|
3021
|
+
|
3022
|
+
@vm_migration_stub.remove_group_migration request, options do |result, operation|
|
3023
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
3024
|
+
yield result, operation if block_given?
|
3025
|
+
return result
|
3026
|
+
end
|
3027
|
+
rescue ::Gapic::Rest::Error => e
|
3028
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3029
|
+
end
|
3030
|
+
|
3031
|
+
##
|
3032
|
+
# Lists TargetProjects in a given project.
|
3033
|
+
#
|
3034
|
+
# NOTE: TargetProject is a global resource; hence the only supported value
|
3035
|
+
# for location is `global`.
|
3036
|
+
#
|
3037
|
+
# @overload list_target_projects(request, options = nil)
|
3038
|
+
# Pass arguments to `list_target_projects` via a request object, either of type
|
3039
|
+
# {::Google::Cloud::VMMigration::V1::ListTargetProjectsRequest} or an equivalent Hash.
|
3040
|
+
#
|
3041
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListTargetProjectsRequest, ::Hash]
|
3042
|
+
# A request object representing the call parameters. Required. To specify no
|
3043
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3044
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3045
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3046
|
+
#
|
3047
|
+
# @overload list_target_projects(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
3048
|
+
# Pass arguments to `list_target_projects` via keyword arguments. Note that at
|
3049
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3050
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3051
|
+
#
|
3052
|
+
# @param parent [::String]
|
3053
|
+
# Required. The parent, which owns this collection of targets.
|
3054
|
+
# @param page_size [::Integer]
|
3055
|
+
# Optional. The maximum number of targets to return. The service may return
|
3056
|
+
# fewer than this value. If unspecified, at most 500 targets will be
|
3057
|
+
# returned. The maximum value is 1000; values above 1000 will be coerced to
|
3058
|
+
# 1000.
|
3059
|
+
# @param page_token [::String]
|
3060
|
+
# Required. A page token, received from a previous `ListTargets` call.
|
3061
|
+
# Provide this to retrieve the subsequent page.
|
3062
|
+
#
|
3063
|
+
# When paginating, all other parameters provided to `ListTargets` must
|
3064
|
+
# match the call that provided the page token.
|
3065
|
+
# @param filter [::String]
|
3066
|
+
# Optional. The filter request.
|
3067
|
+
# @param order_by [::String]
|
3068
|
+
# Optional. the order by fields for the result.
|
3069
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3070
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListTargetProjectsResponse]
|
3071
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3072
|
+
#
|
3073
|
+
# @return [::Google::Cloud::VMMigration::V1::ListTargetProjectsResponse]
|
3074
|
+
#
|
3075
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3076
|
+
def list_target_projects request, options = nil
|
3077
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3078
|
+
|
3079
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListTargetProjectsRequest
|
3080
|
+
|
3081
|
+
# Converts hash and nil to an options object
|
3082
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3083
|
+
|
3084
|
+
# Customize the options with defaults
|
3085
|
+
call_metadata = @config.rpcs.list_target_projects.metadata.to_h
|
3086
|
+
|
3087
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3088
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3089
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3090
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3091
|
+
transports_version_send: [:rest]
|
3092
|
+
|
3093
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3094
|
+
|
3095
|
+
options.apply_defaults timeout: @config.rpcs.list_target_projects.timeout,
|
3096
|
+
metadata: call_metadata,
|
3097
|
+
retry_policy: @config.rpcs.list_target_projects.retry_policy
|
3098
|
+
|
3099
|
+
options.apply_defaults timeout: @config.timeout,
|
3100
|
+
metadata: @config.metadata,
|
3101
|
+
retry_policy: @config.retry_policy
|
3102
|
+
|
3103
|
+
@vm_migration_stub.list_target_projects request, options do |result, operation|
|
3104
|
+
yield result, operation if block_given?
|
3105
|
+
return result
|
3106
|
+
end
|
3107
|
+
rescue ::Gapic::Rest::Error => e
|
3108
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3109
|
+
end
|
3110
|
+
|
3111
|
+
##
|
3112
|
+
# Gets details of a single TargetProject.
|
3113
|
+
#
|
3114
|
+
# NOTE: TargetProject is a global resource; hence the only supported value
|
3115
|
+
# for location is `global`.
|
3116
|
+
#
|
3117
|
+
# @overload get_target_project(request, options = nil)
|
3118
|
+
# Pass arguments to `get_target_project` via a request object, either of type
|
3119
|
+
# {::Google::Cloud::VMMigration::V1::GetTargetProjectRequest} or an equivalent Hash.
|
3120
|
+
#
|
3121
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetTargetProjectRequest, ::Hash]
|
3122
|
+
# A request object representing the call parameters. Required. To specify no
|
3123
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3124
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3125
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3126
|
+
#
|
3127
|
+
# @overload get_target_project(name: nil)
|
3128
|
+
# Pass arguments to `get_target_project` via keyword arguments. Note that at
|
3129
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3130
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3131
|
+
#
|
3132
|
+
# @param name [::String]
|
3133
|
+
# Required. The TargetProject name.
|
3134
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3135
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::TargetProject]
|
3136
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3137
|
+
#
|
3138
|
+
# @return [::Google::Cloud::VMMigration::V1::TargetProject]
|
3139
|
+
#
|
3140
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3141
|
+
def get_target_project request, options = nil
|
3142
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3143
|
+
|
3144
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetTargetProjectRequest
|
3145
|
+
|
3146
|
+
# Converts hash and nil to an options object
|
3147
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3148
|
+
|
3149
|
+
# Customize the options with defaults
|
3150
|
+
call_metadata = @config.rpcs.get_target_project.metadata.to_h
|
3151
|
+
|
3152
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3153
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3154
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3155
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3156
|
+
transports_version_send: [:rest]
|
3157
|
+
|
3158
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3159
|
+
|
3160
|
+
options.apply_defaults timeout: @config.rpcs.get_target_project.timeout,
|
3161
|
+
metadata: call_metadata,
|
3162
|
+
retry_policy: @config.rpcs.get_target_project.retry_policy
|
3163
|
+
|
3164
|
+
options.apply_defaults timeout: @config.timeout,
|
3165
|
+
metadata: @config.metadata,
|
3166
|
+
retry_policy: @config.retry_policy
|
3167
|
+
|
3168
|
+
@vm_migration_stub.get_target_project request, options do |result, operation|
|
3169
|
+
yield result, operation if block_given?
|
3170
|
+
return result
|
3171
|
+
end
|
3172
|
+
rescue ::Gapic::Rest::Error => e
|
3173
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3174
|
+
end
|
3175
|
+
|
3176
|
+
##
|
3177
|
+
# Creates a new TargetProject in a given project.
|
3178
|
+
#
|
3179
|
+
# NOTE: TargetProject is a global resource; hence the only supported value
|
3180
|
+
# for location is `global`.
|
3181
|
+
#
|
3182
|
+
# @overload create_target_project(request, options = nil)
|
3183
|
+
# Pass arguments to `create_target_project` via a request object, either of type
|
3184
|
+
# {::Google::Cloud::VMMigration::V1::CreateTargetProjectRequest} or an equivalent Hash.
|
3185
|
+
#
|
3186
|
+
# @param request [::Google::Cloud::VMMigration::V1::CreateTargetProjectRequest, ::Hash]
|
3187
|
+
# A request object representing the call parameters. Required. To specify no
|
3188
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3189
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3190
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3191
|
+
#
|
3192
|
+
# @overload create_target_project(parent: nil, target_project_id: nil, target_project: nil, request_id: nil)
|
3193
|
+
# Pass arguments to `create_target_project` via keyword arguments. Note that at
|
3194
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3195
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3196
|
+
#
|
3197
|
+
# @param parent [::String]
|
3198
|
+
# Required. The TargetProject's parent.
|
3199
|
+
# @param target_project_id [::String]
|
3200
|
+
# Required. The target_project identifier.
|
3201
|
+
# @param target_project [::Google::Cloud::VMMigration::V1::TargetProject, ::Hash]
|
3202
|
+
# Required. The create request body.
|
3203
|
+
# @param request_id [::String]
|
3204
|
+
# A request ID to identify requests. Specify a unique request ID
|
3205
|
+
# so that if you must retry your request, the server will know to ignore
|
3206
|
+
# the request if it has already been completed. The server will guarantee
|
3207
|
+
# that for at least 60 minutes since the first request.
|
3208
|
+
#
|
3209
|
+
# For example, consider a situation where you make an initial request and t
|
3210
|
+
# he request times out. If you make the request again with the same request
|
3211
|
+
# ID, the server can check if original operation with the same request ID
|
3212
|
+
# was received, and if so, will ignore the second request. This prevents
|
3213
|
+
# clients from accidentally creating duplicate commitments.
|
3214
|
+
#
|
3215
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
3216
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
3217
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3218
|
+
# @yieldparam result [::Gapic::Operation]
|
3219
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3220
|
+
#
|
3221
|
+
# @return [::Gapic::Operation]
|
3222
|
+
#
|
3223
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3224
|
+
def create_target_project request, options = nil
|
3225
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3226
|
+
|
3227
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::CreateTargetProjectRequest
|
3228
|
+
|
3229
|
+
# Converts hash and nil to an options object
|
3230
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3231
|
+
|
3232
|
+
# Customize the options with defaults
|
3233
|
+
call_metadata = @config.rpcs.create_target_project.metadata.to_h
|
3234
|
+
|
3235
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3236
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3237
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3238
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3239
|
+
transports_version_send: [:rest]
|
3240
|
+
|
3241
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3242
|
+
|
3243
|
+
options.apply_defaults timeout: @config.rpcs.create_target_project.timeout,
|
3244
|
+
metadata: call_metadata,
|
3245
|
+
retry_policy: @config.rpcs.create_target_project.retry_policy
|
3246
|
+
|
3247
|
+
options.apply_defaults timeout: @config.timeout,
|
3248
|
+
metadata: @config.metadata,
|
3249
|
+
retry_policy: @config.retry_policy
|
3250
|
+
|
3251
|
+
@vm_migration_stub.create_target_project request, options do |result, operation|
|
3252
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
3253
|
+
yield result, operation if block_given?
|
3254
|
+
return result
|
3255
|
+
end
|
3256
|
+
rescue ::Gapic::Rest::Error => e
|
3257
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3258
|
+
end
|
3259
|
+
|
3260
|
+
##
|
3261
|
+
# Updates the parameters of a single TargetProject.
|
3262
|
+
#
|
3263
|
+
# NOTE: TargetProject is a global resource; hence the only supported value
|
3264
|
+
# for location is `global`.
|
3265
|
+
#
|
3266
|
+
# @overload update_target_project(request, options = nil)
|
3267
|
+
# Pass arguments to `update_target_project` via a request object, either of type
|
3268
|
+
# {::Google::Cloud::VMMigration::V1::UpdateTargetProjectRequest} or an equivalent Hash.
|
3269
|
+
#
|
3270
|
+
# @param request [::Google::Cloud::VMMigration::V1::UpdateTargetProjectRequest, ::Hash]
|
3271
|
+
# A request object representing the call parameters. Required. To specify no
|
3272
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3273
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3274
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3275
|
+
#
|
3276
|
+
# @overload update_target_project(update_mask: nil, target_project: nil, request_id: nil)
|
3277
|
+
# Pass arguments to `update_target_project` via keyword arguments. Note that at
|
3278
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3279
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3280
|
+
#
|
3281
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
3282
|
+
# Field mask is used to specify the fields to be overwritten in the
|
3283
|
+
# TargetProject resource by the update.
|
3284
|
+
# The fields specified in the update_mask are relative to the resource, not
|
3285
|
+
# the full request. A field will be overwritten if it is in the mask. If the
|
3286
|
+
# user does not provide a mask then all fields will be overwritten.
|
3287
|
+
# @param target_project [::Google::Cloud::VMMigration::V1::TargetProject, ::Hash]
|
3288
|
+
# Required. The update request body.
|
3289
|
+
# @param request_id [::String]
|
3290
|
+
# A request ID to identify requests. Specify a unique request ID
|
3291
|
+
# so that if you must retry your request, the server will know to ignore
|
3292
|
+
# the request if it has already been completed. The server will guarantee
|
3293
|
+
# that for at least 60 minutes since the first request.
|
3294
|
+
#
|
3295
|
+
# For example, consider a situation where you make an initial request and t
|
3296
|
+
# he request times out. If you make the request again with the same request
|
3297
|
+
# ID, the server can check if original operation with the same request ID
|
3298
|
+
# was received, and if so, will ignore the second request. This prevents
|
3299
|
+
# clients from accidentally creating duplicate commitments.
|
3300
|
+
#
|
3301
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
3302
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
3303
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3304
|
+
# @yieldparam result [::Gapic::Operation]
|
3305
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3306
|
+
#
|
3307
|
+
# @return [::Gapic::Operation]
|
3308
|
+
#
|
3309
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3310
|
+
def update_target_project request, options = nil
|
3311
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3312
|
+
|
3313
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::UpdateTargetProjectRequest
|
3314
|
+
|
3315
|
+
# Converts hash and nil to an options object
|
3316
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3317
|
+
|
3318
|
+
# Customize the options with defaults
|
3319
|
+
call_metadata = @config.rpcs.update_target_project.metadata.to_h
|
3320
|
+
|
3321
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3322
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3323
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3324
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3325
|
+
transports_version_send: [:rest]
|
3326
|
+
|
3327
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3328
|
+
|
3329
|
+
options.apply_defaults timeout: @config.rpcs.update_target_project.timeout,
|
3330
|
+
metadata: call_metadata,
|
3331
|
+
retry_policy: @config.rpcs.update_target_project.retry_policy
|
3332
|
+
|
3333
|
+
options.apply_defaults timeout: @config.timeout,
|
3334
|
+
metadata: @config.metadata,
|
3335
|
+
retry_policy: @config.retry_policy
|
3336
|
+
|
3337
|
+
@vm_migration_stub.update_target_project request, options do |result, operation|
|
3338
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
3339
|
+
yield result, operation if block_given?
|
3340
|
+
return result
|
3341
|
+
end
|
3342
|
+
rescue ::Gapic::Rest::Error => e
|
3343
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3344
|
+
end
|
3345
|
+
|
3346
|
+
##
|
3347
|
+
# Deletes a single TargetProject.
|
3348
|
+
#
|
3349
|
+
# NOTE: TargetProject is a global resource; hence the only supported value
|
3350
|
+
# for location is `global`.
|
3351
|
+
#
|
3352
|
+
# @overload delete_target_project(request, options = nil)
|
3353
|
+
# Pass arguments to `delete_target_project` via a request object, either of type
|
3354
|
+
# {::Google::Cloud::VMMigration::V1::DeleteTargetProjectRequest} or an equivalent Hash.
|
3355
|
+
#
|
3356
|
+
# @param request [::Google::Cloud::VMMigration::V1::DeleteTargetProjectRequest, ::Hash]
|
3357
|
+
# A request object representing the call parameters. Required. To specify no
|
3358
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3359
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3360
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3361
|
+
#
|
3362
|
+
# @overload delete_target_project(name: nil, request_id: nil)
|
3363
|
+
# Pass arguments to `delete_target_project` via keyword arguments. Note that at
|
3364
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3365
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3366
|
+
#
|
3367
|
+
# @param name [::String]
|
3368
|
+
# Required. The TargetProject name.
|
3369
|
+
# @param request_id [::String]
|
3370
|
+
# Optional. A request ID to identify requests. Specify a unique request ID
|
3371
|
+
# so that if you must retry your request, the server will know to ignore
|
3372
|
+
# the request if it has already been completed. The server will guarantee
|
3373
|
+
# that for at least 60 minutes after the first request.
|
3374
|
+
#
|
3375
|
+
# For example, consider a situation where you make an initial request and t
|
3376
|
+
# he request times out. If you make the request again with the same request
|
3377
|
+
# ID, the server can check if original operation with the same request ID
|
3378
|
+
# was received, and if so, will ignore the second request. This prevents
|
3379
|
+
# clients from accidentally creating duplicate commitments.
|
3380
|
+
#
|
3381
|
+
# The request ID must be a valid UUID with the exception that zero UUID is
|
3382
|
+
# not supported (00000000-0000-0000-0000-000000000000).
|
3383
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3384
|
+
# @yieldparam result [::Gapic::Operation]
|
3385
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3386
|
+
#
|
3387
|
+
# @return [::Gapic::Operation]
|
3388
|
+
#
|
3389
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3390
|
+
def delete_target_project request, options = nil
|
3391
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3392
|
+
|
3393
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::DeleteTargetProjectRequest
|
3394
|
+
|
3395
|
+
# Converts hash and nil to an options object
|
3396
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3397
|
+
|
3398
|
+
# Customize the options with defaults
|
3399
|
+
call_metadata = @config.rpcs.delete_target_project.metadata.to_h
|
3400
|
+
|
3401
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3402
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3403
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3404
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3405
|
+
transports_version_send: [:rest]
|
3406
|
+
|
3407
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3408
|
+
|
3409
|
+
options.apply_defaults timeout: @config.rpcs.delete_target_project.timeout,
|
3410
|
+
metadata: call_metadata,
|
3411
|
+
retry_policy: @config.rpcs.delete_target_project.retry_policy
|
3412
|
+
|
3413
|
+
options.apply_defaults timeout: @config.timeout,
|
3414
|
+
metadata: @config.metadata,
|
3415
|
+
retry_policy: @config.retry_policy
|
3416
|
+
|
3417
|
+
@vm_migration_stub.delete_target_project request, options do |result, operation|
|
3418
|
+
result = ::Gapic::Operation.new result, @operations_client, options: options
|
3419
|
+
yield result, operation if block_given?
|
3420
|
+
return result
|
3421
|
+
end
|
3422
|
+
rescue ::Gapic::Rest::Error => e
|
3423
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3424
|
+
end
|
3425
|
+
|
3426
|
+
##
|
3427
|
+
# Lists ReplicationCycles in a given MigratingVM.
|
3428
|
+
#
|
3429
|
+
# @overload list_replication_cycles(request, options = nil)
|
3430
|
+
# Pass arguments to `list_replication_cycles` via a request object, either of type
|
3431
|
+
# {::Google::Cloud::VMMigration::V1::ListReplicationCyclesRequest} or an equivalent Hash.
|
3432
|
+
#
|
3433
|
+
# @param request [::Google::Cloud::VMMigration::V1::ListReplicationCyclesRequest, ::Hash]
|
3434
|
+
# A request object representing the call parameters. Required. To specify no
|
3435
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3436
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3437
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3438
|
+
#
|
3439
|
+
# @overload list_replication_cycles(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
|
3440
|
+
# Pass arguments to `list_replication_cycles` via keyword arguments. Note that at
|
3441
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3442
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3443
|
+
#
|
3444
|
+
# @param parent [::String]
|
3445
|
+
# Required. The parent, which owns this collection of ReplicationCycles.
|
3446
|
+
# @param page_size [::Integer]
|
3447
|
+
# Optional. The maximum number of replication cycles to return. The service
|
3448
|
+
# may return fewer than this value. If unspecified, at most 100 migrating VMs
|
3449
|
+
# will be returned. The maximum value is 100; values above 100 will be
|
3450
|
+
# coerced to 100.
|
3451
|
+
# @param page_token [::String]
|
3452
|
+
# Required. A page token, received from a previous `ListReplicationCycles`
|
3453
|
+
# call. Provide this to retrieve the subsequent page.
|
3454
|
+
#
|
3455
|
+
# When paginating, all other parameters provided to `ListReplicationCycles`
|
3456
|
+
# must match the call that provided the page token.
|
3457
|
+
# @param filter [::String]
|
3458
|
+
# Optional. The filter request.
|
3459
|
+
# @param order_by [::String]
|
3460
|
+
# Optional. the order by fields for the result.
|
3461
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3462
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ListReplicationCyclesResponse]
|
3463
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3464
|
+
#
|
3465
|
+
# @return [::Google::Cloud::VMMigration::V1::ListReplicationCyclesResponse]
|
3466
|
+
#
|
3467
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3468
|
+
def list_replication_cycles request, options = nil
|
3469
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3470
|
+
|
3471
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::ListReplicationCyclesRequest
|
3472
|
+
|
3473
|
+
# Converts hash and nil to an options object
|
3474
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3475
|
+
|
3476
|
+
# Customize the options with defaults
|
3477
|
+
call_metadata = @config.rpcs.list_replication_cycles.metadata.to_h
|
3478
|
+
|
3479
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3480
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3481
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3482
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3483
|
+
transports_version_send: [:rest]
|
3484
|
+
|
3485
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3486
|
+
|
3487
|
+
options.apply_defaults timeout: @config.rpcs.list_replication_cycles.timeout,
|
3488
|
+
metadata: call_metadata,
|
3489
|
+
retry_policy: @config.rpcs.list_replication_cycles.retry_policy
|
3490
|
+
|
3491
|
+
options.apply_defaults timeout: @config.timeout,
|
3492
|
+
metadata: @config.metadata,
|
3493
|
+
retry_policy: @config.retry_policy
|
3494
|
+
|
3495
|
+
@vm_migration_stub.list_replication_cycles request, options do |result, operation|
|
3496
|
+
yield result, operation if block_given?
|
3497
|
+
return result
|
3498
|
+
end
|
3499
|
+
rescue ::Gapic::Rest::Error => e
|
3500
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3501
|
+
end
|
3502
|
+
|
3503
|
+
##
|
3504
|
+
# Gets details of a single ReplicationCycle.
|
3505
|
+
#
|
3506
|
+
# @overload get_replication_cycle(request, options = nil)
|
3507
|
+
# Pass arguments to `get_replication_cycle` via a request object, either of type
|
3508
|
+
# {::Google::Cloud::VMMigration::V1::GetReplicationCycleRequest} or an equivalent Hash.
|
3509
|
+
#
|
3510
|
+
# @param request [::Google::Cloud::VMMigration::V1::GetReplicationCycleRequest, ::Hash]
|
3511
|
+
# A request object representing the call parameters. Required. To specify no
|
3512
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3513
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3514
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3515
|
+
#
|
3516
|
+
# @overload get_replication_cycle(name: nil)
|
3517
|
+
# Pass arguments to `get_replication_cycle` via keyword arguments. Note that at
|
3518
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3519
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3520
|
+
#
|
3521
|
+
# @param name [::String]
|
3522
|
+
# Required. The name of the ReplicationCycle.
|
3523
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3524
|
+
# @yieldparam result [::Google::Cloud::VMMigration::V1::ReplicationCycle]
|
3525
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3526
|
+
#
|
3527
|
+
# @return [::Google::Cloud::VMMigration::V1::ReplicationCycle]
|
3528
|
+
#
|
3529
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3530
|
+
def get_replication_cycle request, options = nil
|
3531
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3532
|
+
|
3533
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::VMMigration::V1::GetReplicationCycleRequest
|
3534
|
+
|
3535
|
+
# Converts hash and nil to an options object
|
3536
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3537
|
+
|
3538
|
+
# Customize the options with defaults
|
3539
|
+
call_metadata = @config.rpcs.get_replication_cycle.metadata.to_h
|
3540
|
+
|
3541
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
3542
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3543
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3544
|
+
gapic_version: ::Google::Cloud::VMMigration::V1::VERSION,
|
3545
|
+
transports_version_send: [:rest]
|
3546
|
+
|
3547
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3548
|
+
|
3549
|
+
options.apply_defaults timeout: @config.rpcs.get_replication_cycle.timeout,
|
3550
|
+
metadata: call_metadata,
|
3551
|
+
retry_policy: @config.rpcs.get_replication_cycle.retry_policy
|
3552
|
+
|
3553
|
+
options.apply_defaults timeout: @config.timeout,
|
3554
|
+
metadata: @config.metadata,
|
3555
|
+
retry_policy: @config.retry_policy
|
3556
|
+
|
3557
|
+
@vm_migration_stub.get_replication_cycle request, options do |result, operation|
|
3558
|
+
yield result, operation if block_given?
|
3559
|
+
return result
|
3560
|
+
end
|
3561
|
+
rescue ::Gapic::Rest::Error => e
|
3562
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3563
|
+
end
|
3564
|
+
|
3565
|
+
##
|
3566
|
+
# Configuration class for the VmMigration REST API.
|
3567
|
+
#
|
3568
|
+
# This class represents the configuration for VmMigration REST,
|
3569
|
+
# providing control over timeouts, retry behavior, logging, transport
|
3570
|
+
# parameters, and other low-level controls. Certain parameters can also be
|
3571
|
+
# applied individually to specific RPCs. See
|
3572
|
+
# {::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client::Configuration::Rpcs}
|
3573
|
+
# for a list of RPCs that can be configured independently.
|
3574
|
+
#
|
3575
|
+
# Configuration can be applied globally to all clients, or to a single client
|
3576
|
+
# on construction.
|
3577
|
+
#
|
3578
|
+
# @example
|
3579
|
+
#
|
3580
|
+
# # Modify the global config, setting the timeout for
|
3581
|
+
# # list_sources to 20 seconds,
|
3582
|
+
# # and all remaining timeouts to 10 seconds.
|
3583
|
+
# ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client.configure do |config|
|
3584
|
+
# config.timeout = 10.0
|
3585
|
+
# config.rpcs.list_sources.timeout = 20.0
|
3586
|
+
# end
|
3587
|
+
#
|
3588
|
+
# # Apply the above configuration only to a new client.
|
3589
|
+
# client = ::Google::Cloud::VMMigration::V1::VMMigration::Rest::Client.new do |config|
|
3590
|
+
# config.timeout = 10.0
|
3591
|
+
# config.rpcs.list_sources.timeout = 20.0
|
3592
|
+
# end
|
3593
|
+
#
|
3594
|
+
# @!attribute [rw] endpoint
|
3595
|
+
# The hostname or hostname:port of the service endpoint.
|
3596
|
+
# Defaults to `"vmmigration.googleapis.com"`.
|
3597
|
+
# @return [::String]
|
3598
|
+
# @!attribute [rw] credentials
|
3599
|
+
# Credentials to send with calls. You may provide any of the following types:
|
3600
|
+
# * (`String`) The path to a service account key file in JSON format
|
3601
|
+
# * (`Hash`) A service account key as a Hash
|
3602
|
+
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
3603
|
+
# (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
|
3604
|
+
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
3605
|
+
# (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
|
3606
|
+
# * (`nil`) indicating no credentials
|
3607
|
+
# @return [::Object]
|
3608
|
+
# @!attribute [rw] scope
|
3609
|
+
# The OAuth scopes
|
3610
|
+
# @return [::Array<::String>]
|
3611
|
+
# @!attribute [rw] lib_name
|
3612
|
+
# The library name as recorded in instrumentation and logging
|
3613
|
+
# @return [::String]
|
3614
|
+
# @!attribute [rw] lib_version
|
3615
|
+
# The library version as recorded in instrumentation and logging
|
3616
|
+
# @return [::String]
|
3617
|
+
# @!attribute [rw] timeout
|
3618
|
+
# The call timeout in seconds.
|
3619
|
+
# @return [::Numeric]
|
3620
|
+
# @!attribute [rw] metadata
|
3621
|
+
# Additional headers to be sent with the call.
|
3622
|
+
# @return [::Hash{::Symbol=>::String}]
|
3623
|
+
# @!attribute [rw] retry_policy
|
3624
|
+
# The retry policy. The value is a hash with the following keys:
|
3625
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
3626
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
3627
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
3628
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
3629
|
+
# trigger a retry.
|
3630
|
+
# @return [::Hash]
|
3631
|
+
# @!attribute [rw] quota_project
|
3632
|
+
# A separate project against which to charge quota.
|
3633
|
+
# @return [::String]
|
3634
|
+
#
|
3635
|
+
class Configuration
|
3636
|
+
extend ::Gapic::Config
|
3637
|
+
|
3638
|
+
config_attr :endpoint, "vmmigration.googleapis.com", ::String
|
3639
|
+
config_attr :credentials, nil do |value|
|
3640
|
+
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
3641
|
+
allowed.any? { |klass| klass === value }
|
3642
|
+
end
|
3643
|
+
config_attr :scope, nil, ::String, ::Array, nil
|
3644
|
+
config_attr :lib_name, nil, ::String, nil
|
3645
|
+
config_attr :lib_version, nil, ::String, nil
|
3646
|
+
config_attr :timeout, nil, ::Numeric, nil
|
3647
|
+
config_attr :metadata, nil, ::Hash, nil
|
3648
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
3649
|
+
config_attr :quota_project, nil, ::String, nil
|
3650
|
+
|
3651
|
+
# @private
|
3652
|
+
# Overrides for http bindings for the RPCs of this service
|
3653
|
+
# are only used when this service is used as mixin, and only
|
3654
|
+
# by the host service.
|
3655
|
+
# @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
|
3656
|
+
config_attr :bindings_override, {}, ::Hash, nil
|
3657
|
+
|
3658
|
+
# @private
|
3659
|
+
def initialize parent_config = nil
|
3660
|
+
@parent_config = parent_config unless parent_config.nil?
|
3661
|
+
|
3662
|
+
yield self if block_given?
|
3663
|
+
end
|
3664
|
+
|
3665
|
+
##
|
3666
|
+
# Configurations for individual RPCs
|
3667
|
+
# @return [Rpcs]
|
3668
|
+
#
|
3669
|
+
def rpcs
|
3670
|
+
@rpcs ||= begin
|
3671
|
+
parent_rpcs = nil
|
3672
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
3673
|
+
Rpcs.new parent_rpcs
|
3674
|
+
end
|
3675
|
+
end
|
3676
|
+
|
3677
|
+
##
|
3678
|
+
# Configuration RPC class for the VmMigration API.
|
3679
|
+
#
|
3680
|
+
# Includes fields providing the configuration for each RPC in this service.
|
3681
|
+
# Each configuration object is of type `Gapic::Config::Method` and includes
|
3682
|
+
# the following configuration fields:
|
3683
|
+
#
|
3684
|
+
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
3685
|
+
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
|
3686
|
+
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
3687
|
+
# include the following keys:
|
3688
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
3689
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
3690
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
3691
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
3692
|
+
# trigger a retry.
|
3693
|
+
#
|
3694
|
+
class Rpcs
|
3695
|
+
##
|
3696
|
+
# RPC-specific configuration for `list_sources`
|
3697
|
+
# @return [::Gapic::Config::Method]
|
3698
|
+
#
|
3699
|
+
attr_reader :list_sources
|
3700
|
+
##
|
3701
|
+
# RPC-specific configuration for `get_source`
|
3702
|
+
# @return [::Gapic::Config::Method]
|
3703
|
+
#
|
3704
|
+
attr_reader :get_source
|
3705
|
+
##
|
3706
|
+
# RPC-specific configuration for `create_source`
|
3707
|
+
# @return [::Gapic::Config::Method]
|
3708
|
+
#
|
3709
|
+
attr_reader :create_source
|
3710
|
+
##
|
3711
|
+
# RPC-specific configuration for `update_source`
|
3712
|
+
# @return [::Gapic::Config::Method]
|
3713
|
+
#
|
3714
|
+
attr_reader :update_source
|
3715
|
+
##
|
3716
|
+
# RPC-specific configuration for `delete_source`
|
3717
|
+
# @return [::Gapic::Config::Method]
|
3718
|
+
#
|
3719
|
+
attr_reader :delete_source
|
3720
|
+
##
|
3721
|
+
# RPC-specific configuration for `fetch_inventory`
|
3722
|
+
# @return [::Gapic::Config::Method]
|
3723
|
+
#
|
3724
|
+
attr_reader :fetch_inventory
|
3725
|
+
##
|
3726
|
+
# RPC-specific configuration for `list_utilization_reports`
|
3727
|
+
# @return [::Gapic::Config::Method]
|
3728
|
+
#
|
3729
|
+
attr_reader :list_utilization_reports
|
3730
|
+
##
|
3731
|
+
# RPC-specific configuration for `get_utilization_report`
|
3732
|
+
# @return [::Gapic::Config::Method]
|
3733
|
+
#
|
3734
|
+
attr_reader :get_utilization_report
|
3735
|
+
##
|
3736
|
+
# RPC-specific configuration for `create_utilization_report`
|
3737
|
+
# @return [::Gapic::Config::Method]
|
3738
|
+
#
|
3739
|
+
attr_reader :create_utilization_report
|
3740
|
+
##
|
3741
|
+
# RPC-specific configuration for `delete_utilization_report`
|
3742
|
+
# @return [::Gapic::Config::Method]
|
3743
|
+
#
|
3744
|
+
attr_reader :delete_utilization_report
|
3745
|
+
##
|
3746
|
+
# RPC-specific configuration for `list_datacenter_connectors`
|
3747
|
+
# @return [::Gapic::Config::Method]
|
3748
|
+
#
|
3749
|
+
attr_reader :list_datacenter_connectors
|
3750
|
+
##
|
3751
|
+
# RPC-specific configuration for `get_datacenter_connector`
|
3752
|
+
# @return [::Gapic::Config::Method]
|
3753
|
+
#
|
3754
|
+
attr_reader :get_datacenter_connector
|
3755
|
+
##
|
3756
|
+
# RPC-specific configuration for `create_datacenter_connector`
|
3757
|
+
# @return [::Gapic::Config::Method]
|
3758
|
+
#
|
3759
|
+
attr_reader :create_datacenter_connector
|
3760
|
+
##
|
3761
|
+
# RPC-specific configuration for `delete_datacenter_connector`
|
3762
|
+
# @return [::Gapic::Config::Method]
|
3763
|
+
#
|
3764
|
+
attr_reader :delete_datacenter_connector
|
3765
|
+
##
|
3766
|
+
# RPC-specific configuration for `upgrade_appliance`
|
3767
|
+
# @return [::Gapic::Config::Method]
|
3768
|
+
#
|
3769
|
+
attr_reader :upgrade_appliance
|
3770
|
+
##
|
3771
|
+
# RPC-specific configuration for `create_migrating_vm`
|
3772
|
+
# @return [::Gapic::Config::Method]
|
3773
|
+
#
|
3774
|
+
attr_reader :create_migrating_vm
|
3775
|
+
##
|
3776
|
+
# RPC-specific configuration for `list_migrating_vms`
|
3777
|
+
# @return [::Gapic::Config::Method]
|
3778
|
+
#
|
3779
|
+
attr_reader :list_migrating_vms
|
3780
|
+
##
|
3781
|
+
# RPC-specific configuration for `get_migrating_vm`
|
3782
|
+
# @return [::Gapic::Config::Method]
|
3783
|
+
#
|
3784
|
+
attr_reader :get_migrating_vm
|
3785
|
+
##
|
3786
|
+
# RPC-specific configuration for `update_migrating_vm`
|
3787
|
+
# @return [::Gapic::Config::Method]
|
3788
|
+
#
|
3789
|
+
attr_reader :update_migrating_vm
|
3790
|
+
##
|
3791
|
+
# RPC-specific configuration for `delete_migrating_vm`
|
3792
|
+
# @return [::Gapic::Config::Method]
|
3793
|
+
#
|
3794
|
+
attr_reader :delete_migrating_vm
|
3795
|
+
##
|
3796
|
+
# RPC-specific configuration for `start_migration`
|
3797
|
+
# @return [::Gapic::Config::Method]
|
3798
|
+
#
|
3799
|
+
attr_reader :start_migration
|
3800
|
+
##
|
3801
|
+
# RPC-specific configuration for `resume_migration`
|
3802
|
+
# @return [::Gapic::Config::Method]
|
3803
|
+
#
|
3804
|
+
attr_reader :resume_migration
|
3805
|
+
##
|
3806
|
+
# RPC-specific configuration for `pause_migration`
|
3807
|
+
# @return [::Gapic::Config::Method]
|
3808
|
+
#
|
3809
|
+
attr_reader :pause_migration
|
3810
|
+
##
|
3811
|
+
# RPC-specific configuration for `finalize_migration`
|
3812
|
+
# @return [::Gapic::Config::Method]
|
3813
|
+
#
|
3814
|
+
attr_reader :finalize_migration
|
3815
|
+
##
|
3816
|
+
# RPC-specific configuration for `create_clone_job`
|
3817
|
+
# @return [::Gapic::Config::Method]
|
3818
|
+
#
|
3819
|
+
attr_reader :create_clone_job
|
3820
|
+
##
|
3821
|
+
# RPC-specific configuration for `cancel_clone_job`
|
3822
|
+
# @return [::Gapic::Config::Method]
|
3823
|
+
#
|
3824
|
+
attr_reader :cancel_clone_job
|
3825
|
+
##
|
3826
|
+
# RPC-specific configuration for `list_clone_jobs`
|
3827
|
+
# @return [::Gapic::Config::Method]
|
3828
|
+
#
|
3829
|
+
attr_reader :list_clone_jobs
|
3830
|
+
##
|
3831
|
+
# RPC-specific configuration for `get_clone_job`
|
3832
|
+
# @return [::Gapic::Config::Method]
|
3833
|
+
#
|
3834
|
+
attr_reader :get_clone_job
|
3835
|
+
##
|
3836
|
+
# RPC-specific configuration for `create_cutover_job`
|
3837
|
+
# @return [::Gapic::Config::Method]
|
3838
|
+
#
|
3839
|
+
attr_reader :create_cutover_job
|
3840
|
+
##
|
3841
|
+
# RPC-specific configuration for `cancel_cutover_job`
|
3842
|
+
# @return [::Gapic::Config::Method]
|
3843
|
+
#
|
3844
|
+
attr_reader :cancel_cutover_job
|
3845
|
+
##
|
3846
|
+
# RPC-specific configuration for `list_cutover_jobs`
|
3847
|
+
# @return [::Gapic::Config::Method]
|
3848
|
+
#
|
3849
|
+
attr_reader :list_cutover_jobs
|
3850
|
+
##
|
3851
|
+
# RPC-specific configuration for `get_cutover_job`
|
3852
|
+
# @return [::Gapic::Config::Method]
|
3853
|
+
#
|
3854
|
+
attr_reader :get_cutover_job
|
3855
|
+
##
|
3856
|
+
# RPC-specific configuration for `list_groups`
|
3857
|
+
# @return [::Gapic::Config::Method]
|
3858
|
+
#
|
3859
|
+
attr_reader :list_groups
|
3860
|
+
##
|
3861
|
+
# RPC-specific configuration for `get_group`
|
3862
|
+
# @return [::Gapic::Config::Method]
|
3863
|
+
#
|
3864
|
+
attr_reader :get_group
|
3865
|
+
##
|
3866
|
+
# RPC-specific configuration for `create_group`
|
3867
|
+
# @return [::Gapic::Config::Method]
|
3868
|
+
#
|
3869
|
+
attr_reader :create_group
|
3870
|
+
##
|
3871
|
+
# RPC-specific configuration for `update_group`
|
3872
|
+
# @return [::Gapic::Config::Method]
|
3873
|
+
#
|
3874
|
+
attr_reader :update_group
|
3875
|
+
##
|
3876
|
+
# RPC-specific configuration for `delete_group`
|
3877
|
+
# @return [::Gapic::Config::Method]
|
3878
|
+
#
|
3879
|
+
attr_reader :delete_group
|
3880
|
+
##
|
3881
|
+
# RPC-specific configuration for `add_group_migration`
|
3882
|
+
# @return [::Gapic::Config::Method]
|
3883
|
+
#
|
3884
|
+
attr_reader :add_group_migration
|
3885
|
+
##
|
3886
|
+
# RPC-specific configuration for `remove_group_migration`
|
3887
|
+
# @return [::Gapic::Config::Method]
|
3888
|
+
#
|
3889
|
+
attr_reader :remove_group_migration
|
3890
|
+
##
|
3891
|
+
# RPC-specific configuration for `list_target_projects`
|
3892
|
+
# @return [::Gapic::Config::Method]
|
3893
|
+
#
|
3894
|
+
attr_reader :list_target_projects
|
3895
|
+
##
|
3896
|
+
# RPC-specific configuration for `get_target_project`
|
3897
|
+
# @return [::Gapic::Config::Method]
|
3898
|
+
#
|
3899
|
+
attr_reader :get_target_project
|
3900
|
+
##
|
3901
|
+
# RPC-specific configuration for `create_target_project`
|
3902
|
+
# @return [::Gapic::Config::Method]
|
3903
|
+
#
|
3904
|
+
attr_reader :create_target_project
|
3905
|
+
##
|
3906
|
+
# RPC-specific configuration for `update_target_project`
|
3907
|
+
# @return [::Gapic::Config::Method]
|
3908
|
+
#
|
3909
|
+
attr_reader :update_target_project
|
3910
|
+
##
|
3911
|
+
# RPC-specific configuration for `delete_target_project`
|
3912
|
+
# @return [::Gapic::Config::Method]
|
3913
|
+
#
|
3914
|
+
attr_reader :delete_target_project
|
3915
|
+
##
|
3916
|
+
# RPC-specific configuration for `list_replication_cycles`
|
3917
|
+
# @return [::Gapic::Config::Method]
|
3918
|
+
#
|
3919
|
+
attr_reader :list_replication_cycles
|
3920
|
+
##
|
3921
|
+
# RPC-specific configuration for `get_replication_cycle`
|
3922
|
+
# @return [::Gapic::Config::Method]
|
3923
|
+
#
|
3924
|
+
attr_reader :get_replication_cycle
|
3925
|
+
|
3926
|
+
# @private
|
3927
|
+
def initialize parent_rpcs = nil
|
3928
|
+
list_sources_config = parent_rpcs.list_sources if parent_rpcs.respond_to? :list_sources
|
3929
|
+
@list_sources = ::Gapic::Config::Method.new list_sources_config
|
3930
|
+
get_source_config = parent_rpcs.get_source if parent_rpcs.respond_to? :get_source
|
3931
|
+
@get_source = ::Gapic::Config::Method.new get_source_config
|
3932
|
+
create_source_config = parent_rpcs.create_source if parent_rpcs.respond_to? :create_source
|
3933
|
+
@create_source = ::Gapic::Config::Method.new create_source_config
|
3934
|
+
update_source_config = parent_rpcs.update_source if parent_rpcs.respond_to? :update_source
|
3935
|
+
@update_source = ::Gapic::Config::Method.new update_source_config
|
3936
|
+
delete_source_config = parent_rpcs.delete_source if parent_rpcs.respond_to? :delete_source
|
3937
|
+
@delete_source = ::Gapic::Config::Method.new delete_source_config
|
3938
|
+
fetch_inventory_config = parent_rpcs.fetch_inventory if parent_rpcs.respond_to? :fetch_inventory
|
3939
|
+
@fetch_inventory = ::Gapic::Config::Method.new fetch_inventory_config
|
3940
|
+
list_utilization_reports_config = parent_rpcs.list_utilization_reports if parent_rpcs.respond_to? :list_utilization_reports
|
3941
|
+
@list_utilization_reports = ::Gapic::Config::Method.new list_utilization_reports_config
|
3942
|
+
get_utilization_report_config = parent_rpcs.get_utilization_report if parent_rpcs.respond_to? :get_utilization_report
|
3943
|
+
@get_utilization_report = ::Gapic::Config::Method.new get_utilization_report_config
|
3944
|
+
create_utilization_report_config = parent_rpcs.create_utilization_report if parent_rpcs.respond_to? :create_utilization_report
|
3945
|
+
@create_utilization_report = ::Gapic::Config::Method.new create_utilization_report_config
|
3946
|
+
delete_utilization_report_config = parent_rpcs.delete_utilization_report if parent_rpcs.respond_to? :delete_utilization_report
|
3947
|
+
@delete_utilization_report = ::Gapic::Config::Method.new delete_utilization_report_config
|
3948
|
+
list_datacenter_connectors_config = parent_rpcs.list_datacenter_connectors if parent_rpcs.respond_to? :list_datacenter_connectors
|
3949
|
+
@list_datacenter_connectors = ::Gapic::Config::Method.new list_datacenter_connectors_config
|
3950
|
+
get_datacenter_connector_config = parent_rpcs.get_datacenter_connector if parent_rpcs.respond_to? :get_datacenter_connector
|
3951
|
+
@get_datacenter_connector = ::Gapic::Config::Method.new get_datacenter_connector_config
|
3952
|
+
create_datacenter_connector_config = parent_rpcs.create_datacenter_connector if parent_rpcs.respond_to? :create_datacenter_connector
|
3953
|
+
@create_datacenter_connector = ::Gapic::Config::Method.new create_datacenter_connector_config
|
3954
|
+
delete_datacenter_connector_config = parent_rpcs.delete_datacenter_connector if parent_rpcs.respond_to? :delete_datacenter_connector
|
3955
|
+
@delete_datacenter_connector = ::Gapic::Config::Method.new delete_datacenter_connector_config
|
3956
|
+
upgrade_appliance_config = parent_rpcs.upgrade_appliance if parent_rpcs.respond_to? :upgrade_appliance
|
3957
|
+
@upgrade_appliance = ::Gapic::Config::Method.new upgrade_appliance_config
|
3958
|
+
create_migrating_vm_config = parent_rpcs.create_migrating_vm if parent_rpcs.respond_to? :create_migrating_vm
|
3959
|
+
@create_migrating_vm = ::Gapic::Config::Method.new create_migrating_vm_config
|
3960
|
+
list_migrating_vms_config = parent_rpcs.list_migrating_vms if parent_rpcs.respond_to? :list_migrating_vms
|
3961
|
+
@list_migrating_vms = ::Gapic::Config::Method.new list_migrating_vms_config
|
3962
|
+
get_migrating_vm_config = parent_rpcs.get_migrating_vm if parent_rpcs.respond_to? :get_migrating_vm
|
3963
|
+
@get_migrating_vm = ::Gapic::Config::Method.new get_migrating_vm_config
|
3964
|
+
update_migrating_vm_config = parent_rpcs.update_migrating_vm if parent_rpcs.respond_to? :update_migrating_vm
|
3965
|
+
@update_migrating_vm = ::Gapic::Config::Method.new update_migrating_vm_config
|
3966
|
+
delete_migrating_vm_config = parent_rpcs.delete_migrating_vm if parent_rpcs.respond_to? :delete_migrating_vm
|
3967
|
+
@delete_migrating_vm = ::Gapic::Config::Method.new delete_migrating_vm_config
|
3968
|
+
start_migration_config = parent_rpcs.start_migration if parent_rpcs.respond_to? :start_migration
|
3969
|
+
@start_migration = ::Gapic::Config::Method.new start_migration_config
|
3970
|
+
resume_migration_config = parent_rpcs.resume_migration if parent_rpcs.respond_to? :resume_migration
|
3971
|
+
@resume_migration = ::Gapic::Config::Method.new resume_migration_config
|
3972
|
+
pause_migration_config = parent_rpcs.pause_migration if parent_rpcs.respond_to? :pause_migration
|
3973
|
+
@pause_migration = ::Gapic::Config::Method.new pause_migration_config
|
3974
|
+
finalize_migration_config = parent_rpcs.finalize_migration if parent_rpcs.respond_to? :finalize_migration
|
3975
|
+
@finalize_migration = ::Gapic::Config::Method.new finalize_migration_config
|
3976
|
+
create_clone_job_config = parent_rpcs.create_clone_job if parent_rpcs.respond_to? :create_clone_job
|
3977
|
+
@create_clone_job = ::Gapic::Config::Method.new create_clone_job_config
|
3978
|
+
cancel_clone_job_config = parent_rpcs.cancel_clone_job if parent_rpcs.respond_to? :cancel_clone_job
|
3979
|
+
@cancel_clone_job = ::Gapic::Config::Method.new cancel_clone_job_config
|
3980
|
+
list_clone_jobs_config = parent_rpcs.list_clone_jobs if parent_rpcs.respond_to? :list_clone_jobs
|
3981
|
+
@list_clone_jobs = ::Gapic::Config::Method.new list_clone_jobs_config
|
3982
|
+
get_clone_job_config = parent_rpcs.get_clone_job if parent_rpcs.respond_to? :get_clone_job
|
3983
|
+
@get_clone_job = ::Gapic::Config::Method.new get_clone_job_config
|
3984
|
+
create_cutover_job_config = parent_rpcs.create_cutover_job if parent_rpcs.respond_to? :create_cutover_job
|
3985
|
+
@create_cutover_job = ::Gapic::Config::Method.new create_cutover_job_config
|
3986
|
+
cancel_cutover_job_config = parent_rpcs.cancel_cutover_job if parent_rpcs.respond_to? :cancel_cutover_job
|
3987
|
+
@cancel_cutover_job = ::Gapic::Config::Method.new cancel_cutover_job_config
|
3988
|
+
list_cutover_jobs_config = parent_rpcs.list_cutover_jobs if parent_rpcs.respond_to? :list_cutover_jobs
|
3989
|
+
@list_cutover_jobs = ::Gapic::Config::Method.new list_cutover_jobs_config
|
3990
|
+
get_cutover_job_config = parent_rpcs.get_cutover_job if parent_rpcs.respond_to? :get_cutover_job
|
3991
|
+
@get_cutover_job = ::Gapic::Config::Method.new get_cutover_job_config
|
3992
|
+
list_groups_config = parent_rpcs.list_groups if parent_rpcs.respond_to? :list_groups
|
3993
|
+
@list_groups = ::Gapic::Config::Method.new list_groups_config
|
3994
|
+
get_group_config = parent_rpcs.get_group if parent_rpcs.respond_to? :get_group
|
3995
|
+
@get_group = ::Gapic::Config::Method.new get_group_config
|
3996
|
+
create_group_config = parent_rpcs.create_group if parent_rpcs.respond_to? :create_group
|
3997
|
+
@create_group = ::Gapic::Config::Method.new create_group_config
|
3998
|
+
update_group_config = parent_rpcs.update_group if parent_rpcs.respond_to? :update_group
|
3999
|
+
@update_group = ::Gapic::Config::Method.new update_group_config
|
4000
|
+
delete_group_config = parent_rpcs.delete_group if parent_rpcs.respond_to? :delete_group
|
4001
|
+
@delete_group = ::Gapic::Config::Method.new delete_group_config
|
4002
|
+
add_group_migration_config = parent_rpcs.add_group_migration if parent_rpcs.respond_to? :add_group_migration
|
4003
|
+
@add_group_migration = ::Gapic::Config::Method.new add_group_migration_config
|
4004
|
+
remove_group_migration_config = parent_rpcs.remove_group_migration if parent_rpcs.respond_to? :remove_group_migration
|
4005
|
+
@remove_group_migration = ::Gapic::Config::Method.new remove_group_migration_config
|
4006
|
+
list_target_projects_config = parent_rpcs.list_target_projects if parent_rpcs.respond_to? :list_target_projects
|
4007
|
+
@list_target_projects = ::Gapic::Config::Method.new list_target_projects_config
|
4008
|
+
get_target_project_config = parent_rpcs.get_target_project if parent_rpcs.respond_to? :get_target_project
|
4009
|
+
@get_target_project = ::Gapic::Config::Method.new get_target_project_config
|
4010
|
+
create_target_project_config = parent_rpcs.create_target_project if parent_rpcs.respond_to? :create_target_project
|
4011
|
+
@create_target_project = ::Gapic::Config::Method.new create_target_project_config
|
4012
|
+
update_target_project_config = parent_rpcs.update_target_project if parent_rpcs.respond_to? :update_target_project
|
4013
|
+
@update_target_project = ::Gapic::Config::Method.new update_target_project_config
|
4014
|
+
delete_target_project_config = parent_rpcs.delete_target_project if parent_rpcs.respond_to? :delete_target_project
|
4015
|
+
@delete_target_project = ::Gapic::Config::Method.new delete_target_project_config
|
4016
|
+
list_replication_cycles_config = parent_rpcs.list_replication_cycles if parent_rpcs.respond_to? :list_replication_cycles
|
4017
|
+
@list_replication_cycles = ::Gapic::Config::Method.new list_replication_cycles_config
|
4018
|
+
get_replication_cycle_config = parent_rpcs.get_replication_cycle if parent_rpcs.respond_to? :get_replication_cycle
|
4019
|
+
@get_replication_cycle = ::Gapic::Config::Method.new get_replication_cycle_config
|
4020
|
+
|
4021
|
+
yield self if block_given?
|
4022
|
+
end
|
4023
|
+
end
|
4024
|
+
end
|
4025
|
+
end
|
4026
|
+
end
|
4027
|
+
end
|
4028
|
+
end
|
4029
|
+
end
|
4030
|
+
end
|
4031
|
+
end
|