google-cloud-dataplex-v1 0.6.1 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (31) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/lib/google/cloud/dataplex/v1/bindings_override.rb +327 -0
  4. data/lib/google/cloud/dataplex/v1/content_service/client.rb +4 -6
  5. data/lib/google/cloud/dataplex/v1/content_service/rest/client.rb +969 -0
  6. data/lib/google/cloud/dataplex/v1/content_service/rest/service_stub.rb +584 -0
  7. data/lib/google/cloud/dataplex/v1/content_service/rest.rb +53 -0
  8. data/lib/google/cloud/dataplex/v1/content_service.rb +6 -0
  9. data/lib/google/cloud/dataplex/v1/data_scan_service/client.rb +20 -24
  10. data/lib/google/cloud/dataplex/v1/data_scan_service/operations.rb +12 -14
  11. data/lib/google/cloud/dataplex/v1/data_scan_service/rest/client.rb +948 -0
  12. data/lib/google/cloud/dataplex/v1/data_scan_service/rest/operations.rb +793 -0
  13. data/lib/google/cloud/dataplex/v1/data_scan_service/rest/service_stub.rb +523 -0
  14. data/lib/google/cloud/dataplex/v1/data_scan_service/rest.rb +56 -0
  15. data/lib/google/cloud/dataplex/v1/data_scan_service.rb +6 -0
  16. data/lib/google/cloud/dataplex/v1/dataplex_service/client.rb +100 -120
  17. data/lib/google/cloud/dataplex/v1/dataplex_service/operations.rb +12 -14
  18. data/lib/google/cloud/dataplex/v1/dataplex_service/rest/client.rb +2910 -0
  19. data/lib/google/cloud/dataplex/v1/dataplex_service/rest/operations.rb +793 -0
  20. data/lib/google/cloud/dataplex/v1/dataplex_service/rest/service_stub.rb +1947 -0
  21. data/lib/google/cloud/dataplex/v1/dataplex_service/rest.rb +58 -0
  22. data/lib/google/cloud/dataplex/v1/dataplex_service.rb +6 -0
  23. data/lib/google/cloud/dataplex/v1/metadata_service/client.rb +8 -12
  24. data/lib/google/cloud/dataplex/v1/metadata_service/rest/client.rb +1051 -0
  25. data/lib/google/cloud/dataplex/v1/metadata_service/rest/service_stub.rb +582 -0
  26. data/lib/google/cloud/dataplex/v1/metadata_service/rest.rb +54 -0
  27. data/lib/google/cloud/dataplex/v1/metadata_service.rb +6 -0
  28. data/lib/google/cloud/dataplex/v1/rest.rb +41 -0
  29. data/lib/google/cloud/dataplex/v1/version.rb +1 -1
  30. data/lib/google/cloud/dataplex/v1.rb +5 -0
  31. metadata +27 -11
@@ -0,0 +1,2910 @@
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/dataplex/v1/service_pb"
21
+ require "google/cloud/dataplex/v1/dataplex_service/rest/service_stub"
22
+ require "google/cloud/location/rest"
23
+ require "google/iam/v1/rest"
24
+
25
+ module Google
26
+ module Cloud
27
+ module Dataplex
28
+ module V1
29
+ module DataplexService
30
+ module Rest
31
+ ##
32
+ # REST client for the DataplexService service.
33
+ #
34
+ # Dataplex service provides data lakes as a service. The primary resources
35
+ # offered by this service are Lakes, Zones and Assets which collectively allow
36
+ # a data administrator to organize, manage, secure and catalog data across
37
+ # their organization located across cloud projects in a variety of storage
38
+ # systems including Cloud Storage and BigQuery.
39
+ #
40
+ class Client
41
+ include Paths
42
+
43
+ # @private
44
+ attr_reader :dataplex_service_stub
45
+
46
+ ##
47
+ # Configure the DataplexService Client class.
48
+ #
49
+ # See {::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client::Configuration}
50
+ # for a description of the configuration fields.
51
+ #
52
+ # @example
53
+ #
54
+ # # Modify the configuration for all DataplexService clients
55
+ # ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client.configure do |config|
56
+ # config.timeout = 10.0
57
+ # end
58
+ #
59
+ # @yield [config] Configure the Client client.
60
+ # @yieldparam config [Client::Configuration]
61
+ #
62
+ # @return [Client::Configuration]
63
+ #
64
+ def self.configure
65
+ @configure ||= begin
66
+ namespace = ["Google", "Cloud", "Dataplex", "V1"]
67
+ parent_config = while namespace.any?
68
+ parent_name = namespace.join "::"
69
+ parent_const = const_get parent_name
70
+ break parent_const.configure if parent_const.respond_to? :configure
71
+ namespace.pop
72
+ end
73
+ default_config = Client::Configuration.new parent_config
74
+
75
+ default_config.rpcs.create_lake.timeout = 60.0
76
+
77
+ default_config.rpcs.update_lake.timeout = 60.0
78
+
79
+ default_config.rpcs.delete_lake.timeout = 60.0
80
+
81
+ default_config.rpcs.list_lakes.timeout = 60.0
82
+ default_config.rpcs.list_lakes.retry_policy = {
83
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
84
+ }
85
+
86
+ default_config.rpcs.get_lake.timeout = 60.0
87
+ default_config.rpcs.get_lake.retry_policy = {
88
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
89
+ }
90
+
91
+ default_config.rpcs.list_lake_actions.timeout = 60.0
92
+ default_config.rpcs.list_lake_actions.retry_policy = {
93
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
94
+ }
95
+
96
+ default_config.rpcs.create_zone.timeout = 60.0
97
+
98
+ default_config.rpcs.update_zone.timeout = 60.0
99
+
100
+ default_config.rpcs.delete_zone.timeout = 60.0
101
+
102
+ default_config.rpcs.list_zones.timeout = 60.0
103
+ default_config.rpcs.list_zones.retry_policy = {
104
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
105
+ }
106
+
107
+ default_config.rpcs.get_zone.timeout = 60.0
108
+ default_config.rpcs.get_zone.retry_policy = {
109
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
110
+ }
111
+
112
+ default_config.rpcs.list_zone_actions.timeout = 60.0
113
+ default_config.rpcs.list_zone_actions.retry_policy = {
114
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
115
+ }
116
+
117
+ default_config.rpcs.create_asset.timeout = 60.0
118
+
119
+ default_config.rpcs.update_asset.timeout = 60.0
120
+
121
+ default_config.rpcs.delete_asset.timeout = 60.0
122
+
123
+ default_config.rpcs.list_assets.timeout = 60.0
124
+ default_config.rpcs.list_assets.retry_policy = {
125
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
126
+ }
127
+
128
+ default_config.rpcs.get_asset.timeout = 60.0
129
+ default_config.rpcs.get_asset.retry_policy = {
130
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
131
+ }
132
+
133
+ default_config.rpcs.list_asset_actions.timeout = 60.0
134
+ default_config.rpcs.list_asset_actions.retry_policy = {
135
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
136
+ }
137
+
138
+ default_config.rpcs.create_task.timeout = 60.0
139
+
140
+ default_config.rpcs.update_task.timeout = 60.0
141
+
142
+ default_config.rpcs.delete_task.timeout = 60.0
143
+
144
+ default_config.rpcs.list_tasks.timeout = 60.0
145
+ default_config.rpcs.list_tasks.retry_policy = {
146
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
147
+ }
148
+
149
+ default_config.rpcs.get_task.timeout = 60.0
150
+ default_config.rpcs.get_task.retry_policy = {
151
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
152
+ }
153
+
154
+ default_config.rpcs.list_jobs.timeout = 60.0
155
+ default_config.rpcs.list_jobs.retry_policy = {
156
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
157
+ }
158
+
159
+ default_config.rpcs.get_job.timeout = 60.0
160
+ default_config.rpcs.get_job.retry_policy = {
161
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
162
+ }
163
+
164
+ default_config.rpcs.cancel_job.timeout = 60.0
165
+
166
+ default_config.rpcs.create_environment.timeout = 60.0
167
+
168
+ default_config.rpcs.update_environment.timeout = 60.0
169
+
170
+ default_config.rpcs.delete_environment.timeout = 60.0
171
+
172
+ default_config.rpcs.list_environments.timeout = 60.0
173
+ default_config.rpcs.list_environments.retry_policy = {
174
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
175
+ }
176
+
177
+ default_config.rpcs.get_environment.timeout = 60.0
178
+ default_config.rpcs.get_environment.retry_policy = {
179
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
180
+ }
181
+
182
+ default_config
183
+ end
184
+ yield @configure if block_given?
185
+ @configure
186
+ end
187
+
188
+ ##
189
+ # Configure the DataplexService Client instance.
190
+ #
191
+ # The configuration is set to the derived mode, meaning that values can be changed,
192
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
193
+ # should be made on {Client.configure}.
194
+ #
195
+ # See {::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client::Configuration}
196
+ # for a description of the configuration fields.
197
+ #
198
+ # @yield [config] Configure the Client client.
199
+ # @yieldparam config [Client::Configuration]
200
+ #
201
+ # @return [Client::Configuration]
202
+ #
203
+ def configure
204
+ yield @config if block_given?
205
+ @config
206
+ end
207
+
208
+ ##
209
+ # Create a new DataplexService REST client object.
210
+ #
211
+ # @example
212
+ #
213
+ # # Create a client using the default configuration
214
+ # client = ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client.new
215
+ #
216
+ # # Create a client using a custom configuration
217
+ # client = ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client.new do |config|
218
+ # config.timeout = 10.0
219
+ # end
220
+ #
221
+ # @yield [config] Configure the DataplexService client.
222
+ # @yieldparam config [Client::Configuration]
223
+ #
224
+ def initialize
225
+ # Create the configuration object
226
+ @config = Configuration.new Client.configure
227
+
228
+ # Yield the configuration if needed
229
+ yield @config if block_given?
230
+
231
+ # Create credentials
232
+ credentials = @config.credentials
233
+ # Use self-signed JWT if the endpoint is unchanged from default,
234
+ # but only if the default endpoint does not have a region prefix.
235
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
236
+ !@config.endpoint.split(".").first.include?("-")
237
+ credentials ||= Credentials.default scope: @config.scope,
238
+ enable_self_signed_jwt: enable_self_signed_jwt
239
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
240
+ credentials = Credentials.new credentials, scope: @config.scope
241
+ end
242
+
243
+ @quota_project_id = @config.quota_project
244
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
245
+
246
+ @operations_client = ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Operations.new do |config|
247
+ config.credentials = credentials
248
+ config.quota_project = @quota_project_id
249
+ config.endpoint = @config.endpoint
250
+ end
251
+
252
+ @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
253
+ config.credentials = credentials
254
+ config.quota_project = @quota_project_id
255
+ config.endpoint = @config.endpoint
256
+ config.bindings_override = @config.bindings_override
257
+ end
258
+
259
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
260
+ config.credentials = credentials
261
+ config.quota_project = @quota_project_id
262
+ config.endpoint = @config.endpoint
263
+ config.bindings_override = @config.bindings_override
264
+ end
265
+
266
+ @dataplex_service_stub = ::Google::Cloud::Dataplex::V1::DataplexService::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
267
+ end
268
+
269
+ ##
270
+ # Get the associated client for long-running operations.
271
+ #
272
+ # @return [::Google::Cloud::Dataplex::V1::DataplexService::Rest::Operations]
273
+ #
274
+ attr_reader :operations_client
275
+
276
+ ##
277
+ # Get the associated client for mix-in of the Locations.
278
+ #
279
+ # @return [Google::Cloud::Location::Locations::Rest::Client]
280
+ #
281
+ attr_reader :location_client
282
+
283
+ ##
284
+ # Get the associated client for mix-in of the IAMPolicy.
285
+ #
286
+ # @return [Google::Iam::V1::IAMPolicy::Rest::Client]
287
+ #
288
+ attr_reader :iam_policy_client
289
+
290
+ # Service calls
291
+
292
+ ##
293
+ # Creates a lake resource.
294
+ #
295
+ # @overload create_lake(request, options = nil)
296
+ # Pass arguments to `create_lake` via a request object, either of type
297
+ # {::Google::Cloud::Dataplex::V1::CreateLakeRequest} or an equivalent Hash.
298
+ #
299
+ # @param request [::Google::Cloud::Dataplex::V1::CreateLakeRequest, ::Hash]
300
+ # A request object representing the call parameters. Required. To specify no
301
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
302
+ # @param options [::Gapic::CallOptions, ::Hash]
303
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
304
+ #
305
+ # @overload create_lake(parent: nil, lake_id: nil, lake: nil, validate_only: nil)
306
+ # Pass arguments to `create_lake` via keyword arguments. Note that at
307
+ # least one keyword argument is required. To specify no parameters, or to keep all
308
+ # the default parameter values, pass an empty Hash as a request object (see above).
309
+ #
310
+ # @param parent [::String]
311
+ # Required. The resource name of the lake location, of the form:
312
+ # projects/\\{project_number}/locations/\\{location_id}
313
+ # where `location_id` refers to a GCP region.
314
+ # @param lake_id [::String]
315
+ # Required. Lake identifier.
316
+ # This ID will be used to generate names such as database and dataset names
317
+ # when publishing metadata to Hive Metastore and BigQuery.
318
+ # * Must contain only lowercase letters, numbers and hyphens.
319
+ # * Must start with a letter.
320
+ # * Must end with a number or a letter.
321
+ # * Must be between 1-63 characters.
322
+ # * Must be unique within the customer project / location.
323
+ # @param lake [::Google::Cloud::Dataplex::V1::Lake, ::Hash]
324
+ # Required. Lake resource
325
+ # @param validate_only [::Boolean]
326
+ # Optional. Only validate the request, but do not perform mutations.
327
+ # The default is false.
328
+ # @yield [result, operation] Access the result along with the TransportOperation object
329
+ # @yieldparam result [::Gapic::Operation]
330
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
331
+ #
332
+ # @return [::Gapic::Operation]
333
+ #
334
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
335
+ def create_lake request, options = nil
336
+ raise ::ArgumentError, "request must be provided" if request.nil?
337
+
338
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CreateLakeRequest
339
+
340
+ # Converts hash and nil to an options object
341
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
342
+
343
+ # Customize the options with defaults
344
+ call_metadata = @config.rpcs.create_lake.metadata.to_h
345
+
346
+ # Set x-goog-api-client and x-goog-user-project headers
347
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
348
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
349
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
350
+ transports_version_send: [:rest]
351
+
352
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
353
+
354
+ options.apply_defaults timeout: @config.rpcs.create_lake.timeout,
355
+ metadata: call_metadata,
356
+ retry_policy: @config.rpcs.create_lake.retry_policy
357
+
358
+ options.apply_defaults timeout: @config.timeout,
359
+ metadata: @config.metadata,
360
+ retry_policy: @config.retry_policy
361
+
362
+ @dataplex_service_stub.create_lake request, options do |result, operation|
363
+ result = ::Gapic::Operation.new result, @operations_client, options: options
364
+ yield result, operation if block_given?
365
+ return result
366
+ end
367
+ rescue ::Gapic::Rest::Error => e
368
+ raise ::Google::Cloud::Error.from_error(e)
369
+ end
370
+
371
+ ##
372
+ # Updates a lake resource.
373
+ #
374
+ # @overload update_lake(request, options = nil)
375
+ # Pass arguments to `update_lake` via a request object, either of type
376
+ # {::Google::Cloud::Dataplex::V1::UpdateLakeRequest} or an equivalent Hash.
377
+ #
378
+ # @param request [::Google::Cloud::Dataplex::V1::UpdateLakeRequest, ::Hash]
379
+ # A request object representing the call parameters. Required. To specify no
380
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
381
+ # @param options [::Gapic::CallOptions, ::Hash]
382
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
383
+ #
384
+ # @overload update_lake(update_mask: nil, lake: nil, validate_only: nil)
385
+ # Pass arguments to `update_lake` via keyword arguments. Note that at
386
+ # least one keyword argument is required. To specify no parameters, or to keep all
387
+ # the default parameter values, pass an empty Hash as a request object (see above).
388
+ #
389
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
390
+ # Required. Mask of fields to update.
391
+ # @param lake [::Google::Cloud::Dataplex::V1::Lake, ::Hash]
392
+ # Required. Update description.
393
+ # Only fields specified in `update_mask` are updated.
394
+ # @param validate_only [::Boolean]
395
+ # Optional. Only validate the request, but do not perform mutations.
396
+ # The default is false.
397
+ # @yield [result, operation] Access the result along with the TransportOperation object
398
+ # @yieldparam result [::Gapic::Operation]
399
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
400
+ #
401
+ # @return [::Gapic::Operation]
402
+ #
403
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
404
+ def update_lake request, options = nil
405
+ raise ::ArgumentError, "request must be provided" if request.nil?
406
+
407
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::UpdateLakeRequest
408
+
409
+ # Converts hash and nil to an options object
410
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
411
+
412
+ # Customize the options with defaults
413
+ call_metadata = @config.rpcs.update_lake.metadata.to_h
414
+
415
+ # Set x-goog-api-client and x-goog-user-project headers
416
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
417
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
418
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
419
+ transports_version_send: [:rest]
420
+
421
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
422
+
423
+ options.apply_defaults timeout: @config.rpcs.update_lake.timeout,
424
+ metadata: call_metadata,
425
+ retry_policy: @config.rpcs.update_lake.retry_policy
426
+
427
+ options.apply_defaults timeout: @config.timeout,
428
+ metadata: @config.metadata,
429
+ retry_policy: @config.retry_policy
430
+
431
+ @dataplex_service_stub.update_lake request, options do |result, operation|
432
+ result = ::Gapic::Operation.new result, @operations_client, options: options
433
+ yield result, operation if block_given?
434
+ return result
435
+ end
436
+ rescue ::Gapic::Rest::Error => e
437
+ raise ::Google::Cloud::Error.from_error(e)
438
+ end
439
+
440
+ ##
441
+ # Deletes a lake resource. All zones within the lake must be deleted before
442
+ # the lake can be deleted.
443
+ #
444
+ # @overload delete_lake(request, options = nil)
445
+ # Pass arguments to `delete_lake` via a request object, either of type
446
+ # {::Google::Cloud::Dataplex::V1::DeleteLakeRequest} or an equivalent Hash.
447
+ #
448
+ # @param request [::Google::Cloud::Dataplex::V1::DeleteLakeRequest, ::Hash]
449
+ # A request object representing the call parameters. Required. To specify no
450
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
451
+ # @param options [::Gapic::CallOptions, ::Hash]
452
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
453
+ #
454
+ # @overload delete_lake(name: nil)
455
+ # Pass arguments to `delete_lake` via keyword arguments. Note that at
456
+ # least one keyword argument is required. To specify no parameters, or to keep all
457
+ # the default parameter values, pass an empty Hash as a request object (see above).
458
+ #
459
+ # @param name [::String]
460
+ # Required. The resource name of the lake:
461
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
462
+ # @yield [result, operation] Access the result along with the TransportOperation object
463
+ # @yieldparam result [::Gapic::Operation]
464
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
465
+ #
466
+ # @return [::Gapic::Operation]
467
+ #
468
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
469
+ def delete_lake request, options = nil
470
+ raise ::ArgumentError, "request must be provided" if request.nil?
471
+
472
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::DeleteLakeRequest
473
+
474
+ # Converts hash and nil to an options object
475
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
476
+
477
+ # Customize the options with defaults
478
+ call_metadata = @config.rpcs.delete_lake.metadata.to_h
479
+
480
+ # Set x-goog-api-client and x-goog-user-project headers
481
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
482
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
483
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
484
+ transports_version_send: [:rest]
485
+
486
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
487
+
488
+ options.apply_defaults timeout: @config.rpcs.delete_lake.timeout,
489
+ metadata: call_metadata,
490
+ retry_policy: @config.rpcs.delete_lake.retry_policy
491
+
492
+ options.apply_defaults timeout: @config.timeout,
493
+ metadata: @config.metadata,
494
+ retry_policy: @config.retry_policy
495
+
496
+ @dataplex_service_stub.delete_lake request, options do |result, operation|
497
+ result = ::Gapic::Operation.new result, @operations_client, options: options
498
+ yield result, operation if block_given?
499
+ return result
500
+ end
501
+ rescue ::Gapic::Rest::Error => e
502
+ raise ::Google::Cloud::Error.from_error(e)
503
+ end
504
+
505
+ ##
506
+ # Lists lake resources in a project and location.
507
+ #
508
+ # @overload list_lakes(request, options = nil)
509
+ # Pass arguments to `list_lakes` via a request object, either of type
510
+ # {::Google::Cloud::Dataplex::V1::ListLakesRequest} or an equivalent Hash.
511
+ #
512
+ # @param request [::Google::Cloud::Dataplex::V1::ListLakesRequest, ::Hash]
513
+ # A request object representing the call parameters. Required. To specify no
514
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
515
+ # @param options [::Gapic::CallOptions, ::Hash]
516
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
517
+ #
518
+ # @overload list_lakes(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
519
+ # Pass arguments to `list_lakes` via keyword arguments. Note that at
520
+ # least one keyword argument is required. To specify no parameters, or to keep all
521
+ # the default parameter values, pass an empty Hash as a request object (see above).
522
+ #
523
+ # @param parent [::String]
524
+ # Required. The resource name of the lake location, of the form:
525
+ # `projects/{project_number}/locations/{location_id}`
526
+ # where `location_id` refers to a GCP region.
527
+ # @param page_size [::Integer]
528
+ # Optional. Maximum number of Lakes to return. The service may return fewer
529
+ # than this value. If unspecified, at most 10 lakes will be returned. The
530
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
531
+ # @param page_token [::String]
532
+ # Optional. Page token received from a previous `ListLakes` call. Provide
533
+ # this to retrieve the subsequent page. When paginating, all other parameters
534
+ # provided to `ListLakes` must match the call that provided the page token.
535
+ # @param filter [::String]
536
+ # Optional. Filter request.
537
+ # @param order_by [::String]
538
+ # Optional. Order by fields for the result.
539
+ # @yield [result, operation] Access the result along with the TransportOperation object
540
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::ListLakesResponse]
541
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
542
+ #
543
+ # @return [::Google::Cloud::Dataplex::V1::ListLakesResponse]
544
+ #
545
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
546
+ def list_lakes request, options = nil
547
+ raise ::ArgumentError, "request must be provided" if request.nil?
548
+
549
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListLakesRequest
550
+
551
+ # Converts hash and nil to an options object
552
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
553
+
554
+ # Customize the options with defaults
555
+ call_metadata = @config.rpcs.list_lakes.metadata.to_h
556
+
557
+ # Set x-goog-api-client and x-goog-user-project headers
558
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
559
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
560
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
561
+ transports_version_send: [:rest]
562
+
563
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
564
+
565
+ options.apply_defaults timeout: @config.rpcs.list_lakes.timeout,
566
+ metadata: call_metadata,
567
+ retry_policy: @config.rpcs.list_lakes.retry_policy
568
+
569
+ options.apply_defaults timeout: @config.timeout,
570
+ metadata: @config.metadata,
571
+ retry_policy: @config.retry_policy
572
+
573
+ @dataplex_service_stub.list_lakes request, options do |result, operation|
574
+ yield result, operation if block_given?
575
+ return result
576
+ end
577
+ rescue ::Gapic::Rest::Error => e
578
+ raise ::Google::Cloud::Error.from_error(e)
579
+ end
580
+
581
+ ##
582
+ # Retrieves a lake resource.
583
+ #
584
+ # @overload get_lake(request, options = nil)
585
+ # Pass arguments to `get_lake` via a request object, either of type
586
+ # {::Google::Cloud::Dataplex::V1::GetLakeRequest} or an equivalent Hash.
587
+ #
588
+ # @param request [::Google::Cloud::Dataplex::V1::GetLakeRequest, ::Hash]
589
+ # A request object representing the call parameters. Required. To specify no
590
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
591
+ # @param options [::Gapic::CallOptions, ::Hash]
592
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
593
+ #
594
+ # @overload get_lake(name: nil)
595
+ # Pass arguments to `get_lake` via keyword arguments. Note that at
596
+ # least one keyword argument is required. To specify no parameters, or to keep all
597
+ # the default parameter values, pass an empty Hash as a request object (see above).
598
+ #
599
+ # @param name [::String]
600
+ # Required. The resource name of the lake:
601
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
602
+ # @yield [result, operation] Access the result along with the TransportOperation object
603
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Lake]
604
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
605
+ #
606
+ # @return [::Google::Cloud::Dataplex::V1::Lake]
607
+ #
608
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
609
+ def get_lake request, options = nil
610
+ raise ::ArgumentError, "request must be provided" if request.nil?
611
+
612
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetLakeRequest
613
+
614
+ # Converts hash and nil to an options object
615
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
616
+
617
+ # Customize the options with defaults
618
+ call_metadata = @config.rpcs.get_lake.metadata.to_h
619
+
620
+ # Set x-goog-api-client and x-goog-user-project headers
621
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
622
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
623
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
624
+ transports_version_send: [:rest]
625
+
626
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
627
+
628
+ options.apply_defaults timeout: @config.rpcs.get_lake.timeout,
629
+ metadata: call_metadata,
630
+ retry_policy: @config.rpcs.get_lake.retry_policy
631
+
632
+ options.apply_defaults timeout: @config.timeout,
633
+ metadata: @config.metadata,
634
+ retry_policy: @config.retry_policy
635
+
636
+ @dataplex_service_stub.get_lake request, options do |result, operation|
637
+ yield result, operation if block_given?
638
+ return result
639
+ end
640
+ rescue ::Gapic::Rest::Error => e
641
+ raise ::Google::Cloud::Error.from_error(e)
642
+ end
643
+
644
+ ##
645
+ # Lists action resources in a lake.
646
+ #
647
+ # @overload list_lake_actions(request, options = nil)
648
+ # Pass arguments to `list_lake_actions` via a request object, either of type
649
+ # {::Google::Cloud::Dataplex::V1::ListLakeActionsRequest} or an equivalent Hash.
650
+ #
651
+ # @param request [::Google::Cloud::Dataplex::V1::ListLakeActionsRequest, ::Hash]
652
+ # A request object representing the call parameters. Required. To specify no
653
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
654
+ # @param options [::Gapic::CallOptions, ::Hash]
655
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
656
+ #
657
+ # @overload list_lake_actions(parent: nil, page_size: nil, page_token: nil)
658
+ # Pass arguments to `list_lake_actions` via keyword arguments. Note that at
659
+ # least one keyword argument is required. To specify no parameters, or to keep all
660
+ # the default parameter values, pass an empty Hash as a request object (see above).
661
+ #
662
+ # @param parent [::String]
663
+ # Required. The resource name of the parent lake:
664
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
665
+ # @param page_size [::Integer]
666
+ # Optional. Maximum number of actions to return. The service may return fewer
667
+ # than this value. If unspecified, at most 10 actions will be returned. The
668
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
669
+ # @param page_token [::String]
670
+ # Optional. Page token received from a previous `ListLakeActions` call.
671
+ # Provide this to retrieve the subsequent page. When paginating, all other
672
+ # parameters provided to `ListLakeActions` must match the call that provided
673
+ # the page token.
674
+ # @yield [result, operation] Access the result along with the TransportOperation object
675
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
676
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
677
+ #
678
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
679
+ #
680
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
681
+ def list_lake_actions request, options = nil
682
+ raise ::ArgumentError, "request must be provided" if request.nil?
683
+
684
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListLakeActionsRequest
685
+
686
+ # Converts hash and nil to an options object
687
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
688
+
689
+ # Customize the options with defaults
690
+ call_metadata = @config.rpcs.list_lake_actions.metadata.to_h
691
+
692
+ # Set x-goog-api-client and x-goog-user-project headers
693
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
694
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
695
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
696
+ transports_version_send: [:rest]
697
+
698
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
699
+
700
+ options.apply_defaults timeout: @config.rpcs.list_lake_actions.timeout,
701
+ metadata: call_metadata,
702
+ retry_policy: @config.rpcs.list_lake_actions.retry_policy
703
+
704
+ options.apply_defaults timeout: @config.timeout,
705
+ metadata: @config.metadata,
706
+ retry_policy: @config.retry_policy
707
+
708
+ @dataplex_service_stub.list_lake_actions request, options do |result, operation|
709
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_lake_actions, "actions", request, result, options
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
+ # Creates a zone resource within a lake.
719
+ #
720
+ # @overload create_zone(request, options = nil)
721
+ # Pass arguments to `create_zone` via a request object, either of type
722
+ # {::Google::Cloud::Dataplex::V1::CreateZoneRequest} or an equivalent Hash.
723
+ #
724
+ # @param request [::Google::Cloud::Dataplex::V1::CreateZoneRequest, ::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 create_zone(parent: nil, zone_id: nil, zone: nil, validate_only: nil)
731
+ # Pass arguments to `create_zone` 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 parent [::String]
736
+ # Required. The resource name of the parent lake:
737
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
738
+ # @param zone_id [::String]
739
+ # Required. Zone identifier.
740
+ # This ID will be used to generate names such as database and dataset names
741
+ # when publishing metadata to Hive Metastore and BigQuery.
742
+ # * Must contain only lowercase letters, numbers and hyphens.
743
+ # * Must start with a letter.
744
+ # * Must end with a number or a letter.
745
+ # * Must be between 1-63 characters.
746
+ # * Must be unique across all lakes from all locations in a project.
747
+ # * Must not be one of the reserved IDs (i.e. "default", "global-temp")
748
+ # @param zone [::Google::Cloud::Dataplex::V1::Zone, ::Hash]
749
+ # Required. Zone resource.
750
+ # @param validate_only [::Boolean]
751
+ # Optional. Only validate the request, but do not perform mutations.
752
+ # The default is false.
753
+ # @yield [result, operation] Access the result along with the TransportOperation object
754
+ # @yieldparam result [::Gapic::Operation]
755
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
756
+ #
757
+ # @return [::Gapic::Operation]
758
+ #
759
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
760
+ def create_zone request, options = nil
761
+ raise ::ArgumentError, "request must be provided" if request.nil?
762
+
763
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CreateZoneRequest
764
+
765
+ # Converts hash and nil to an options object
766
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
767
+
768
+ # Customize the options with defaults
769
+ call_metadata = @config.rpcs.create_zone.metadata.to_h
770
+
771
+ # Set x-goog-api-client and x-goog-user-project headers
772
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
773
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
774
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
775
+ transports_version_send: [:rest]
776
+
777
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
778
+
779
+ options.apply_defaults timeout: @config.rpcs.create_zone.timeout,
780
+ metadata: call_metadata,
781
+ retry_policy: @config.rpcs.create_zone.retry_policy
782
+
783
+ options.apply_defaults timeout: @config.timeout,
784
+ metadata: @config.metadata,
785
+ retry_policy: @config.retry_policy
786
+
787
+ @dataplex_service_stub.create_zone request, options do |result, operation|
788
+ result = ::Gapic::Operation.new result, @operations_client, options: options
789
+ yield result, operation if block_given?
790
+ return result
791
+ end
792
+ rescue ::Gapic::Rest::Error => e
793
+ raise ::Google::Cloud::Error.from_error(e)
794
+ end
795
+
796
+ ##
797
+ # Updates a zone resource.
798
+ #
799
+ # @overload update_zone(request, options = nil)
800
+ # Pass arguments to `update_zone` via a request object, either of type
801
+ # {::Google::Cloud::Dataplex::V1::UpdateZoneRequest} or an equivalent Hash.
802
+ #
803
+ # @param request [::Google::Cloud::Dataplex::V1::UpdateZoneRequest, ::Hash]
804
+ # A request object representing the call parameters. Required. To specify no
805
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
806
+ # @param options [::Gapic::CallOptions, ::Hash]
807
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
808
+ #
809
+ # @overload update_zone(update_mask: nil, zone: nil, validate_only: nil)
810
+ # Pass arguments to `update_zone` via keyword arguments. Note that at
811
+ # least one keyword argument is required. To specify no parameters, or to keep all
812
+ # the default parameter values, pass an empty Hash as a request object (see above).
813
+ #
814
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
815
+ # Required. Mask of fields to update.
816
+ # @param zone [::Google::Cloud::Dataplex::V1::Zone, ::Hash]
817
+ # Required. Update description.
818
+ # Only fields specified in `update_mask` are updated.
819
+ # @param validate_only [::Boolean]
820
+ # Optional. Only validate the request, but do not perform mutations.
821
+ # The default is false.
822
+ # @yield [result, operation] Access the result along with the TransportOperation object
823
+ # @yieldparam result [::Gapic::Operation]
824
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
825
+ #
826
+ # @return [::Gapic::Operation]
827
+ #
828
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
829
+ def update_zone request, options = nil
830
+ raise ::ArgumentError, "request must be provided" if request.nil?
831
+
832
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::UpdateZoneRequest
833
+
834
+ # Converts hash and nil to an options object
835
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
836
+
837
+ # Customize the options with defaults
838
+ call_metadata = @config.rpcs.update_zone.metadata.to_h
839
+
840
+ # Set x-goog-api-client and x-goog-user-project headers
841
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
842
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
843
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
844
+ transports_version_send: [:rest]
845
+
846
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
847
+
848
+ options.apply_defaults timeout: @config.rpcs.update_zone.timeout,
849
+ metadata: call_metadata,
850
+ retry_policy: @config.rpcs.update_zone.retry_policy
851
+
852
+ options.apply_defaults timeout: @config.timeout,
853
+ metadata: @config.metadata,
854
+ retry_policy: @config.retry_policy
855
+
856
+ @dataplex_service_stub.update_zone request, options do |result, operation|
857
+ result = ::Gapic::Operation.new result, @operations_client, options: options
858
+ yield result, operation if block_given?
859
+ return result
860
+ end
861
+ rescue ::Gapic::Rest::Error => e
862
+ raise ::Google::Cloud::Error.from_error(e)
863
+ end
864
+
865
+ ##
866
+ # Deletes a zone resource. All assets within a zone must be deleted before
867
+ # the zone can be deleted.
868
+ #
869
+ # @overload delete_zone(request, options = nil)
870
+ # Pass arguments to `delete_zone` via a request object, either of type
871
+ # {::Google::Cloud::Dataplex::V1::DeleteZoneRequest} or an equivalent Hash.
872
+ #
873
+ # @param request [::Google::Cloud::Dataplex::V1::DeleteZoneRequest, ::Hash]
874
+ # A request object representing the call parameters. Required. To specify no
875
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
876
+ # @param options [::Gapic::CallOptions, ::Hash]
877
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
878
+ #
879
+ # @overload delete_zone(name: nil)
880
+ # Pass arguments to `delete_zone` via keyword arguments. Note that at
881
+ # least one keyword argument is required. To specify no parameters, or to keep all
882
+ # the default parameter values, pass an empty Hash as a request object (see above).
883
+ #
884
+ # @param name [::String]
885
+ # Required. The resource name of the zone:
886
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`.
887
+ # @yield [result, operation] Access the result along with the TransportOperation object
888
+ # @yieldparam result [::Gapic::Operation]
889
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
890
+ #
891
+ # @return [::Gapic::Operation]
892
+ #
893
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
894
+ def delete_zone request, options = nil
895
+ raise ::ArgumentError, "request must be provided" if request.nil?
896
+
897
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::DeleteZoneRequest
898
+
899
+ # Converts hash and nil to an options object
900
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
901
+
902
+ # Customize the options with defaults
903
+ call_metadata = @config.rpcs.delete_zone.metadata.to_h
904
+
905
+ # Set x-goog-api-client and x-goog-user-project headers
906
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
907
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
908
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
909
+ transports_version_send: [:rest]
910
+
911
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
912
+
913
+ options.apply_defaults timeout: @config.rpcs.delete_zone.timeout,
914
+ metadata: call_metadata,
915
+ retry_policy: @config.rpcs.delete_zone.retry_policy
916
+
917
+ options.apply_defaults timeout: @config.timeout,
918
+ metadata: @config.metadata,
919
+ retry_policy: @config.retry_policy
920
+
921
+ @dataplex_service_stub.delete_zone request, options do |result, operation|
922
+ result = ::Gapic::Operation.new result, @operations_client, options: options
923
+ yield result, operation if block_given?
924
+ return result
925
+ end
926
+ rescue ::Gapic::Rest::Error => e
927
+ raise ::Google::Cloud::Error.from_error(e)
928
+ end
929
+
930
+ ##
931
+ # Lists zone resources in a lake.
932
+ #
933
+ # @overload list_zones(request, options = nil)
934
+ # Pass arguments to `list_zones` via a request object, either of type
935
+ # {::Google::Cloud::Dataplex::V1::ListZonesRequest} or an equivalent Hash.
936
+ #
937
+ # @param request [::Google::Cloud::Dataplex::V1::ListZonesRequest, ::Hash]
938
+ # A request object representing the call parameters. Required. To specify no
939
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
940
+ # @param options [::Gapic::CallOptions, ::Hash]
941
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
942
+ #
943
+ # @overload list_zones(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
944
+ # Pass arguments to `list_zones` via keyword arguments. Note that at
945
+ # least one keyword argument is required. To specify no parameters, or to keep all
946
+ # the default parameter values, pass an empty Hash as a request object (see above).
947
+ #
948
+ # @param parent [::String]
949
+ # Required. The resource name of the parent lake:
950
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
951
+ # @param page_size [::Integer]
952
+ # Optional. Maximum number of zones to return. The service may return fewer
953
+ # than this value. If unspecified, at most 10 zones will be returned. The
954
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
955
+ # @param page_token [::String]
956
+ # Optional. Page token received from a previous `ListZones` call. Provide
957
+ # this to retrieve the subsequent page. When paginating, all other parameters
958
+ # provided to `ListZones` must match the call that provided the page token.
959
+ # @param filter [::String]
960
+ # Optional. Filter request.
961
+ # @param order_by [::String]
962
+ # Optional. Order by fields for the result.
963
+ # @yield [result, operation] Access the result along with the TransportOperation object
964
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Zone>]
965
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
966
+ #
967
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Zone>]
968
+ #
969
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
970
+ def list_zones request, options = nil
971
+ raise ::ArgumentError, "request must be provided" if request.nil?
972
+
973
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListZonesRequest
974
+
975
+ # Converts hash and nil to an options object
976
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
977
+
978
+ # Customize the options with defaults
979
+ call_metadata = @config.rpcs.list_zones.metadata.to_h
980
+
981
+ # Set x-goog-api-client and x-goog-user-project headers
982
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
983
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
984
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
985
+ transports_version_send: [:rest]
986
+
987
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
988
+
989
+ options.apply_defaults timeout: @config.rpcs.list_zones.timeout,
990
+ metadata: call_metadata,
991
+ retry_policy: @config.rpcs.list_zones.retry_policy
992
+
993
+ options.apply_defaults timeout: @config.timeout,
994
+ metadata: @config.metadata,
995
+ retry_policy: @config.retry_policy
996
+
997
+ @dataplex_service_stub.list_zones request, options do |result, operation|
998
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_zones, "zones", request, result, options
999
+ yield result, operation if block_given?
1000
+ return result
1001
+ end
1002
+ rescue ::Gapic::Rest::Error => e
1003
+ raise ::Google::Cloud::Error.from_error(e)
1004
+ end
1005
+
1006
+ ##
1007
+ # Retrieves a zone resource.
1008
+ #
1009
+ # @overload get_zone(request, options = nil)
1010
+ # Pass arguments to `get_zone` via a request object, either of type
1011
+ # {::Google::Cloud::Dataplex::V1::GetZoneRequest} or an equivalent Hash.
1012
+ #
1013
+ # @param request [::Google::Cloud::Dataplex::V1::GetZoneRequest, ::Hash]
1014
+ # A request object representing the call parameters. Required. To specify no
1015
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1016
+ # @param options [::Gapic::CallOptions, ::Hash]
1017
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1018
+ #
1019
+ # @overload get_zone(name: nil)
1020
+ # Pass arguments to `get_zone` via keyword arguments. Note that at
1021
+ # least one keyword argument is required. To specify no parameters, or to keep all
1022
+ # the default parameter values, pass an empty Hash as a request object (see above).
1023
+ #
1024
+ # @param name [::String]
1025
+ # Required. The resource name of the zone:
1026
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`.
1027
+ # @yield [result, operation] Access the result along with the TransportOperation object
1028
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Zone]
1029
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1030
+ #
1031
+ # @return [::Google::Cloud::Dataplex::V1::Zone]
1032
+ #
1033
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1034
+ def get_zone request, options = nil
1035
+ raise ::ArgumentError, "request must be provided" if request.nil?
1036
+
1037
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetZoneRequest
1038
+
1039
+ # Converts hash and nil to an options object
1040
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1041
+
1042
+ # Customize the options with defaults
1043
+ call_metadata = @config.rpcs.get_zone.metadata.to_h
1044
+
1045
+ # Set x-goog-api-client and x-goog-user-project headers
1046
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1047
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1048
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1049
+ transports_version_send: [:rest]
1050
+
1051
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1052
+
1053
+ options.apply_defaults timeout: @config.rpcs.get_zone.timeout,
1054
+ metadata: call_metadata,
1055
+ retry_policy: @config.rpcs.get_zone.retry_policy
1056
+
1057
+ options.apply_defaults timeout: @config.timeout,
1058
+ metadata: @config.metadata,
1059
+ retry_policy: @config.retry_policy
1060
+
1061
+ @dataplex_service_stub.get_zone request, options do |result, operation|
1062
+ yield result, operation if block_given?
1063
+ return result
1064
+ end
1065
+ rescue ::Gapic::Rest::Error => e
1066
+ raise ::Google::Cloud::Error.from_error(e)
1067
+ end
1068
+
1069
+ ##
1070
+ # Lists action resources in a zone.
1071
+ #
1072
+ # @overload list_zone_actions(request, options = nil)
1073
+ # Pass arguments to `list_zone_actions` via a request object, either of type
1074
+ # {::Google::Cloud::Dataplex::V1::ListZoneActionsRequest} or an equivalent Hash.
1075
+ #
1076
+ # @param request [::Google::Cloud::Dataplex::V1::ListZoneActionsRequest, ::Hash]
1077
+ # A request object representing the call parameters. Required. To specify no
1078
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1079
+ # @param options [::Gapic::CallOptions, ::Hash]
1080
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1081
+ #
1082
+ # @overload list_zone_actions(parent: nil, page_size: nil, page_token: nil)
1083
+ # Pass arguments to `list_zone_actions` via keyword arguments. Note that at
1084
+ # least one keyword argument is required. To specify no parameters, or to keep all
1085
+ # the default parameter values, pass an empty Hash as a request object (see above).
1086
+ #
1087
+ # @param parent [::String]
1088
+ # Required. The resource name of the parent zone:
1089
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`.
1090
+ # @param page_size [::Integer]
1091
+ # Optional. Maximum number of actions to return. The service may return fewer
1092
+ # than this value. If unspecified, at most 10 actions will be returned. The
1093
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
1094
+ # @param page_token [::String]
1095
+ # Optional. Page token received from a previous `ListZoneActions` call.
1096
+ # Provide this to retrieve the subsequent page. When paginating, all other
1097
+ # parameters provided to `ListZoneActions` must match the call that provided
1098
+ # the page token.
1099
+ # @yield [result, operation] Access the result along with the TransportOperation object
1100
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
1101
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1102
+ #
1103
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
1104
+ #
1105
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1106
+ def list_zone_actions request, options = nil
1107
+ raise ::ArgumentError, "request must be provided" if request.nil?
1108
+
1109
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListZoneActionsRequest
1110
+
1111
+ # Converts hash and nil to an options object
1112
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1113
+
1114
+ # Customize the options with defaults
1115
+ call_metadata = @config.rpcs.list_zone_actions.metadata.to_h
1116
+
1117
+ # Set x-goog-api-client and x-goog-user-project headers
1118
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1119
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1120
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1121
+ transports_version_send: [:rest]
1122
+
1123
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1124
+
1125
+ options.apply_defaults timeout: @config.rpcs.list_zone_actions.timeout,
1126
+ metadata: call_metadata,
1127
+ retry_policy: @config.rpcs.list_zone_actions.retry_policy
1128
+
1129
+ options.apply_defaults timeout: @config.timeout,
1130
+ metadata: @config.metadata,
1131
+ retry_policy: @config.retry_policy
1132
+
1133
+ @dataplex_service_stub.list_zone_actions request, options do |result, operation|
1134
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_zone_actions, "actions", request, result, options
1135
+ yield result, operation if block_given?
1136
+ return result
1137
+ end
1138
+ rescue ::Gapic::Rest::Error => e
1139
+ raise ::Google::Cloud::Error.from_error(e)
1140
+ end
1141
+
1142
+ ##
1143
+ # Creates an asset resource.
1144
+ #
1145
+ # @overload create_asset(request, options = nil)
1146
+ # Pass arguments to `create_asset` via a request object, either of type
1147
+ # {::Google::Cloud::Dataplex::V1::CreateAssetRequest} or an equivalent Hash.
1148
+ #
1149
+ # @param request [::Google::Cloud::Dataplex::V1::CreateAssetRequest, ::Hash]
1150
+ # A request object representing the call parameters. Required. To specify no
1151
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1152
+ # @param options [::Gapic::CallOptions, ::Hash]
1153
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1154
+ #
1155
+ # @overload create_asset(parent: nil, asset_id: nil, asset: nil, validate_only: nil)
1156
+ # Pass arguments to `create_asset` via keyword arguments. Note that at
1157
+ # least one keyword argument is required. To specify no parameters, or to keep all
1158
+ # the default parameter values, pass an empty Hash as a request object (see above).
1159
+ #
1160
+ # @param parent [::String]
1161
+ # Required. The resource name of the parent zone:
1162
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`.
1163
+ # @param asset_id [::String]
1164
+ # Required. Asset identifier.
1165
+ # This ID will be used to generate names such as table names when publishing
1166
+ # metadata to Hive Metastore and BigQuery.
1167
+ # * Must contain only lowercase letters, numbers and hyphens.
1168
+ # * Must start with a letter.
1169
+ # * Must end with a number or a letter.
1170
+ # * Must be between 1-63 characters.
1171
+ # * Must be unique within the zone.
1172
+ # @param asset [::Google::Cloud::Dataplex::V1::Asset, ::Hash]
1173
+ # Required. Asset resource.
1174
+ # @param validate_only [::Boolean]
1175
+ # Optional. Only validate the request, but do not perform mutations.
1176
+ # The default is false.
1177
+ # @yield [result, operation] Access the result along with the TransportOperation object
1178
+ # @yieldparam result [::Gapic::Operation]
1179
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1180
+ #
1181
+ # @return [::Gapic::Operation]
1182
+ #
1183
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1184
+ def create_asset request, options = nil
1185
+ raise ::ArgumentError, "request must be provided" if request.nil?
1186
+
1187
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CreateAssetRequest
1188
+
1189
+ # Converts hash and nil to an options object
1190
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1191
+
1192
+ # Customize the options with defaults
1193
+ call_metadata = @config.rpcs.create_asset.metadata.to_h
1194
+
1195
+ # Set x-goog-api-client and x-goog-user-project headers
1196
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1197
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1198
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1199
+ transports_version_send: [:rest]
1200
+
1201
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1202
+
1203
+ options.apply_defaults timeout: @config.rpcs.create_asset.timeout,
1204
+ metadata: call_metadata,
1205
+ retry_policy: @config.rpcs.create_asset.retry_policy
1206
+
1207
+ options.apply_defaults timeout: @config.timeout,
1208
+ metadata: @config.metadata,
1209
+ retry_policy: @config.retry_policy
1210
+
1211
+ @dataplex_service_stub.create_asset request, options do |result, operation|
1212
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1213
+ yield result, operation if block_given?
1214
+ return result
1215
+ end
1216
+ rescue ::Gapic::Rest::Error => e
1217
+ raise ::Google::Cloud::Error.from_error(e)
1218
+ end
1219
+
1220
+ ##
1221
+ # Updates an asset resource.
1222
+ #
1223
+ # @overload update_asset(request, options = nil)
1224
+ # Pass arguments to `update_asset` via a request object, either of type
1225
+ # {::Google::Cloud::Dataplex::V1::UpdateAssetRequest} or an equivalent Hash.
1226
+ #
1227
+ # @param request [::Google::Cloud::Dataplex::V1::UpdateAssetRequest, ::Hash]
1228
+ # A request object representing the call parameters. Required. To specify no
1229
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1230
+ # @param options [::Gapic::CallOptions, ::Hash]
1231
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1232
+ #
1233
+ # @overload update_asset(update_mask: nil, asset: nil, validate_only: nil)
1234
+ # Pass arguments to `update_asset` via keyword arguments. Note that at
1235
+ # least one keyword argument is required. To specify no parameters, or to keep all
1236
+ # the default parameter values, pass an empty Hash as a request object (see above).
1237
+ #
1238
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1239
+ # Required. Mask of fields to update.
1240
+ # @param asset [::Google::Cloud::Dataplex::V1::Asset, ::Hash]
1241
+ # Required. Update description.
1242
+ # Only fields specified in `update_mask` are updated.
1243
+ # @param validate_only [::Boolean]
1244
+ # Optional. Only validate the request, but do not perform mutations.
1245
+ # The default is false.
1246
+ # @yield [result, operation] Access the result along with the TransportOperation object
1247
+ # @yieldparam result [::Gapic::Operation]
1248
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1249
+ #
1250
+ # @return [::Gapic::Operation]
1251
+ #
1252
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1253
+ def update_asset request, options = nil
1254
+ raise ::ArgumentError, "request must be provided" if request.nil?
1255
+
1256
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::UpdateAssetRequest
1257
+
1258
+ # Converts hash and nil to an options object
1259
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1260
+
1261
+ # Customize the options with defaults
1262
+ call_metadata = @config.rpcs.update_asset.metadata.to_h
1263
+
1264
+ # Set x-goog-api-client and x-goog-user-project headers
1265
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1266
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1267
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1268
+ transports_version_send: [:rest]
1269
+
1270
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1271
+
1272
+ options.apply_defaults timeout: @config.rpcs.update_asset.timeout,
1273
+ metadata: call_metadata,
1274
+ retry_policy: @config.rpcs.update_asset.retry_policy
1275
+
1276
+ options.apply_defaults timeout: @config.timeout,
1277
+ metadata: @config.metadata,
1278
+ retry_policy: @config.retry_policy
1279
+
1280
+ @dataplex_service_stub.update_asset request, options do |result, operation|
1281
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1282
+ yield result, operation if block_given?
1283
+ return result
1284
+ end
1285
+ rescue ::Gapic::Rest::Error => e
1286
+ raise ::Google::Cloud::Error.from_error(e)
1287
+ end
1288
+
1289
+ ##
1290
+ # Deletes an asset resource. The referenced storage resource is detached
1291
+ # (default) or deleted based on the associated Lifecycle policy.
1292
+ #
1293
+ # @overload delete_asset(request, options = nil)
1294
+ # Pass arguments to `delete_asset` via a request object, either of type
1295
+ # {::Google::Cloud::Dataplex::V1::DeleteAssetRequest} or an equivalent Hash.
1296
+ #
1297
+ # @param request [::Google::Cloud::Dataplex::V1::DeleteAssetRequest, ::Hash]
1298
+ # A request object representing the call parameters. Required. To specify no
1299
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1300
+ # @param options [::Gapic::CallOptions, ::Hash]
1301
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1302
+ #
1303
+ # @overload delete_asset(name: nil)
1304
+ # Pass arguments to `delete_asset` via keyword arguments. Note that at
1305
+ # least one keyword argument is required. To specify no parameters, or to keep all
1306
+ # the default parameter values, pass an empty Hash as a request object (see above).
1307
+ #
1308
+ # @param name [::String]
1309
+ # Required. The resource name of the asset:
1310
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`.
1311
+ # @yield [result, operation] Access the result along with the TransportOperation object
1312
+ # @yieldparam result [::Gapic::Operation]
1313
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1314
+ #
1315
+ # @return [::Gapic::Operation]
1316
+ #
1317
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1318
+ def delete_asset request, options = nil
1319
+ raise ::ArgumentError, "request must be provided" if request.nil?
1320
+
1321
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::DeleteAssetRequest
1322
+
1323
+ # Converts hash and nil to an options object
1324
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1325
+
1326
+ # Customize the options with defaults
1327
+ call_metadata = @config.rpcs.delete_asset.metadata.to_h
1328
+
1329
+ # Set x-goog-api-client and x-goog-user-project headers
1330
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1331
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1332
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1333
+ transports_version_send: [:rest]
1334
+
1335
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1336
+
1337
+ options.apply_defaults timeout: @config.rpcs.delete_asset.timeout,
1338
+ metadata: call_metadata,
1339
+ retry_policy: @config.rpcs.delete_asset.retry_policy
1340
+
1341
+ options.apply_defaults timeout: @config.timeout,
1342
+ metadata: @config.metadata,
1343
+ retry_policy: @config.retry_policy
1344
+
1345
+ @dataplex_service_stub.delete_asset request, options do |result, operation|
1346
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1347
+ yield result, operation if block_given?
1348
+ return result
1349
+ end
1350
+ rescue ::Gapic::Rest::Error => e
1351
+ raise ::Google::Cloud::Error.from_error(e)
1352
+ end
1353
+
1354
+ ##
1355
+ # Lists asset resources in a zone.
1356
+ #
1357
+ # @overload list_assets(request, options = nil)
1358
+ # Pass arguments to `list_assets` via a request object, either of type
1359
+ # {::Google::Cloud::Dataplex::V1::ListAssetsRequest} or an equivalent Hash.
1360
+ #
1361
+ # @param request [::Google::Cloud::Dataplex::V1::ListAssetsRequest, ::Hash]
1362
+ # A request object representing the call parameters. Required. To specify no
1363
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1364
+ # @param options [::Gapic::CallOptions, ::Hash]
1365
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1366
+ #
1367
+ # @overload list_assets(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
1368
+ # Pass arguments to `list_assets` via keyword arguments. Note that at
1369
+ # least one keyword argument is required. To specify no parameters, or to keep all
1370
+ # the default parameter values, pass an empty Hash as a request object (see above).
1371
+ #
1372
+ # @param parent [::String]
1373
+ # Required. The resource name of the parent zone:
1374
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`.
1375
+ # @param page_size [::Integer]
1376
+ # Optional. Maximum number of asset to return. The service may return fewer
1377
+ # than this value. If unspecified, at most 10 assets will be returned. The
1378
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
1379
+ # @param page_token [::String]
1380
+ # Optional. Page token received from a previous `ListAssets` call. Provide
1381
+ # this to retrieve the subsequent page. When paginating, all other parameters
1382
+ # provided to `ListAssets` must match the call that provided the page
1383
+ # token.
1384
+ # @param filter [::String]
1385
+ # Optional. Filter request.
1386
+ # @param order_by [::String]
1387
+ # Optional. Order by fields for the result.
1388
+ # @yield [result, operation] Access the result along with the TransportOperation object
1389
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Asset>]
1390
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1391
+ #
1392
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Asset>]
1393
+ #
1394
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1395
+ def list_assets request, options = nil
1396
+ raise ::ArgumentError, "request must be provided" if request.nil?
1397
+
1398
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListAssetsRequest
1399
+
1400
+ # Converts hash and nil to an options object
1401
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1402
+
1403
+ # Customize the options with defaults
1404
+ call_metadata = @config.rpcs.list_assets.metadata.to_h
1405
+
1406
+ # Set x-goog-api-client and x-goog-user-project headers
1407
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1408
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1409
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1410
+ transports_version_send: [:rest]
1411
+
1412
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1413
+
1414
+ options.apply_defaults timeout: @config.rpcs.list_assets.timeout,
1415
+ metadata: call_metadata,
1416
+ retry_policy: @config.rpcs.list_assets.retry_policy
1417
+
1418
+ options.apply_defaults timeout: @config.timeout,
1419
+ metadata: @config.metadata,
1420
+ retry_policy: @config.retry_policy
1421
+
1422
+ @dataplex_service_stub.list_assets request, options do |result, operation|
1423
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_assets, "assets", request, result, options
1424
+ yield result, operation if block_given?
1425
+ return result
1426
+ end
1427
+ rescue ::Gapic::Rest::Error => e
1428
+ raise ::Google::Cloud::Error.from_error(e)
1429
+ end
1430
+
1431
+ ##
1432
+ # Retrieves an asset resource.
1433
+ #
1434
+ # @overload get_asset(request, options = nil)
1435
+ # Pass arguments to `get_asset` via a request object, either of type
1436
+ # {::Google::Cloud::Dataplex::V1::GetAssetRequest} or an equivalent Hash.
1437
+ #
1438
+ # @param request [::Google::Cloud::Dataplex::V1::GetAssetRequest, ::Hash]
1439
+ # A request object representing the call parameters. Required. To specify no
1440
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1441
+ # @param options [::Gapic::CallOptions, ::Hash]
1442
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1443
+ #
1444
+ # @overload get_asset(name: nil)
1445
+ # Pass arguments to `get_asset` via keyword arguments. Note that at
1446
+ # least one keyword argument is required. To specify no parameters, or to keep all
1447
+ # the default parameter values, pass an empty Hash as a request object (see above).
1448
+ #
1449
+ # @param name [::String]
1450
+ # Required. The resource name of the asset:
1451
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`.
1452
+ # @yield [result, operation] Access the result along with the TransportOperation object
1453
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Asset]
1454
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1455
+ #
1456
+ # @return [::Google::Cloud::Dataplex::V1::Asset]
1457
+ #
1458
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1459
+ def get_asset request, options = nil
1460
+ raise ::ArgumentError, "request must be provided" if request.nil?
1461
+
1462
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetAssetRequest
1463
+
1464
+ # Converts hash and nil to an options object
1465
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1466
+
1467
+ # Customize the options with defaults
1468
+ call_metadata = @config.rpcs.get_asset.metadata.to_h
1469
+
1470
+ # Set x-goog-api-client and x-goog-user-project headers
1471
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1472
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1473
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1474
+ transports_version_send: [:rest]
1475
+
1476
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1477
+
1478
+ options.apply_defaults timeout: @config.rpcs.get_asset.timeout,
1479
+ metadata: call_metadata,
1480
+ retry_policy: @config.rpcs.get_asset.retry_policy
1481
+
1482
+ options.apply_defaults timeout: @config.timeout,
1483
+ metadata: @config.metadata,
1484
+ retry_policy: @config.retry_policy
1485
+
1486
+ @dataplex_service_stub.get_asset request, options do |result, operation|
1487
+ yield result, operation if block_given?
1488
+ return result
1489
+ end
1490
+ rescue ::Gapic::Rest::Error => e
1491
+ raise ::Google::Cloud::Error.from_error(e)
1492
+ end
1493
+
1494
+ ##
1495
+ # Lists action resources in an asset.
1496
+ #
1497
+ # @overload list_asset_actions(request, options = nil)
1498
+ # Pass arguments to `list_asset_actions` via a request object, either of type
1499
+ # {::Google::Cloud::Dataplex::V1::ListAssetActionsRequest} or an equivalent Hash.
1500
+ #
1501
+ # @param request [::Google::Cloud::Dataplex::V1::ListAssetActionsRequest, ::Hash]
1502
+ # A request object representing the call parameters. Required. To specify no
1503
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1504
+ # @param options [::Gapic::CallOptions, ::Hash]
1505
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1506
+ #
1507
+ # @overload list_asset_actions(parent: nil, page_size: nil, page_token: nil)
1508
+ # Pass arguments to `list_asset_actions` via keyword arguments. Note that at
1509
+ # least one keyword argument is required. To specify no parameters, or to keep all
1510
+ # the default parameter values, pass an empty Hash as a request object (see above).
1511
+ #
1512
+ # @param parent [::String]
1513
+ # Required. The resource name of the parent asset:
1514
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`.
1515
+ # @param page_size [::Integer]
1516
+ # Optional. Maximum number of actions to return. The service may return fewer
1517
+ # than this value. If unspecified, at most 10 actions will be returned. The
1518
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
1519
+ # @param page_token [::String]
1520
+ # Optional. Page token received from a previous `ListAssetActions` call.
1521
+ # Provide this to retrieve the subsequent page. When paginating, all other
1522
+ # parameters provided to `ListAssetActions` must match the call that provided
1523
+ # the page token.
1524
+ # @yield [result, operation] Access the result along with the TransportOperation object
1525
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
1526
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1527
+ #
1528
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Action>]
1529
+ #
1530
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1531
+ def list_asset_actions request, options = nil
1532
+ raise ::ArgumentError, "request must be provided" if request.nil?
1533
+
1534
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListAssetActionsRequest
1535
+
1536
+ # Converts hash and nil to an options object
1537
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1538
+
1539
+ # Customize the options with defaults
1540
+ call_metadata = @config.rpcs.list_asset_actions.metadata.to_h
1541
+
1542
+ # Set x-goog-api-client and x-goog-user-project headers
1543
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1544
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1545
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1546
+ transports_version_send: [:rest]
1547
+
1548
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1549
+
1550
+ options.apply_defaults timeout: @config.rpcs.list_asset_actions.timeout,
1551
+ metadata: call_metadata,
1552
+ retry_policy: @config.rpcs.list_asset_actions.retry_policy
1553
+
1554
+ options.apply_defaults timeout: @config.timeout,
1555
+ metadata: @config.metadata,
1556
+ retry_policy: @config.retry_policy
1557
+
1558
+ @dataplex_service_stub.list_asset_actions request, options do |result, operation|
1559
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_asset_actions, "actions", request, result, options
1560
+ yield result, operation if block_given?
1561
+ return result
1562
+ end
1563
+ rescue ::Gapic::Rest::Error => e
1564
+ raise ::Google::Cloud::Error.from_error(e)
1565
+ end
1566
+
1567
+ ##
1568
+ # Creates a task resource within a lake.
1569
+ #
1570
+ # @overload create_task(request, options = nil)
1571
+ # Pass arguments to `create_task` via a request object, either of type
1572
+ # {::Google::Cloud::Dataplex::V1::CreateTaskRequest} or an equivalent Hash.
1573
+ #
1574
+ # @param request [::Google::Cloud::Dataplex::V1::CreateTaskRequest, ::Hash]
1575
+ # A request object representing the call parameters. Required. To specify no
1576
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1577
+ # @param options [::Gapic::CallOptions, ::Hash]
1578
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1579
+ #
1580
+ # @overload create_task(parent: nil, task_id: nil, task: nil, validate_only: nil)
1581
+ # Pass arguments to `create_task` via keyword arguments. Note that at
1582
+ # least one keyword argument is required. To specify no parameters, or to keep all
1583
+ # the default parameter values, pass an empty Hash as a request object (see above).
1584
+ #
1585
+ # @param parent [::String]
1586
+ # Required. The resource name of the parent lake:
1587
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
1588
+ # @param task_id [::String]
1589
+ # Required. Task identifier.
1590
+ # @param task [::Google::Cloud::Dataplex::V1::Task, ::Hash]
1591
+ # Required. Task resource.
1592
+ # @param validate_only [::Boolean]
1593
+ # Optional. Only validate the request, but do not perform mutations.
1594
+ # The default is false.
1595
+ # @yield [result, operation] Access the result along with the TransportOperation object
1596
+ # @yieldparam result [::Gapic::Operation]
1597
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1598
+ #
1599
+ # @return [::Gapic::Operation]
1600
+ #
1601
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1602
+ def create_task request, options = nil
1603
+ raise ::ArgumentError, "request must be provided" if request.nil?
1604
+
1605
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CreateTaskRequest
1606
+
1607
+ # Converts hash and nil to an options object
1608
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1609
+
1610
+ # Customize the options with defaults
1611
+ call_metadata = @config.rpcs.create_task.metadata.to_h
1612
+
1613
+ # Set x-goog-api-client and x-goog-user-project headers
1614
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1615
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1616
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1617
+ transports_version_send: [:rest]
1618
+
1619
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1620
+
1621
+ options.apply_defaults timeout: @config.rpcs.create_task.timeout,
1622
+ metadata: call_metadata,
1623
+ retry_policy: @config.rpcs.create_task.retry_policy
1624
+
1625
+ options.apply_defaults timeout: @config.timeout,
1626
+ metadata: @config.metadata,
1627
+ retry_policy: @config.retry_policy
1628
+
1629
+ @dataplex_service_stub.create_task request, options do |result, operation|
1630
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1631
+ yield result, operation if block_given?
1632
+ return result
1633
+ end
1634
+ rescue ::Gapic::Rest::Error => e
1635
+ raise ::Google::Cloud::Error.from_error(e)
1636
+ end
1637
+
1638
+ ##
1639
+ # Update the task resource.
1640
+ #
1641
+ # @overload update_task(request, options = nil)
1642
+ # Pass arguments to `update_task` via a request object, either of type
1643
+ # {::Google::Cloud::Dataplex::V1::UpdateTaskRequest} or an equivalent Hash.
1644
+ #
1645
+ # @param request [::Google::Cloud::Dataplex::V1::UpdateTaskRequest, ::Hash]
1646
+ # A request object representing the call parameters. Required. To specify no
1647
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1648
+ # @param options [::Gapic::CallOptions, ::Hash]
1649
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1650
+ #
1651
+ # @overload update_task(update_mask: nil, task: nil, validate_only: nil)
1652
+ # Pass arguments to `update_task` via keyword arguments. Note that at
1653
+ # least one keyword argument is required. To specify no parameters, or to keep all
1654
+ # the default parameter values, pass an empty Hash as a request object (see above).
1655
+ #
1656
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
1657
+ # Required. Mask of fields to update.
1658
+ # @param task [::Google::Cloud::Dataplex::V1::Task, ::Hash]
1659
+ # Required. Update description.
1660
+ # Only fields specified in `update_mask` are updated.
1661
+ # @param validate_only [::Boolean]
1662
+ # Optional. Only validate the request, but do not perform mutations.
1663
+ # The default is false.
1664
+ # @yield [result, operation] Access the result along with the TransportOperation object
1665
+ # @yieldparam result [::Gapic::Operation]
1666
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1667
+ #
1668
+ # @return [::Gapic::Operation]
1669
+ #
1670
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1671
+ def update_task request, options = nil
1672
+ raise ::ArgumentError, "request must be provided" if request.nil?
1673
+
1674
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::UpdateTaskRequest
1675
+
1676
+ # Converts hash and nil to an options object
1677
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1678
+
1679
+ # Customize the options with defaults
1680
+ call_metadata = @config.rpcs.update_task.metadata.to_h
1681
+
1682
+ # Set x-goog-api-client and x-goog-user-project headers
1683
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1684
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1685
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1686
+ transports_version_send: [:rest]
1687
+
1688
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1689
+
1690
+ options.apply_defaults timeout: @config.rpcs.update_task.timeout,
1691
+ metadata: call_metadata,
1692
+ retry_policy: @config.rpcs.update_task.retry_policy
1693
+
1694
+ options.apply_defaults timeout: @config.timeout,
1695
+ metadata: @config.metadata,
1696
+ retry_policy: @config.retry_policy
1697
+
1698
+ @dataplex_service_stub.update_task request, options do |result, operation|
1699
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1700
+ yield result, operation if block_given?
1701
+ return result
1702
+ end
1703
+ rescue ::Gapic::Rest::Error => e
1704
+ raise ::Google::Cloud::Error.from_error(e)
1705
+ end
1706
+
1707
+ ##
1708
+ # Delete the task resource.
1709
+ #
1710
+ # @overload delete_task(request, options = nil)
1711
+ # Pass arguments to `delete_task` via a request object, either of type
1712
+ # {::Google::Cloud::Dataplex::V1::DeleteTaskRequest} or an equivalent Hash.
1713
+ #
1714
+ # @param request [::Google::Cloud::Dataplex::V1::DeleteTaskRequest, ::Hash]
1715
+ # A request object representing the call parameters. Required. To specify no
1716
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1717
+ # @param options [::Gapic::CallOptions, ::Hash]
1718
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1719
+ #
1720
+ # @overload delete_task(name: nil)
1721
+ # Pass arguments to `delete_task` via keyword arguments. Note that at
1722
+ # least one keyword argument is required. To specify no parameters, or to keep all
1723
+ # the default parameter values, pass an empty Hash as a request object (see above).
1724
+ #
1725
+ # @param name [::String]
1726
+ # Required. The resource name of the task:
1727
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/task/{task_id}`.
1728
+ # @yield [result, operation] Access the result along with the TransportOperation object
1729
+ # @yieldparam result [::Gapic::Operation]
1730
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1731
+ #
1732
+ # @return [::Gapic::Operation]
1733
+ #
1734
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1735
+ def delete_task request, options = nil
1736
+ raise ::ArgumentError, "request must be provided" if request.nil?
1737
+
1738
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::DeleteTaskRequest
1739
+
1740
+ # Converts hash and nil to an options object
1741
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1742
+
1743
+ # Customize the options with defaults
1744
+ call_metadata = @config.rpcs.delete_task.metadata.to_h
1745
+
1746
+ # Set x-goog-api-client and x-goog-user-project headers
1747
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1748
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1749
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1750
+ transports_version_send: [:rest]
1751
+
1752
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1753
+
1754
+ options.apply_defaults timeout: @config.rpcs.delete_task.timeout,
1755
+ metadata: call_metadata,
1756
+ retry_policy: @config.rpcs.delete_task.retry_policy
1757
+
1758
+ options.apply_defaults timeout: @config.timeout,
1759
+ metadata: @config.metadata,
1760
+ retry_policy: @config.retry_policy
1761
+
1762
+ @dataplex_service_stub.delete_task request, options do |result, operation|
1763
+ result = ::Gapic::Operation.new result, @operations_client, options: options
1764
+ yield result, operation if block_given?
1765
+ return result
1766
+ end
1767
+ rescue ::Gapic::Rest::Error => e
1768
+ raise ::Google::Cloud::Error.from_error(e)
1769
+ end
1770
+
1771
+ ##
1772
+ # Lists tasks under the given lake.
1773
+ #
1774
+ # @overload list_tasks(request, options = nil)
1775
+ # Pass arguments to `list_tasks` via a request object, either of type
1776
+ # {::Google::Cloud::Dataplex::V1::ListTasksRequest} or an equivalent Hash.
1777
+ #
1778
+ # @param request [::Google::Cloud::Dataplex::V1::ListTasksRequest, ::Hash]
1779
+ # A request object representing the call parameters. Required. To specify no
1780
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1781
+ # @param options [::Gapic::CallOptions, ::Hash]
1782
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1783
+ #
1784
+ # @overload list_tasks(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
1785
+ # Pass arguments to `list_tasks` via keyword arguments. Note that at
1786
+ # least one keyword argument is required. To specify no parameters, or to keep all
1787
+ # the default parameter values, pass an empty Hash as a request object (see above).
1788
+ #
1789
+ # @param parent [::String]
1790
+ # Required. The resource name of the parent lake:
1791
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`.
1792
+ # @param page_size [::Integer]
1793
+ # Optional. Maximum number of tasks to return. The service may return fewer
1794
+ # than this value. If unspecified, at most 10 tasks will be returned. The
1795
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
1796
+ # @param page_token [::String]
1797
+ # Optional. Page token received from a previous `ListZones` call. Provide
1798
+ # this to retrieve the subsequent page. When paginating, all other parameters
1799
+ # provided to `ListZones` must match the call that provided the page token.
1800
+ # @param filter [::String]
1801
+ # Optional. Filter request.
1802
+ # @param order_by [::String]
1803
+ # Optional. Order by fields for the result.
1804
+ # @yield [result, operation] Access the result along with the TransportOperation object
1805
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::ListTasksResponse]
1806
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1807
+ #
1808
+ # @return [::Google::Cloud::Dataplex::V1::ListTasksResponse]
1809
+ #
1810
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1811
+ def list_tasks request, options = nil
1812
+ raise ::ArgumentError, "request must be provided" if request.nil?
1813
+
1814
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListTasksRequest
1815
+
1816
+ # Converts hash and nil to an options object
1817
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1818
+
1819
+ # Customize the options with defaults
1820
+ call_metadata = @config.rpcs.list_tasks.metadata.to_h
1821
+
1822
+ # Set x-goog-api-client and x-goog-user-project headers
1823
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1824
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1825
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1826
+ transports_version_send: [:rest]
1827
+
1828
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1829
+
1830
+ options.apply_defaults timeout: @config.rpcs.list_tasks.timeout,
1831
+ metadata: call_metadata,
1832
+ retry_policy: @config.rpcs.list_tasks.retry_policy
1833
+
1834
+ options.apply_defaults timeout: @config.timeout,
1835
+ metadata: @config.metadata,
1836
+ retry_policy: @config.retry_policy
1837
+
1838
+ @dataplex_service_stub.list_tasks request, options do |result, operation|
1839
+ yield result, operation if block_given?
1840
+ return result
1841
+ end
1842
+ rescue ::Gapic::Rest::Error => e
1843
+ raise ::Google::Cloud::Error.from_error(e)
1844
+ end
1845
+
1846
+ ##
1847
+ # Get task resource.
1848
+ #
1849
+ # @overload get_task(request, options = nil)
1850
+ # Pass arguments to `get_task` via a request object, either of type
1851
+ # {::Google::Cloud::Dataplex::V1::GetTaskRequest} or an equivalent Hash.
1852
+ #
1853
+ # @param request [::Google::Cloud::Dataplex::V1::GetTaskRequest, ::Hash]
1854
+ # A request object representing the call parameters. Required. To specify no
1855
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1856
+ # @param options [::Gapic::CallOptions, ::Hash]
1857
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1858
+ #
1859
+ # @overload get_task(name: nil)
1860
+ # Pass arguments to `get_task` via keyword arguments. Note that at
1861
+ # least one keyword argument is required. To specify no parameters, or to keep all
1862
+ # the default parameter values, pass an empty Hash as a request object (see above).
1863
+ #
1864
+ # @param name [::String]
1865
+ # Required. The resource name of the task:
1866
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{tasks_id}`.
1867
+ # @yield [result, operation] Access the result along with the TransportOperation object
1868
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Task]
1869
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1870
+ #
1871
+ # @return [::Google::Cloud::Dataplex::V1::Task]
1872
+ #
1873
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1874
+ def get_task request, options = nil
1875
+ raise ::ArgumentError, "request must be provided" if request.nil?
1876
+
1877
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetTaskRequest
1878
+
1879
+ # Converts hash and nil to an options object
1880
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1881
+
1882
+ # Customize the options with defaults
1883
+ call_metadata = @config.rpcs.get_task.metadata.to_h
1884
+
1885
+ # Set x-goog-api-client and x-goog-user-project headers
1886
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1887
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1888
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1889
+ transports_version_send: [:rest]
1890
+
1891
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1892
+
1893
+ options.apply_defaults timeout: @config.rpcs.get_task.timeout,
1894
+ metadata: call_metadata,
1895
+ retry_policy: @config.rpcs.get_task.retry_policy
1896
+
1897
+ options.apply_defaults timeout: @config.timeout,
1898
+ metadata: @config.metadata,
1899
+ retry_policy: @config.retry_policy
1900
+
1901
+ @dataplex_service_stub.get_task request, options do |result, operation|
1902
+ yield result, operation if block_given?
1903
+ return result
1904
+ end
1905
+ rescue ::Gapic::Rest::Error => e
1906
+ raise ::Google::Cloud::Error.from_error(e)
1907
+ end
1908
+
1909
+ ##
1910
+ # Lists Jobs under the given task.
1911
+ #
1912
+ # @overload list_jobs(request, options = nil)
1913
+ # Pass arguments to `list_jobs` via a request object, either of type
1914
+ # {::Google::Cloud::Dataplex::V1::ListJobsRequest} or an equivalent Hash.
1915
+ #
1916
+ # @param request [::Google::Cloud::Dataplex::V1::ListJobsRequest, ::Hash]
1917
+ # A request object representing the call parameters. Required. To specify no
1918
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1919
+ # @param options [::Gapic::CallOptions, ::Hash]
1920
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1921
+ #
1922
+ # @overload list_jobs(parent: nil, page_size: nil, page_token: nil)
1923
+ # Pass arguments to `list_jobs` via keyword arguments. Note that at
1924
+ # least one keyword argument is required. To specify no parameters, or to keep all
1925
+ # the default parameter values, pass an empty Hash as a request object (see above).
1926
+ #
1927
+ # @param parent [::String]
1928
+ # Required. The resource name of the parent environment:
1929
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}`.
1930
+ # @param page_size [::Integer]
1931
+ # Optional. Maximum number of jobs to return. The service may return fewer
1932
+ # than this value. If unspecified, at most 10 jobs will be returned. The
1933
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
1934
+ # @param page_token [::String]
1935
+ # Optional. Page token received from a previous `ListJobs` call. Provide this
1936
+ # to retrieve the subsequent page. When paginating, all other parameters
1937
+ # provided to `ListJobs` must match the call that provided the page
1938
+ # token.
1939
+ # @yield [result, operation] Access the result along with the TransportOperation object
1940
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Job>]
1941
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
1942
+ #
1943
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Job>]
1944
+ #
1945
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
1946
+ def list_jobs request, options = nil
1947
+ raise ::ArgumentError, "request must be provided" if request.nil?
1948
+
1949
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListJobsRequest
1950
+
1951
+ # Converts hash and nil to an options object
1952
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1953
+
1954
+ # Customize the options with defaults
1955
+ call_metadata = @config.rpcs.list_jobs.metadata.to_h
1956
+
1957
+ # Set x-goog-api-client and x-goog-user-project headers
1958
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1959
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
1960
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
1961
+ transports_version_send: [:rest]
1962
+
1963
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1964
+
1965
+ options.apply_defaults timeout: @config.rpcs.list_jobs.timeout,
1966
+ metadata: call_metadata,
1967
+ retry_policy: @config.rpcs.list_jobs.retry_policy
1968
+
1969
+ options.apply_defaults timeout: @config.timeout,
1970
+ metadata: @config.metadata,
1971
+ retry_policy: @config.retry_policy
1972
+
1973
+ @dataplex_service_stub.list_jobs request, options do |result, operation|
1974
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_jobs, "jobs", request, result, options
1975
+ yield result, operation if block_given?
1976
+ return result
1977
+ end
1978
+ rescue ::Gapic::Rest::Error => e
1979
+ raise ::Google::Cloud::Error.from_error(e)
1980
+ end
1981
+
1982
+ ##
1983
+ # Get job resource.
1984
+ #
1985
+ # @overload get_job(request, options = nil)
1986
+ # Pass arguments to `get_job` via a request object, either of type
1987
+ # {::Google::Cloud::Dataplex::V1::GetJobRequest} or an equivalent Hash.
1988
+ #
1989
+ # @param request [::Google::Cloud::Dataplex::V1::GetJobRequest, ::Hash]
1990
+ # A request object representing the call parameters. Required. To specify no
1991
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
1992
+ # @param options [::Gapic::CallOptions, ::Hash]
1993
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
1994
+ #
1995
+ # @overload get_job(name: nil)
1996
+ # Pass arguments to `get_job` via keyword arguments. Note that at
1997
+ # least one keyword argument is required. To specify no parameters, or to keep all
1998
+ # the default parameter values, pass an empty Hash as a request object (see above).
1999
+ #
2000
+ # @param name [::String]
2001
+ # Required. The resource name of the job:
2002
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}/jobs/{job_id}`.
2003
+ # @yield [result, operation] Access the result along with the TransportOperation object
2004
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Job]
2005
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2006
+ #
2007
+ # @return [::Google::Cloud::Dataplex::V1::Job]
2008
+ #
2009
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2010
+ def get_job request, options = nil
2011
+ raise ::ArgumentError, "request must be provided" if request.nil?
2012
+
2013
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetJobRequest
2014
+
2015
+ # Converts hash and nil to an options object
2016
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2017
+
2018
+ # Customize the options with defaults
2019
+ call_metadata = @config.rpcs.get_job.metadata.to_h
2020
+
2021
+ # Set x-goog-api-client and x-goog-user-project headers
2022
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2023
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2024
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2025
+ transports_version_send: [:rest]
2026
+
2027
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2028
+
2029
+ options.apply_defaults timeout: @config.rpcs.get_job.timeout,
2030
+ metadata: call_metadata,
2031
+ retry_policy: @config.rpcs.get_job.retry_policy
2032
+
2033
+ options.apply_defaults timeout: @config.timeout,
2034
+ metadata: @config.metadata,
2035
+ retry_policy: @config.retry_policy
2036
+
2037
+ @dataplex_service_stub.get_job request, options do |result, operation|
2038
+ yield result, operation if block_given?
2039
+ return result
2040
+ end
2041
+ rescue ::Gapic::Rest::Error => e
2042
+ raise ::Google::Cloud::Error.from_error(e)
2043
+ end
2044
+
2045
+ ##
2046
+ # Cancel jobs running for the task resource.
2047
+ #
2048
+ # @overload cancel_job(request, options = nil)
2049
+ # Pass arguments to `cancel_job` via a request object, either of type
2050
+ # {::Google::Cloud::Dataplex::V1::CancelJobRequest} or an equivalent Hash.
2051
+ #
2052
+ # @param request [::Google::Cloud::Dataplex::V1::CancelJobRequest, ::Hash]
2053
+ # A request object representing the call parameters. Required. To specify no
2054
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2055
+ # @param options [::Gapic::CallOptions, ::Hash]
2056
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2057
+ #
2058
+ # @overload cancel_job(name: nil)
2059
+ # Pass arguments to `cancel_job` via keyword arguments. Note that at
2060
+ # least one keyword argument is required. To specify no parameters, or to keep all
2061
+ # the default parameter values, pass an empty Hash as a request object (see above).
2062
+ #
2063
+ # @param name [::String]
2064
+ # Required. The resource name of the job:
2065
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/task/{task_id}/job/{job_id}`.
2066
+ # @yield [result, operation] Access the result along with the TransportOperation object
2067
+ # @yieldparam result [::Google::Protobuf::Empty]
2068
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2069
+ #
2070
+ # @return [::Google::Protobuf::Empty]
2071
+ #
2072
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2073
+ def cancel_job request, options = nil
2074
+ raise ::ArgumentError, "request must be provided" if request.nil?
2075
+
2076
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CancelJobRequest
2077
+
2078
+ # Converts hash and nil to an options object
2079
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2080
+
2081
+ # Customize the options with defaults
2082
+ call_metadata = @config.rpcs.cancel_job.metadata.to_h
2083
+
2084
+ # Set x-goog-api-client and x-goog-user-project headers
2085
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2086
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2087
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2088
+ transports_version_send: [:rest]
2089
+
2090
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2091
+
2092
+ options.apply_defaults timeout: @config.rpcs.cancel_job.timeout,
2093
+ metadata: call_metadata,
2094
+ retry_policy: @config.rpcs.cancel_job.retry_policy
2095
+
2096
+ options.apply_defaults timeout: @config.timeout,
2097
+ metadata: @config.metadata,
2098
+ retry_policy: @config.retry_policy
2099
+
2100
+ @dataplex_service_stub.cancel_job request, options do |result, operation|
2101
+ yield result, operation if block_given?
2102
+ return result
2103
+ end
2104
+ rescue ::Gapic::Rest::Error => e
2105
+ raise ::Google::Cloud::Error.from_error(e)
2106
+ end
2107
+
2108
+ ##
2109
+ # Create an environment resource.
2110
+ #
2111
+ # @overload create_environment(request, options = nil)
2112
+ # Pass arguments to `create_environment` via a request object, either of type
2113
+ # {::Google::Cloud::Dataplex::V1::CreateEnvironmentRequest} or an equivalent Hash.
2114
+ #
2115
+ # @param request [::Google::Cloud::Dataplex::V1::CreateEnvironmentRequest, ::Hash]
2116
+ # A request object representing the call parameters. Required. To specify no
2117
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2118
+ # @param options [::Gapic::CallOptions, ::Hash]
2119
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2120
+ #
2121
+ # @overload create_environment(parent: nil, environment_id: nil, environment: nil, validate_only: nil)
2122
+ # Pass arguments to `create_environment` via keyword arguments. Note that at
2123
+ # least one keyword argument is required. To specify no parameters, or to keep all
2124
+ # the default parameter values, pass an empty Hash as a request object (see above).
2125
+ #
2126
+ # @param parent [::String]
2127
+ # Required. The resource name of the parent lake:
2128
+ # `projects/{project_id}/locations/{location_id}/lakes/{lake_id}`.
2129
+ # @param environment_id [::String]
2130
+ # Required. Environment identifier.
2131
+ # * Must contain only lowercase letters, numbers and hyphens.
2132
+ # * Must start with a letter.
2133
+ # * Must be between 1-63 characters.
2134
+ # * Must end with a number or a letter.
2135
+ # * Must be unique within the lake.
2136
+ # @param environment [::Google::Cloud::Dataplex::V1::Environment, ::Hash]
2137
+ # Required. Environment resource.
2138
+ # @param validate_only [::Boolean]
2139
+ # Optional. Only validate the request, but do not perform mutations.
2140
+ # The default is false.
2141
+ # @yield [result, operation] Access the result along with the TransportOperation object
2142
+ # @yieldparam result [::Gapic::Operation]
2143
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2144
+ #
2145
+ # @return [::Gapic::Operation]
2146
+ #
2147
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2148
+ def create_environment request, options = nil
2149
+ raise ::ArgumentError, "request must be provided" if request.nil?
2150
+
2151
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::CreateEnvironmentRequest
2152
+
2153
+ # Converts hash and nil to an options object
2154
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2155
+
2156
+ # Customize the options with defaults
2157
+ call_metadata = @config.rpcs.create_environment.metadata.to_h
2158
+
2159
+ # Set x-goog-api-client and x-goog-user-project headers
2160
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2161
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2162
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2163
+ transports_version_send: [:rest]
2164
+
2165
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2166
+
2167
+ options.apply_defaults timeout: @config.rpcs.create_environment.timeout,
2168
+ metadata: call_metadata,
2169
+ retry_policy: @config.rpcs.create_environment.retry_policy
2170
+
2171
+ options.apply_defaults timeout: @config.timeout,
2172
+ metadata: @config.metadata,
2173
+ retry_policy: @config.retry_policy
2174
+
2175
+ @dataplex_service_stub.create_environment request, options do |result, operation|
2176
+ result = ::Gapic::Operation.new result, @operations_client, options: options
2177
+ yield result, operation if block_given?
2178
+ return result
2179
+ end
2180
+ rescue ::Gapic::Rest::Error => e
2181
+ raise ::Google::Cloud::Error.from_error(e)
2182
+ end
2183
+
2184
+ ##
2185
+ # Update the environment resource.
2186
+ #
2187
+ # @overload update_environment(request, options = nil)
2188
+ # Pass arguments to `update_environment` via a request object, either of type
2189
+ # {::Google::Cloud::Dataplex::V1::UpdateEnvironmentRequest} or an equivalent Hash.
2190
+ #
2191
+ # @param request [::Google::Cloud::Dataplex::V1::UpdateEnvironmentRequest, ::Hash]
2192
+ # A request object representing the call parameters. Required. To specify no
2193
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2194
+ # @param options [::Gapic::CallOptions, ::Hash]
2195
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2196
+ #
2197
+ # @overload update_environment(update_mask: nil, environment: nil, validate_only: nil)
2198
+ # Pass arguments to `update_environment` via keyword arguments. Note that at
2199
+ # least one keyword argument is required. To specify no parameters, or to keep all
2200
+ # the default parameter values, pass an empty Hash as a request object (see above).
2201
+ #
2202
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
2203
+ # Required. Mask of fields to update.
2204
+ # @param environment [::Google::Cloud::Dataplex::V1::Environment, ::Hash]
2205
+ # Required. Update description.
2206
+ # Only fields specified in `update_mask` are updated.
2207
+ # @param validate_only [::Boolean]
2208
+ # Optional. Only validate the request, but do not perform mutations.
2209
+ # The default is false.
2210
+ # @yield [result, operation] Access the result along with the TransportOperation object
2211
+ # @yieldparam result [::Gapic::Operation]
2212
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2213
+ #
2214
+ # @return [::Gapic::Operation]
2215
+ #
2216
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2217
+ def update_environment request, options = nil
2218
+ raise ::ArgumentError, "request must be provided" if request.nil?
2219
+
2220
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::UpdateEnvironmentRequest
2221
+
2222
+ # Converts hash and nil to an options object
2223
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2224
+
2225
+ # Customize the options with defaults
2226
+ call_metadata = @config.rpcs.update_environment.metadata.to_h
2227
+
2228
+ # Set x-goog-api-client and x-goog-user-project headers
2229
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2230
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2231
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2232
+ transports_version_send: [:rest]
2233
+
2234
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2235
+
2236
+ options.apply_defaults timeout: @config.rpcs.update_environment.timeout,
2237
+ metadata: call_metadata,
2238
+ retry_policy: @config.rpcs.update_environment.retry_policy
2239
+
2240
+ options.apply_defaults timeout: @config.timeout,
2241
+ metadata: @config.metadata,
2242
+ retry_policy: @config.retry_policy
2243
+
2244
+ @dataplex_service_stub.update_environment request, options do |result, operation|
2245
+ result = ::Gapic::Operation.new result, @operations_client, options: options
2246
+ yield result, operation if block_given?
2247
+ return result
2248
+ end
2249
+ rescue ::Gapic::Rest::Error => e
2250
+ raise ::Google::Cloud::Error.from_error(e)
2251
+ end
2252
+
2253
+ ##
2254
+ # Delete the environment resource. All the child resources must have been
2255
+ # deleted before environment deletion can be initiated.
2256
+ #
2257
+ # @overload delete_environment(request, options = nil)
2258
+ # Pass arguments to `delete_environment` via a request object, either of type
2259
+ # {::Google::Cloud::Dataplex::V1::DeleteEnvironmentRequest} or an equivalent Hash.
2260
+ #
2261
+ # @param request [::Google::Cloud::Dataplex::V1::DeleteEnvironmentRequest, ::Hash]
2262
+ # A request object representing the call parameters. Required. To specify no
2263
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2264
+ # @param options [::Gapic::CallOptions, ::Hash]
2265
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2266
+ #
2267
+ # @overload delete_environment(name: nil)
2268
+ # Pass arguments to `delete_environment` via keyword arguments. Note that at
2269
+ # least one keyword argument is required. To specify no parameters, or to keep all
2270
+ # the default parameter values, pass an empty Hash as a request object (see above).
2271
+ #
2272
+ # @param name [::String]
2273
+ # Required. The resource name of the environment:
2274
+ # `projects/{project_id}/locations/{location_id}/lakes/{lake_id}/environments/{environment_id}`.
2275
+ # @yield [result, operation] Access the result along with the TransportOperation object
2276
+ # @yieldparam result [::Gapic::Operation]
2277
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2278
+ #
2279
+ # @return [::Gapic::Operation]
2280
+ #
2281
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2282
+ def delete_environment request, options = nil
2283
+ raise ::ArgumentError, "request must be provided" if request.nil?
2284
+
2285
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::DeleteEnvironmentRequest
2286
+
2287
+ # Converts hash and nil to an options object
2288
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2289
+
2290
+ # Customize the options with defaults
2291
+ call_metadata = @config.rpcs.delete_environment.metadata.to_h
2292
+
2293
+ # Set x-goog-api-client and x-goog-user-project headers
2294
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2295
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2296
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2297
+ transports_version_send: [:rest]
2298
+
2299
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2300
+
2301
+ options.apply_defaults timeout: @config.rpcs.delete_environment.timeout,
2302
+ metadata: call_metadata,
2303
+ retry_policy: @config.rpcs.delete_environment.retry_policy
2304
+
2305
+ options.apply_defaults timeout: @config.timeout,
2306
+ metadata: @config.metadata,
2307
+ retry_policy: @config.retry_policy
2308
+
2309
+ @dataplex_service_stub.delete_environment request, options do |result, operation|
2310
+ result = ::Gapic::Operation.new result, @operations_client, options: options
2311
+ yield result, operation if block_given?
2312
+ return result
2313
+ end
2314
+ rescue ::Gapic::Rest::Error => e
2315
+ raise ::Google::Cloud::Error.from_error(e)
2316
+ end
2317
+
2318
+ ##
2319
+ # Lists environments under the given lake.
2320
+ #
2321
+ # @overload list_environments(request, options = nil)
2322
+ # Pass arguments to `list_environments` via a request object, either of type
2323
+ # {::Google::Cloud::Dataplex::V1::ListEnvironmentsRequest} or an equivalent Hash.
2324
+ #
2325
+ # @param request [::Google::Cloud::Dataplex::V1::ListEnvironmentsRequest, ::Hash]
2326
+ # A request object representing the call parameters. Required. To specify no
2327
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2328
+ # @param options [::Gapic::CallOptions, ::Hash]
2329
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2330
+ #
2331
+ # @overload list_environments(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil)
2332
+ # Pass arguments to `list_environments` via keyword arguments. Note that at
2333
+ # least one keyword argument is required. To specify no parameters, or to keep all
2334
+ # the default parameter values, pass an empty Hash as a request object (see above).
2335
+ #
2336
+ # @param parent [::String]
2337
+ # Required. The resource name of the parent lake:
2338
+ # `projects/{project_id}/locations/{location_id}/lakes/{lake_id}`.
2339
+ # @param page_size [::Integer]
2340
+ # Optional. Maximum number of environments to return. The service may return
2341
+ # fewer than this value. If unspecified, at most 10 environments will be
2342
+ # returned. The maximum value is 1000; values above 1000 will be coerced to
2343
+ # 1000.
2344
+ # @param page_token [::String]
2345
+ # Optional. Page token received from a previous `ListEnvironments` call.
2346
+ # Provide this to retrieve the subsequent page. When paginating, all other
2347
+ # parameters provided to `ListEnvironments` must match the call that provided
2348
+ # the page token.
2349
+ # @param filter [::String]
2350
+ # Optional. Filter request.
2351
+ # @param order_by [::String]
2352
+ # Optional. Order by fields for the result.
2353
+ # @yield [result, operation] Access the result along with the TransportOperation object
2354
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Environment>]
2355
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2356
+ #
2357
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Environment>]
2358
+ #
2359
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2360
+ def list_environments request, options = nil
2361
+ raise ::ArgumentError, "request must be provided" if request.nil?
2362
+
2363
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListEnvironmentsRequest
2364
+
2365
+ # Converts hash and nil to an options object
2366
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2367
+
2368
+ # Customize the options with defaults
2369
+ call_metadata = @config.rpcs.list_environments.metadata.to_h
2370
+
2371
+ # Set x-goog-api-client and x-goog-user-project headers
2372
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2373
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2374
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2375
+ transports_version_send: [:rest]
2376
+
2377
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2378
+
2379
+ options.apply_defaults timeout: @config.rpcs.list_environments.timeout,
2380
+ metadata: call_metadata,
2381
+ retry_policy: @config.rpcs.list_environments.retry_policy
2382
+
2383
+ options.apply_defaults timeout: @config.timeout,
2384
+ metadata: @config.metadata,
2385
+ retry_policy: @config.retry_policy
2386
+
2387
+ @dataplex_service_stub.list_environments request, options do |result, operation|
2388
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_environments, "environments", request, result, options
2389
+ yield result, operation if block_given?
2390
+ return result
2391
+ end
2392
+ rescue ::Gapic::Rest::Error => e
2393
+ raise ::Google::Cloud::Error.from_error(e)
2394
+ end
2395
+
2396
+ ##
2397
+ # Get environment resource.
2398
+ #
2399
+ # @overload get_environment(request, options = nil)
2400
+ # Pass arguments to `get_environment` via a request object, either of type
2401
+ # {::Google::Cloud::Dataplex::V1::GetEnvironmentRequest} or an equivalent Hash.
2402
+ #
2403
+ # @param request [::Google::Cloud::Dataplex::V1::GetEnvironmentRequest, ::Hash]
2404
+ # A request object representing the call parameters. Required. To specify no
2405
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
2406
+ # @param options [::Gapic::CallOptions, ::Hash]
2407
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
2408
+ #
2409
+ # @overload get_environment(name: nil)
2410
+ # Pass arguments to `get_environment` via keyword arguments. Note that at
2411
+ # least one keyword argument is required. To specify no parameters, or to keep all
2412
+ # the default parameter values, pass an empty Hash as a request object (see above).
2413
+ #
2414
+ # @param name [::String]
2415
+ # Required. The resource name of the environment:
2416
+ # `projects/{project_id}/locations/{location_id}/lakes/{lake_id}/environments/{environment_id}`.
2417
+ # @yield [result, operation] Access the result along with the TransportOperation object
2418
+ # @yieldparam result [::Google::Cloud::Dataplex::V1::Environment]
2419
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2420
+ #
2421
+ # @return [::Google::Cloud::Dataplex::V1::Environment]
2422
+ #
2423
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2424
+ def get_environment request, options = nil
2425
+ raise ::ArgumentError, "request must be provided" if request.nil?
2426
+
2427
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::GetEnvironmentRequest
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.get_environment.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::Dataplex::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.get_environment.timeout,
2444
+ metadata: call_metadata,
2445
+ retry_policy: @config.rpcs.get_environment.retry_policy
2446
+
2447
+ options.apply_defaults timeout: @config.timeout,
2448
+ metadata: @config.metadata,
2449
+ retry_policy: @config.retry_policy
2450
+
2451
+ @dataplex_service_stub.get_environment 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
+ # Lists session resources in an environment.
2461
+ #
2462
+ # @overload list_sessions(request, options = nil)
2463
+ # Pass arguments to `list_sessions` via a request object, either of type
2464
+ # {::Google::Cloud::Dataplex::V1::ListSessionsRequest} or an equivalent Hash.
2465
+ #
2466
+ # @param request [::Google::Cloud::Dataplex::V1::ListSessionsRequest, ::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 list_sessions(parent: nil, page_size: nil, page_token: nil, filter: nil)
2473
+ # Pass arguments to `list_sessions` 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 parent [::String]
2478
+ # Required. The resource name of the parent environment:
2479
+ # `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/environment/{environment_id}`.
2480
+ # @param page_size [::Integer]
2481
+ # Optional. Maximum number of sessions to return. The service may return
2482
+ # fewer than this value. If unspecified, at most 10 sessions will be
2483
+ # returned. The maximum value is 1000; values above 1000 will be coerced to
2484
+ # 1000.
2485
+ # @param page_token [::String]
2486
+ # Optional. Page token received from a previous `ListSessions` call. Provide
2487
+ # this to retrieve the subsequent page. When paginating, all other parameters
2488
+ # provided to `ListSessions` must match the call that provided the page
2489
+ # token.
2490
+ # @param filter [::String]
2491
+ # Optional. Filter request. The following `mode` filter is supported to
2492
+ # return only the sessions belonging to the requester when the mode is USER
2493
+ # and return sessions of all the users when the mode is ADMIN. When no filter
2494
+ # is sent default to USER mode. NOTE: When the mode is ADMIN, the requester
2495
+ # should have `dataplex.environments.listAllSessions` permission to list all
2496
+ # sessions, in absence of the permission, the request fails.
2497
+ #
2498
+ # mode = ADMIN | USER
2499
+ # @yield [result, operation] Access the result along with the TransportOperation object
2500
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Session>]
2501
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
2502
+ #
2503
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::Dataplex::V1::Session>]
2504
+ #
2505
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
2506
+ def list_sessions request, options = nil
2507
+ raise ::ArgumentError, "request must be provided" if request.nil?
2508
+
2509
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dataplex::V1::ListSessionsRequest
2510
+
2511
+ # Converts hash and nil to an options object
2512
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
2513
+
2514
+ # Customize the options with defaults
2515
+ call_metadata = @config.rpcs.list_sessions.metadata.to_h
2516
+
2517
+ # Set x-goog-api-client and x-goog-user-project headers
2518
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
2519
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
2520
+ gapic_version: ::Google::Cloud::Dataplex::V1::VERSION,
2521
+ transports_version_send: [:rest]
2522
+
2523
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
2524
+
2525
+ options.apply_defaults timeout: @config.rpcs.list_sessions.timeout,
2526
+ metadata: call_metadata,
2527
+ retry_policy: @config.rpcs.list_sessions.retry_policy
2528
+
2529
+ options.apply_defaults timeout: @config.timeout,
2530
+ metadata: @config.metadata,
2531
+ retry_policy: @config.retry_policy
2532
+
2533
+ @dataplex_service_stub.list_sessions request, options do |result, operation|
2534
+ result = ::Gapic::Rest::PagedEnumerable.new @dataplex_service_stub, :list_sessions, "sessions", request, result, options
2535
+ yield result, operation if block_given?
2536
+ return result
2537
+ end
2538
+ rescue ::Gapic::Rest::Error => e
2539
+ raise ::Google::Cloud::Error.from_error(e)
2540
+ end
2541
+
2542
+ ##
2543
+ # Configuration class for the DataplexService REST API.
2544
+ #
2545
+ # This class represents the configuration for DataplexService REST,
2546
+ # providing control over timeouts, retry behavior, logging, transport
2547
+ # parameters, and other low-level controls. Certain parameters can also be
2548
+ # applied individually to specific RPCs. See
2549
+ # {::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client::Configuration::Rpcs}
2550
+ # for a list of RPCs that can be configured independently.
2551
+ #
2552
+ # Configuration can be applied globally to all clients, or to a single client
2553
+ # on construction.
2554
+ #
2555
+ # @example
2556
+ #
2557
+ # # Modify the global config, setting the timeout for
2558
+ # # create_lake to 20 seconds,
2559
+ # # and all remaining timeouts to 10 seconds.
2560
+ # ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client.configure do |config|
2561
+ # config.timeout = 10.0
2562
+ # config.rpcs.create_lake.timeout = 20.0
2563
+ # end
2564
+ #
2565
+ # # Apply the above configuration only to a new client.
2566
+ # client = ::Google::Cloud::Dataplex::V1::DataplexService::Rest::Client.new do |config|
2567
+ # config.timeout = 10.0
2568
+ # config.rpcs.create_lake.timeout = 20.0
2569
+ # end
2570
+ #
2571
+ # @!attribute [rw] endpoint
2572
+ # The hostname or hostname:port of the service endpoint.
2573
+ # Defaults to `"dataplex.googleapis.com"`.
2574
+ # @return [::String]
2575
+ # @!attribute [rw] credentials
2576
+ # Credentials to send with calls. You may provide any of the following types:
2577
+ # * (`String`) The path to a service account key file in JSON format
2578
+ # * (`Hash`) A service account key as a Hash
2579
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
2580
+ # (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
2581
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
2582
+ # (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
2583
+ # * (`nil`) indicating no credentials
2584
+ # @return [::Object]
2585
+ # @!attribute [rw] scope
2586
+ # The OAuth scopes
2587
+ # @return [::Array<::String>]
2588
+ # @!attribute [rw] lib_name
2589
+ # The library name as recorded in instrumentation and logging
2590
+ # @return [::String]
2591
+ # @!attribute [rw] lib_version
2592
+ # The library version as recorded in instrumentation and logging
2593
+ # @return [::String]
2594
+ # @!attribute [rw] timeout
2595
+ # The call timeout in seconds.
2596
+ # @return [::Numeric]
2597
+ # @!attribute [rw] metadata
2598
+ # Additional headers to be sent with the call.
2599
+ # @return [::Hash{::Symbol=>::String}]
2600
+ # @!attribute [rw] retry_policy
2601
+ # The retry policy. The value is a hash with the following keys:
2602
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
2603
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
2604
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
2605
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
2606
+ # trigger a retry.
2607
+ # @return [::Hash]
2608
+ # @!attribute [rw] quota_project
2609
+ # A separate project against which to charge quota.
2610
+ # @return [::String]
2611
+ #
2612
+ class Configuration
2613
+ extend ::Gapic::Config
2614
+
2615
+ config_attr :endpoint, "dataplex.googleapis.com", ::String
2616
+ config_attr :credentials, nil do |value|
2617
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
2618
+ allowed.any? { |klass| klass === value }
2619
+ end
2620
+ config_attr :scope, nil, ::String, ::Array, nil
2621
+ config_attr :lib_name, nil, ::String, nil
2622
+ config_attr :lib_version, nil, ::String, nil
2623
+ config_attr :timeout, nil, ::Numeric, nil
2624
+ config_attr :metadata, nil, ::Hash, nil
2625
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
2626
+ config_attr :quota_project, nil, ::String, nil
2627
+
2628
+ # @private
2629
+ # Overrides for http bindings for the RPCs of this service
2630
+ # are only used when this service is used as mixin, and only
2631
+ # by the host service.
2632
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
2633
+ config_attr :bindings_override, {}, ::Hash, nil
2634
+
2635
+ # @private
2636
+ def initialize parent_config = nil
2637
+ @parent_config = parent_config unless parent_config.nil?
2638
+
2639
+ yield self if block_given?
2640
+ end
2641
+
2642
+ ##
2643
+ # Configurations for individual RPCs
2644
+ # @return [Rpcs]
2645
+ #
2646
+ def rpcs
2647
+ @rpcs ||= begin
2648
+ parent_rpcs = nil
2649
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
2650
+ Rpcs.new parent_rpcs
2651
+ end
2652
+ end
2653
+
2654
+ ##
2655
+ # Configuration RPC class for the DataplexService API.
2656
+ #
2657
+ # Includes fields providing the configuration for each RPC in this service.
2658
+ # Each configuration object is of type `Gapic::Config::Method` and includes
2659
+ # the following configuration fields:
2660
+ #
2661
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
2662
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
2663
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
2664
+ # include the following keys:
2665
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
2666
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
2667
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
2668
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
2669
+ # trigger a retry.
2670
+ #
2671
+ class Rpcs
2672
+ ##
2673
+ # RPC-specific configuration for `create_lake`
2674
+ # @return [::Gapic::Config::Method]
2675
+ #
2676
+ attr_reader :create_lake
2677
+ ##
2678
+ # RPC-specific configuration for `update_lake`
2679
+ # @return [::Gapic::Config::Method]
2680
+ #
2681
+ attr_reader :update_lake
2682
+ ##
2683
+ # RPC-specific configuration for `delete_lake`
2684
+ # @return [::Gapic::Config::Method]
2685
+ #
2686
+ attr_reader :delete_lake
2687
+ ##
2688
+ # RPC-specific configuration for `list_lakes`
2689
+ # @return [::Gapic::Config::Method]
2690
+ #
2691
+ attr_reader :list_lakes
2692
+ ##
2693
+ # RPC-specific configuration for `get_lake`
2694
+ # @return [::Gapic::Config::Method]
2695
+ #
2696
+ attr_reader :get_lake
2697
+ ##
2698
+ # RPC-specific configuration for `list_lake_actions`
2699
+ # @return [::Gapic::Config::Method]
2700
+ #
2701
+ attr_reader :list_lake_actions
2702
+ ##
2703
+ # RPC-specific configuration for `create_zone`
2704
+ # @return [::Gapic::Config::Method]
2705
+ #
2706
+ attr_reader :create_zone
2707
+ ##
2708
+ # RPC-specific configuration for `update_zone`
2709
+ # @return [::Gapic::Config::Method]
2710
+ #
2711
+ attr_reader :update_zone
2712
+ ##
2713
+ # RPC-specific configuration for `delete_zone`
2714
+ # @return [::Gapic::Config::Method]
2715
+ #
2716
+ attr_reader :delete_zone
2717
+ ##
2718
+ # RPC-specific configuration for `list_zones`
2719
+ # @return [::Gapic::Config::Method]
2720
+ #
2721
+ attr_reader :list_zones
2722
+ ##
2723
+ # RPC-specific configuration for `get_zone`
2724
+ # @return [::Gapic::Config::Method]
2725
+ #
2726
+ attr_reader :get_zone
2727
+ ##
2728
+ # RPC-specific configuration for `list_zone_actions`
2729
+ # @return [::Gapic::Config::Method]
2730
+ #
2731
+ attr_reader :list_zone_actions
2732
+ ##
2733
+ # RPC-specific configuration for `create_asset`
2734
+ # @return [::Gapic::Config::Method]
2735
+ #
2736
+ attr_reader :create_asset
2737
+ ##
2738
+ # RPC-specific configuration for `update_asset`
2739
+ # @return [::Gapic::Config::Method]
2740
+ #
2741
+ attr_reader :update_asset
2742
+ ##
2743
+ # RPC-specific configuration for `delete_asset`
2744
+ # @return [::Gapic::Config::Method]
2745
+ #
2746
+ attr_reader :delete_asset
2747
+ ##
2748
+ # RPC-specific configuration for `list_assets`
2749
+ # @return [::Gapic::Config::Method]
2750
+ #
2751
+ attr_reader :list_assets
2752
+ ##
2753
+ # RPC-specific configuration for `get_asset`
2754
+ # @return [::Gapic::Config::Method]
2755
+ #
2756
+ attr_reader :get_asset
2757
+ ##
2758
+ # RPC-specific configuration for `list_asset_actions`
2759
+ # @return [::Gapic::Config::Method]
2760
+ #
2761
+ attr_reader :list_asset_actions
2762
+ ##
2763
+ # RPC-specific configuration for `create_task`
2764
+ # @return [::Gapic::Config::Method]
2765
+ #
2766
+ attr_reader :create_task
2767
+ ##
2768
+ # RPC-specific configuration for `update_task`
2769
+ # @return [::Gapic::Config::Method]
2770
+ #
2771
+ attr_reader :update_task
2772
+ ##
2773
+ # RPC-specific configuration for `delete_task`
2774
+ # @return [::Gapic::Config::Method]
2775
+ #
2776
+ attr_reader :delete_task
2777
+ ##
2778
+ # RPC-specific configuration for `list_tasks`
2779
+ # @return [::Gapic::Config::Method]
2780
+ #
2781
+ attr_reader :list_tasks
2782
+ ##
2783
+ # RPC-specific configuration for `get_task`
2784
+ # @return [::Gapic::Config::Method]
2785
+ #
2786
+ attr_reader :get_task
2787
+ ##
2788
+ # RPC-specific configuration for `list_jobs`
2789
+ # @return [::Gapic::Config::Method]
2790
+ #
2791
+ attr_reader :list_jobs
2792
+ ##
2793
+ # RPC-specific configuration for `get_job`
2794
+ # @return [::Gapic::Config::Method]
2795
+ #
2796
+ attr_reader :get_job
2797
+ ##
2798
+ # RPC-specific configuration for `cancel_job`
2799
+ # @return [::Gapic::Config::Method]
2800
+ #
2801
+ attr_reader :cancel_job
2802
+ ##
2803
+ # RPC-specific configuration for `create_environment`
2804
+ # @return [::Gapic::Config::Method]
2805
+ #
2806
+ attr_reader :create_environment
2807
+ ##
2808
+ # RPC-specific configuration for `update_environment`
2809
+ # @return [::Gapic::Config::Method]
2810
+ #
2811
+ attr_reader :update_environment
2812
+ ##
2813
+ # RPC-specific configuration for `delete_environment`
2814
+ # @return [::Gapic::Config::Method]
2815
+ #
2816
+ attr_reader :delete_environment
2817
+ ##
2818
+ # RPC-specific configuration for `list_environments`
2819
+ # @return [::Gapic::Config::Method]
2820
+ #
2821
+ attr_reader :list_environments
2822
+ ##
2823
+ # RPC-specific configuration for `get_environment`
2824
+ # @return [::Gapic::Config::Method]
2825
+ #
2826
+ attr_reader :get_environment
2827
+ ##
2828
+ # RPC-specific configuration for `list_sessions`
2829
+ # @return [::Gapic::Config::Method]
2830
+ #
2831
+ attr_reader :list_sessions
2832
+
2833
+ # @private
2834
+ def initialize parent_rpcs = nil
2835
+ create_lake_config = parent_rpcs.create_lake if parent_rpcs.respond_to? :create_lake
2836
+ @create_lake = ::Gapic::Config::Method.new create_lake_config
2837
+ update_lake_config = parent_rpcs.update_lake if parent_rpcs.respond_to? :update_lake
2838
+ @update_lake = ::Gapic::Config::Method.new update_lake_config
2839
+ delete_lake_config = parent_rpcs.delete_lake if parent_rpcs.respond_to? :delete_lake
2840
+ @delete_lake = ::Gapic::Config::Method.new delete_lake_config
2841
+ list_lakes_config = parent_rpcs.list_lakes if parent_rpcs.respond_to? :list_lakes
2842
+ @list_lakes = ::Gapic::Config::Method.new list_lakes_config
2843
+ get_lake_config = parent_rpcs.get_lake if parent_rpcs.respond_to? :get_lake
2844
+ @get_lake = ::Gapic::Config::Method.new get_lake_config
2845
+ list_lake_actions_config = parent_rpcs.list_lake_actions if parent_rpcs.respond_to? :list_lake_actions
2846
+ @list_lake_actions = ::Gapic::Config::Method.new list_lake_actions_config
2847
+ create_zone_config = parent_rpcs.create_zone if parent_rpcs.respond_to? :create_zone
2848
+ @create_zone = ::Gapic::Config::Method.new create_zone_config
2849
+ update_zone_config = parent_rpcs.update_zone if parent_rpcs.respond_to? :update_zone
2850
+ @update_zone = ::Gapic::Config::Method.new update_zone_config
2851
+ delete_zone_config = parent_rpcs.delete_zone if parent_rpcs.respond_to? :delete_zone
2852
+ @delete_zone = ::Gapic::Config::Method.new delete_zone_config
2853
+ list_zones_config = parent_rpcs.list_zones if parent_rpcs.respond_to? :list_zones
2854
+ @list_zones = ::Gapic::Config::Method.new list_zones_config
2855
+ get_zone_config = parent_rpcs.get_zone if parent_rpcs.respond_to? :get_zone
2856
+ @get_zone = ::Gapic::Config::Method.new get_zone_config
2857
+ list_zone_actions_config = parent_rpcs.list_zone_actions if parent_rpcs.respond_to? :list_zone_actions
2858
+ @list_zone_actions = ::Gapic::Config::Method.new list_zone_actions_config
2859
+ create_asset_config = parent_rpcs.create_asset if parent_rpcs.respond_to? :create_asset
2860
+ @create_asset = ::Gapic::Config::Method.new create_asset_config
2861
+ update_asset_config = parent_rpcs.update_asset if parent_rpcs.respond_to? :update_asset
2862
+ @update_asset = ::Gapic::Config::Method.new update_asset_config
2863
+ delete_asset_config = parent_rpcs.delete_asset if parent_rpcs.respond_to? :delete_asset
2864
+ @delete_asset = ::Gapic::Config::Method.new delete_asset_config
2865
+ list_assets_config = parent_rpcs.list_assets if parent_rpcs.respond_to? :list_assets
2866
+ @list_assets = ::Gapic::Config::Method.new list_assets_config
2867
+ get_asset_config = parent_rpcs.get_asset if parent_rpcs.respond_to? :get_asset
2868
+ @get_asset = ::Gapic::Config::Method.new get_asset_config
2869
+ list_asset_actions_config = parent_rpcs.list_asset_actions if parent_rpcs.respond_to? :list_asset_actions
2870
+ @list_asset_actions = ::Gapic::Config::Method.new list_asset_actions_config
2871
+ create_task_config = parent_rpcs.create_task if parent_rpcs.respond_to? :create_task
2872
+ @create_task = ::Gapic::Config::Method.new create_task_config
2873
+ update_task_config = parent_rpcs.update_task if parent_rpcs.respond_to? :update_task
2874
+ @update_task = ::Gapic::Config::Method.new update_task_config
2875
+ delete_task_config = parent_rpcs.delete_task if parent_rpcs.respond_to? :delete_task
2876
+ @delete_task = ::Gapic::Config::Method.new delete_task_config
2877
+ list_tasks_config = parent_rpcs.list_tasks if parent_rpcs.respond_to? :list_tasks
2878
+ @list_tasks = ::Gapic::Config::Method.new list_tasks_config
2879
+ get_task_config = parent_rpcs.get_task if parent_rpcs.respond_to? :get_task
2880
+ @get_task = ::Gapic::Config::Method.new get_task_config
2881
+ list_jobs_config = parent_rpcs.list_jobs if parent_rpcs.respond_to? :list_jobs
2882
+ @list_jobs = ::Gapic::Config::Method.new list_jobs_config
2883
+ get_job_config = parent_rpcs.get_job if parent_rpcs.respond_to? :get_job
2884
+ @get_job = ::Gapic::Config::Method.new get_job_config
2885
+ cancel_job_config = parent_rpcs.cancel_job if parent_rpcs.respond_to? :cancel_job
2886
+ @cancel_job = ::Gapic::Config::Method.new cancel_job_config
2887
+ create_environment_config = parent_rpcs.create_environment if parent_rpcs.respond_to? :create_environment
2888
+ @create_environment = ::Gapic::Config::Method.new create_environment_config
2889
+ update_environment_config = parent_rpcs.update_environment if parent_rpcs.respond_to? :update_environment
2890
+ @update_environment = ::Gapic::Config::Method.new update_environment_config
2891
+ delete_environment_config = parent_rpcs.delete_environment if parent_rpcs.respond_to? :delete_environment
2892
+ @delete_environment = ::Gapic::Config::Method.new delete_environment_config
2893
+ list_environments_config = parent_rpcs.list_environments if parent_rpcs.respond_to? :list_environments
2894
+ @list_environments = ::Gapic::Config::Method.new list_environments_config
2895
+ get_environment_config = parent_rpcs.get_environment if parent_rpcs.respond_to? :get_environment
2896
+ @get_environment = ::Gapic::Config::Method.new get_environment_config
2897
+ list_sessions_config = parent_rpcs.list_sessions if parent_rpcs.respond_to? :list_sessions
2898
+ @list_sessions = ::Gapic::Config::Method.new list_sessions_config
2899
+
2900
+ yield self if block_given?
2901
+ end
2902
+ end
2903
+ end
2904
+ end
2905
+ end
2906
+ end
2907
+ end
2908
+ end
2909
+ end
2910
+ end