google-cloud-data_catalog-v1 0.7.3 → 0.8.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/data_catalog/v1/data_catalog/client.rb +989 -432
- data/lib/google/cloud/data_catalog/v1/data_catalog.rb +2 -2
- data/lib/google/cloud/data_catalog/v1/policy_tag_manager/client.rb +394 -133
- data/lib/google/cloud/data_catalog/v1/policy_tag_manager.rb +1 -1
- data/lib/google/cloud/data_catalog/v1/policy_tag_manager_serialization/client.rb +198 -61
- data/lib/google/cloud/data_catalog/v1/policy_tag_manager_serialization.rb +4 -3
- data/lib/google/cloud/data_catalog/v1/version.rb +1 -1
- data/lib/google/cloud/datacatalog/v1/bigquery_pb.rb +48 -0
- data/lib/google/cloud/datacatalog/v1/data_source_pb.rb +1 -1
- data/lib/google/cloud/datacatalog/v1/datacatalog_pb.rb +46 -2
- data/lib/google/cloud/datacatalog/v1/datacatalog_services_pb.rb +180 -143
- data/lib/google/cloud/datacatalog/v1/gcs_fileset_spec_pb.rb +2 -2
- data/lib/google/cloud/datacatalog/v1/policytagmanager_pb.rb +2 -2
- data/lib/google/cloud/datacatalog/v1/policytagmanager_services_pb.rb +16 -15
- data/lib/google/cloud/datacatalog/v1/policytagmanagerserialization_pb.rb +7 -2
- data/lib/google/cloud/datacatalog/v1/policytagmanagerserialization_services_pb.rb +29 -15
- data/lib/google/cloud/datacatalog/v1/schema_pb.rb +1 -1
- data/lib/google/cloud/datacatalog/v1/search_pb.rb +2 -2
- data/lib/google/cloud/datacatalog/v1/table_spec_pb.rb +2 -2
- data/lib/google/cloud/datacatalog/v1/tags_pb.rb +5 -2
- data/lib/google/cloud/datacatalog/v1/timestamps_pb.rb +2 -2
- data/lib/google/cloud/datacatalog/v1/usage_pb.rb +31 -0
- data/proto_docs/google/cloud/datacatalog/v1/bigquery.rb +87 -0
- data/proto_docs/google/cloud/datacatalog/v1/common.rb +1 -2
- data/proto_docs/google/cloud/datacatalog/v1/data_source.rb +6 -5
- data/proto_docs/google/cloud/datacatalog/v1/datacatalog.rb +370 -246
- data/proto_docs/google/cloud/datacatalog/v1/gcs_fileset_spec.rb +16 -15
- data/proto_docs/google/cloud/datacatalog/v1/policytagmanager.rb +87 -71
- data/proto_docs/google/cloud/datacatalog/v1/policytagmanagerserialization.rb +34 -19
- data/proto_docs/google/cloud/datacatalog/v1/schema.rb +3 -3
- data/proto_docs/google/cloud/datacatalog/v1/search.rb +43 -29
- data/proto_docs/google/cloud/datacatalog/v1/table_spec.rb +23 -16
- data/proto_docs/google/cloud/datacatalog/v1/tags.rb +96 -51
- data/proto_docs/google/cloud/datacatalog/v1/timestamps.rb +12 -5
- data/proto_docs/google/cloud/datacatalog/v1/usage.rb +79 -0
- metadata +8 -4
@@ -27,7 +27,7 @@ module Google
|
|
27
27
|
##
|
28
28
|
# Client for the PolicyTagManager service.
|
29
29
|
#
|
30
|
-
# Policy Tag Manager API service allows
|
30
|
+
# Policy Tag Manager API service allows you to manage your policy tags and
|
31
31
|
# taxonomies.
|
32
32
|
#
|
33
33
|
# Policy tags are used to tag BigQuery columns and apply additional access
|
@@ -46,13 +46,12 @@ module Google
|
|
46
46
|
# See {::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client::Configuration}
|
47
47
|
# for a description of the configuration fields.
|
48
48
|
#
|
49
|
-
#
|
49
|
+
# @example
|
50
50
|
#
|
51
|
-
#
|
52
|
-
#
|
53
|
-
#
|
54
|
-
#
|
55
|
-
# end
|
51
|
+
# # Modify the configuration for all PolicyTagManager clients
|
52
|
+
# ::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.configure do |config|
|
53
|
+
# config.timeout = 10.0
|
54
|
+
# end
|
56
55
|
#
|
57
56
|
# @yield [config] Configure the Client client.
|
58
57
|
# @yieldparam config [Client::Configuration]
|
@@ -101,19 +100,15 @@ module Google
|
|
101
100
|
##
|
102
101
|
# Create a new PolicyTagManager client object.
|
103
102
|
#
|
104
|
-
#
|
105
|
-
#
|
106
|
-
# To create a new PolicyTagManager client with the default
|
107
|
-
# configuration:
|
103
|
+
# @example
|
108
104
|
#
|
109
|
-
#
|
105
|
+
# # Create a client using the default configuration
|
106
|
+
# client = ::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
110
107
|
#
|
111
|
-
#
|
112
|
-
#
|
113
|
-
#
|
114
|
-
#
|
115
|
-
# config.timeout = 10.0
|
116
|
-
# end
|
108
|
+
# # Create a client using a custom configuration
|
109
|
+
# client = ::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new do |config|
|
110
|
+
# config.timeout = 10.0
|
111
|
+
# end
|
117
112
|
#
|
118
113
|
# @yield [config] Configure the PolicyTagManager client.
|
119
114
|
# @yieldparam config [Client::Configuration]
|
@@ -133,10 +128,9 @@ module Google
|
|
133
128
|
|
134
129
|
# Create credentials
|
135
130
|
credentials = @config.credentials
|
136
|
-
# Use self-signed JWT if the
|
131
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
137
132
|
# but only if the default endpoint does not have a region prefix.
|
138
|
-
enable_self_signed_jwt = @config.
|
139
|
-
@config.endpoint == Client.configure.endpoint &&
|
133
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
140
134
|
!@config.endpoint.split(".").first.include?("-")
|
141
135
|
credentials ||= Credentials.default scope: @config.scope,
|
142
136
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -158,8 +152,9 @@ module Google
|
|
158
152
|
# Service calls
|
159
153
|
|
160
154
|
##
|
161
|
-
# Creates a taxonomy in a specified project.
|
162
|
-
#
|
155
|
+
# Creates a taxonomy in a specified project.
|
156
|
+
#
|
157
|
+
# The taxonomy is initially empty, that is, it doesn't contain policy tags.
|
163
158
|
#
|
164
159
|
# @overload create_taxonomy(request, options = nil)
|
165
160
|
# Pass arguments to `create_taxonomy` via a request object, either of type
|
@@ -179,7 +174,7 @@ module Google
|
|
179
174
|
# @param parent [::String]
|
180
175
|
# Required. Resource name of the project that the taxonomy will belong to.
|
181
176
|
# @param taxonomy [::Google::Cloud::DataCatalog::V1::Taxonomy, ::Hash]
|
182
|
-
# The taxonomy to
|
177
|
+
# The taxonomy to create.
|
183
178
|
#
|
184
179
|
# @yield [response, operation] Access the result along with the RPC operation
|
185
180
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::Taxonomy]
|
@@ -189,6 +184,21 @@ module Google
|
|
189
184
|
#
|
190
185
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
191
186
|
#
|
187
|
+
# @example Basic example
|
188
|
+
# require "google/cloud/data_catalog/v1"
|
189
|
+
#
|
190
|
+
# # Create a client object. The client can be reused for multiple calls.
|
191
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
192
|
+
#
|
193
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
194
|
+
# request = Google::Cloud::DataCatalog::V1::CreateTaxonomyRequest.new
|
195
|
+
#
|
196
|
+
# # Call the create_taxonomy method.
|
197
|
+
# result = client.create_taxonomy request
|
198
|
+
#
|
199
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::Taxonomy.
|
200
|
+
# p result
|
201
|
+
#
|
192
202
|
def create_taxonomy request, options = nil
|
193
203
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
194
204
|
|
@@ -206,16 +216,20 @@ module Google
|
|
206
216
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
207
217
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
208
218
|
|
209
|
-
header_params = {
|
210
|
-
|
211
|
-
|
219
|
+
header_params = {}
|
220
|
+
if request.parent
|
221
|
+
header_params["parent"] = request.parent
|
222
|
+
end
|
223
|
+
|
212
224
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
213
225
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
214
226
|
|
215
227
|
options.apply_defaults timeout: @config.rpcs.create_taxonomy.timeout,
|
216
228
|
metadata: metadata,
|
217
229
|
retry_policy: @config.rpcs.create_taxonomy.retry_policy
|
218
|
-
|
230
|
+
|
231
|
+
options.apply_defaults timeout: @config.timeout,
|
232
|
+
metadata: @config.metadata,
|
219
233
|
retry_policy: @config.retry_policy
|
220
234
|
|
221
235
|
@policy_tag_manager_stub.call_rpc :create_taxonomy, request, options: options do |response, operation|
|
@@ -227,7 +241,7 @@ module Google
|
|
227
241
|
end
|
228
242
|
|
229
243
|
##
|
230
|
-
# Deletes a taxonomy
|
244
|
+
# Deletes a taxonomy, including all policy tags in this
|
231
245
|
# taxonomy, their associated policies, and the policy tags references from
|
232
246
|
# BigQuery columns.
|
233
247
|
#
|
@@ -247,8 +261,9 @@ module Google
|
|
247
261
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
248
262
|
#
|
249
263
|
# @param name [::String]
|
250
|
-
# Required. Resource name of the taxonomy to
|
251
|
-
#
|
264
|
+
# Required. Resource name of the taxonomy to delete.
|
265
|
+
#
|
266
|
+
# Note: All policy tags in this taxonomy are also deleted.
|
252
267
|
#
|
253
268
|
# @yield [response, operation] Access the result along with the RPC operation
|
254
269
|
# @yieldparam response [::Google::Protobuf::Empty]
|
@@ -258,6 +273,21 @@ module Google
|
|
258
273
|
#
|
259
274
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
260
275
|
#
|
276
|
+
# @example Basic example
|
277
|
+
# require "google/cloud/data_catalog/v1"
|
278
|
+
#
|
279
|
+
# # Create a client object. The client can be reused for multiple calls.
|
280
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
281
|
+
#
|
282
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
283
|
+
# request = Google::Cloud::DataCatalog::V1::DeleteTaxonomyRequest.new
|
284
|
+
#
|
285
|
+
# # Call the delete_taxonomy method.
|
286
|
+
# result = client.delete_taxonomy request
|
287
|
+
#
|
288
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
289
|
+
# p result
|
290
|
+
#
|
261
291
|
def delete_taxonomy request, options = nil
|
262
292
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
263
293
|
|
@@ -275,16 +305,20 @@ module Google
|
|
275
305
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
276
306
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
277
307
|
|
278
|
-
header_params = {
|
279
|
-
|
280
|
-
|
308
|
+
header_params = {}
|
309
|
+
if request.name
|
310
|
+
header_params["name"] = request.name
|
311
|
+
end
|
312
|
+
|
281
313
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
282
314
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
283
315
|
|
284
316
|
options.apply_defaults timeout: @config.rpcs.delete_taxonomy.timeout,
|
285
317
|
metadata: metadata,
|
286
318
|
retry_policy: @config.rpcs.delete_taxonomy.retry_policy
|
287
|
-
|
319
|
+
|
320
|
+
options.apply_defaults timeout: @config.timeout,
|
321
|
+
metadata: @config.metadata,
|
288
322
|
retry_policy: @config.retry_policy
|
289
323
|
|
290
324
|
@policy_tag_manager_stub.call_rpc :delete_taxonomy, request, options: options do |response, operation|
|
@@ -296,7 +330,7 @@ module Google
|
|
296
330
|
end
|
297
331
|
|
298
332
|
##
|
299
|
-
# Updates a taxonomy
|
333
|
+
# Updates a taxonomy, including its display name,
|
300
334
|
# description, and activated policy types.
|
301
335
|
#
|
302
336
|
# @overload update_taxonomy(request, options = nil)
|
@@ -315,13 +349,14 @@ module Google
|
|
315
349
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
316
350
|
#
|
317
351
|
# @param taxonomy [::Google::Cloud::DataCatalog::V1::Taxonomy, ::Hash]
|
318
|
-
# The taxonomy to update.
|
319
|
-
# policy types
|
352
|
+
# The taxonomy to update. You can update only its description, display name,
|
353
|
+
# and activated policy types.
|
320
354
|
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
321
|
-
#
|
322
|
-
#
|
323
|
-
#
|
324
|
-
#
|
355
|
+
# Specifies fields to update. If not set, defaults to all fields you can
|
356
|
+
# update.
|
357
|
+
#
|
358
|
+
# For more information, see [FieldMask]
|
359
|
+
# (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask).
|
325
360
|
#
|
326
361
|
# @yield [response, operation] Access the result along with the RPC operation
|
327
362
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::Taxonomy]
|
@@ -331,6 +366,21 @@ module Google
|
|
331
366
|
#
|
332
367
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
333
368
|
#
|
369
|
+
# @example Basic example
|
370
|
+
# require "google/cloud/data_catalog/v1"
|
371
|
+
#
|
372
|
+
# # Create a client object. The client can be reused for multiple calls.
|
373
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
374
|
+
#
|
375
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
376
|
+
# request = Google::Cloud::DataCatalog::V1::UpdateTaxonomyRequest.new
|
377
|
+
#
|
378
|
+
# # Call the update_taxonomy method.
|
379
|
+
# result = client.update_taxonomy request
|
380
|
+
#
|
381
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::Taxonomy.
|
382
|
+
# p result
|
383
|
+
#
|
334
384
|
def update_taxonomy request, options = nil
|
335
385
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
336
386
|
|
@@ -348,16 +398,20 @@ module Google
|
|
348
398
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
349
399
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
350
400
|
|
351
|
-
header_params = {
|
352
|
-
|
353
|
-
|
401
|
+
header_params = {}
|
402
|
+
if request.taxonomy&.name
|
403
|
+
header_params["taxonomy.name"] = request.taxonomy.name
|
404
|
+
end
|
405
|
+
|
354
406
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
355
407
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
356
408
|
|
357
409
|
options.apply_defaults timeout: @config.rpcs.update_taxonomy.timeout,
|
358
410
|
metadata: metadata,
|
359
411
|
retry_policy: @config.rpcs.update_taxonomy.retry_policy
|
360
|
-
|
412
|
+
|
413
|
+
options.apply_defaults timeout: @config.timeout,
|
414
|
+
metadata: @config.metadata,
|
361
415
|
retry_policy: @config.retry_policy
|
362
416
|
|
363
417
|
@policy_tag_manager_stub.call_rpc :update_taxonomy, request, options: options do |response, operation|
|
@@ -369,8 +423,8 @@ module Google
|
|
369
423
|
end
|
370
424
|
|
371
425
|
##
|
372
|
-
# Lists all taxonomies in a project in a particular location that
|
373
|
-
#
|
426
|
+
# Lists all taxonomies in a project in a particular location that you
|
427
|
+
# have a permission to view.
|
374
428
|
#
|
375
429
|
# @overload list_taxonomies(request, options = nil)
|
376
430
|
# Pass arguments to `list_taxonomies` via a request object, either of type
|
@@ -390,11 +444,13 @@ module Google
|
|
390
444
|
# @param parent [::String]
|
391
445
|
# Required. Resource name of the project to list the taxonomies of.
|
392
446
|
# @param page_size [::Integer]
|
393
|
-
# The maximum number of items to return. Must be a value between 1 and 1000
|
394
|
-
# If not set, defaults to 50.
|
447
|
+
# The maximum number of items to return. Must be a value between 1 and 1000
|
448
|
+
# inclusively. If not set, defaults to 50.
|
395
449
|
# @param page_token [::String]
|
396
|
-
# The
|
397
|
-
#
|
450
|
+
# The pagination token of the next results page. If not set,
|
451
|
+
# the first page is returned.
|
452
|
+
#
|
453
|
+
# The token is returned in the response to a previous list request.
|
398
454
|
#
|
399
455
|
# @yield [response, operation] Access the result along with the RPC operation
|
400
456
|
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::DataCatalog::V1::Taxonomy>]
|
@@ -404,6 +460,27 @@ module Google
|
|
404
460
|
#
|
405
461
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
406
462
|
#
|
463
|
+
# @example Basic example
|
464
|
+
# require "google/cloud/data_catalog/v1"
|
465
|
+
#
|
466
|
+
# # Create a client object. The client can be reused for multiple calls.
|
467
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
468
|
+
#
|
469
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
470
|
+
# request = Google::Cloud::DataCatalog::V1::ListTaxonomiesRequest.new
|
471
|
+
#
|
472
|
+
# # Call the list_taxonomies method.
|
473
|
+
# result = client.list_taxonomies request
|
474
|
+
#
|
475
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
476
|
+
# # iterate over all elements by calling #each, and the enumerable
|
477
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
478
|
+
# # methods are also available for managing paging directly.
|
479
|
+
# result.each do |response|
|
480
|
+
# # Each element is of type ::Google::Cloud::DataCatalog::V1::Taxonomy.
|
481
|
+
# p response
|
482
|
+
# end
|
483
|
+
#
|
407
484
|
def list_taxonomies request, options = nil
|
408
485
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
409
486
|
|
@@ -421,16 +498,20 @@ module Google
|
|
421
498
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
422
499
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
423
500
|
|
424
|
-
header_params = {
|
425
|
-
|
426
|
-
|
501
|
+
header_params = {}
|
502
|
+
if request.parent
|
503
|
+
header_params["parent"] = request.parent
|
504
|
+
end
|
505
|
+
|
427
506
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
428
507
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
429
508
|
|
430
509
|
options.apply_defaults timeout: @config.rpcs.list_taxonomies.timeout,
|
431
510
|
metadata: metadata,
|
432
511
|
retry_policy: @config.rpcs.list_taxonomies.retry_policy
|
433
|
-
|
512
|
+
|
513
|
+
options.apply_defaults timeout: @config.timeout,
|
514
|
+
metadata: @config.metadata,
|
434
515
|
retry_policy: @config.retry_policy
|
435
516
|
|
436
517
|
@policy_tag_manager_stub.call_rpc :list_taxonomies, request, options: options do |response, operation|
|
@@ -461,7 +542,7 @@ module Google
|
|
461
542
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
462
543
|
#
|
463
544
|
# @param name [::String]
|
464
|
-
# Required. Resource name of the
|
545
|
+
# Required. Resource name of the taxonomy to get.
|
465
546
|
#
|
466
547
|
# @yield [response, operation] Access the result along with the RPC operation
|
467
548
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::Taxonomy]
|
@@ -471,6 +552,21 @@ module Google
|
|
471
552
|
#
|
472
553
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
473
554
|
#
|
555
|
+
# @example Basic example
|
556
|
+
# require "google/cloud/data_catalog/v1"
|
557
|
+
#
|
558
|
+
# # Create a client object. The client can be reused for multiple calls.
|
559
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
560
|
+
#
|
561
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
562
|
+
# request = Google::Cloud::DataCatalog::V1::GetTaxonomyRequest.new
|
563
|
+
#
|
564
|
+
# # Call the get_taxonomy method.
|
565
|
+
# result = client.get_taxonomy request
|
566
|
+
#
|
567
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::Taxonomy.
|
568
|
+
# p result
|
569
|
+
#
|
474
570
|
def get_taxonomy request, options = nil
|
475
571
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
476
572
|
|
@@ -488,16 +584,20 @@ module Google
|
|
488
584
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
489
585
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
490
586
|
|
491
|
-
header_params = {
|
492
|
-
|
493
|
-
|
587
|
+
header_params = {}
|
588
|
+
if request.name
|
589
|
+
header_params["name"] = request.name
|
590
|
+
end
|
591
|
+
|
494
592
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
495
593
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
496
594
|
|
497
595
|
options.apply_defaults timeout: @config.rpcs.get_taxonomy.timeout,
|
498
596
|
metadata: metadata,
|
499
597
|
retry_policy: @config.rpcs.get_taxonomy.retry_policy
|
500
|
-
|
598
|
+
|
599
|
+
options.apply_defaults timeout: @config.timeout,
|
600
|
+
metadata: @config.metadata,
|
501
601
|
retry_policy: @config.retry_policy
|
502
602
|
|
503
603
|
@policy_tag_manager_stub.call_rpc :get_taxonomy, request, options: options do |response, operation|
|
@@ -527,9 +627,10 @@ module Google
|
|
527
627
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
528
628
|
#
|
529
629
|
# @param parent [::String]
|
530
|
-
# Required. Resource name of the taxonomy that the policy tag will belong to
|
630
|
+
# Required. Resource name of the taxonomy that the policy tag will belong to.<br /><br
|
631
|
+
# />
|
531
632
|
# @param policy_tag [::Google::Cloud::DataCatalog::V1::PolicyTag, ::Hash]
|
532
|
-
# The policy tag to
|
633
|
+
# The policy tag to create.
|
533
634
|
#
|
534
635
|
# @yield [response, operation] Access the result along with the RPC operation
|
535
636
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::PolicyTag]
|
@@ -539,6 +640,21 @@ module Google
|
|
539
640
|
#
|
540
641
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
541
642
|
#
|
643
|
+
# @example Basic example
|
644
|
+
# require "google/cloud/data_catalog/v1"
|
645
|
+
#
|
646
|
+
# # Create a client object. The client can be reused for multiple calls.
|
647
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
648
|
+
#
|
649
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
650
|
+
# request = Google::Cloud::DataCatalog::V1::CreatePolicyTagRequest.new
|
651
|
+
#
|
652
|
+
# # Call the create_policy_tag method.
|
653
|
+
# result = client.create_policy_tag request
|
654
|
+
#
|
655
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::PolicyTag.
|
656
|
+
# p result
|
657
|
+
#
|
542
658
|
def create_policy_tag request, options = nil
|
543
659
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
544
660
|
|
@@ -556,16 +672,20 @@ module Google
|
|
556
672
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
557
673
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
558
674
|
|
559
|
-
header_params = {
|
560
|
-
|
561
|
-
|
675
|
+
header_params = {}
|
676
|
+
if request.parent
|
677
|
+
header_params["parent"] = request.parent
|
678
|
+
end
|
679
|
+
|
562
680
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
563
681
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
564
682
|
|
565
683
|
options.apply_defaults timeout: @config.rpcs.create_policy_tag.timeout,
|
566
684
|
metadata: metadata,
|
567
685
|
retry_policy: @config.rpcs.create_policy_tag.retry_policy
|
568
|
-
|
686
|
+
|
687
|
+
options.apply_defaults timeout: @config.timeout,
|
688
|
+
metadata: @config.metadata,
|
569
689
|
retry_policy: @config.retry_policy
|
570
690
|
|
571
691
|
@policy_tag_manager_stub.call_rpc :create_policy_tag, request, options: options do |response, operation|
|
@@ -577,12 +697,12 @@ module Google
|
|
577
697
|
end
|
578
698
|
|
579
699
|
##
|
580
|
-
# Deletes a policy tag
|
700
|
+
# Deletes a policy tag together with the following:
|
581
701
|
#
|
582
|
-
# *
|
583
|
-
# *
|
584
|
-
# *
|
585
|
-
# descendants
|
702
|
+
# * All of its descendant policy tags, if any
|
703
|
+
# * Policies associated with the policy tag and its descendants
|
704
|
+
# * References from BigQuery table schema of the policy tag and its
|
705
|
+
# descendants
|
586
706
|
#
|
587
707
|
# @overload delete_policy_tag(request, options = nil)
|
588
708
|
# Pass arguments to `delete_policy_tag` via a request object, either of type
|
@@ -600,8 +720,9 @@ module Google
|
|
600
720
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
601
721
|
#
|
602
722
|
# @param name [::String]
|
603
|
-
# Required. Resource name of the policy tag to
|
604
|
-
#
|
723
|
+
# Required. Resource name of the policy tag to delete.
|
724
|
+
#
|
725
|
+
# Note: All of its descendant policy tags are also deleted.
|
605
726
|
#
|
606
727
|
# @yield [response, operation] Access the result along with the RPC operation
|
607
728
|
# @yieldparam response [::Google::Protobuf::Empty]
|
@@ -611,6 +732,21 @@ module Google
|
|
611
732
|
#
|
612
733
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
613
734
|
#
|
735
|
+
# @example Basic example
|
736
|
+
# require "google/cloud/data_catalog/v1"
|
737
|
+
#
|
738
|
+
# # Create a client object. The client can be reused for multiple calls.
|
739
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
740
|
+
#
|
741
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
742
|
+
# request = Google::Cloud::DataCatalog::V1::DeletePolicyTagRequest.new
|
743
|
+
#
|
744
|
+
# # Call the delete_policy_tag method.
|
745
|
+
# result = client.delete_policy_tag request
|
746
|
+
#
|
747
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
748
|
+
# p result
|
749
|
+
#
|
614
750
|
def delete_policy_tag request, options = nil
|
615
751
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
616
752
|
|
@@ -628,16 +764,20 @@ module Google
|
|
628
764
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
629
765
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
630
766
|
|
631
|
-
header_params = {
|
632
|
-
|
633
|
-
|
767
|
+
header_params = {}
|
768
|
+
if request.name
|
769
|
+
header_params["name"] = request.name
|
770
|
+
end
|
771
|
+
|
634
772
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
635
773
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
636
774
|
|
637
775
|
options.apply_defaults timeout: @config.rpcs.delete_policy_tag.timeout,
|
638
776
|
metadata: metadata,
|
639
777
|
retry_policy: @config.rpcs.delete_policy_tag.retry_policy
|
640
|
-
|
778
|
+
|
779
|
+
options.apply_defaults timeout: @config.timeout,
|
780
|
+
metadata: @config.metadata,
|
641
781
|
retry_policy: @config.retry_policy
|
642
782
|
|
643
783
|
@policy_tag_manager_stub.call_rpc :delete_policy_tag, request, options: options do |response, operation|
|
@@ -649,7 +789,7 @@ module Google
|
|
649
789
|
end
|
650
790
|
|
651
791
|
##
|
652
|
-
# Updates a policy tag
|
792
|
+
# Updates a policy tag, including its display
|
653
793
|
# name, description, and parent policy tag.
|
654
794
|
#
|
655
795
|
# @overload update_policy_tag(request, options = nil)
|
@@ -668,16 +808,15 @@ module Google
|
|
668
808
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
669
809
|
#
|
670
810
|
# @param policy_tag [::Google::Cloud::DataCatalog::V1::PolicyTag, ::Hash]
|
671
|
-
# The policy tag to update.
|
672
|
-
#
|
811
|
+
# The policy tag to update. You can update only its description, display
|
812
|
+
# name, and parent policy tag fields.
|
673
813
|
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
674
|
-
#
|
675
|
-
#
|
676
|
-
#
|
677
|
-
#
|
678
|
-
#
|
679
|
-
# https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask
|
680
|
-
# If not set, defaults to all of the fields that are allowed to update.
|
814
|
+
# Specifies the fields to update.
|
815
|
+
#
|
816
|
+
# You can update only display name, description, and parent policy tag.
|
817
|
+
# If not set, defaults to all updatable fields.
|
818
|
+
# For more information, see [FieldMask]
|
819
|
+
# (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask).
|
681
820
|
#
|
682
821
|
# @yield [response, operation] Access the result along with the RPC operation
|
683
822
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::PolicyTag]
|
@@ -687,6 +826,21 @@ module Google
|
|
687
826
|
#
|
688
827
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
689
828
|
#
|
829
|
+
# @example Basic example
|
830
|
+
# require "google/cloud/data_catalog/v1"
|
831
|
+
#
|
832
|
+
# # Create a client object. The client can be reused for multiple calls.
|
833
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
834
|
+
#
|
835
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
836
|
+
# request = Google::Cloud::DataCatalog::V1::UpdatePolicyTagRequest.new
|
837
|
+
#
|
838
|
+
# # Call the update_policy_tag method.
|
839
|
+
# result = client.update_policy_tag request
|
840
|
+
#
|
841
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::PolicyTag.
|
842
|
+
# p result
|
843
|
+
#
|
690
844
|
def update_policy_tag request, options = nil
|
691
845
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
692
846
|
|
@@ -704,16 +858,20 @@ module Google
|
|
704
858
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
705
859
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
706
860
|
|
707
|
-
header_params = {
|
708
|
-
|
709
|
-
|
861
|
+
header_params = {}
|
862
|
+
if request.policy_tag&.name
|
863
|
+
header_params["policy_tag.name"] = request.policy_tag.name
|
864
|
+
end
|
865
|
+
|
710
866
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
711
867
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
712
868
|
|
713
869
|
options.apply_defaults timeout: @config.rpcs.update_policy_tag.timeout,
|
714
870
|
metadata: metadata,
|
715
871
|
retry_policy: @config.rpcs.update_policy_tag.retry_policy
|
716
|
-
|
872
|
+
|
873
|
+
options.apply_defaults timeout: @config.timeout,
|
874
|
+
metadata: @config.metadata,
|
717
875
|
retry_policy: @config.retry_policy
|
718
876
|
|
719
877
|
@policy_tag_manager_stub.call_rpc :update_policy_tag, request, options: options do |response, operation|
|
@@ -745,11 +903,14 @@ module Google
|
|
745
903
|
# @param parent [::String]
|
746
904
|
# Required. Resource name of the taxonomy to list the policy tags of.
|
747
905
|
# @param page_size [::Integer]
|
748
|
-
# The maximum number of items to return. Must be a value between 1 and 1000
|
906
|
+
# The maximum number of items to return. Must be a value between 1 and 1000
|
907
|
+
# inclusively.
|
749
908
|
# If not set, defaults to 50.
|
750
909
|
# @param page_token [::String]
|
751
|
-
# The
|
752
|
-
#
|
910
|
+
# The pagination token of the next results page. If not set, returns the
|
911
|
+
# first page.
|
912
|
+
#
|
913
|
+
# The token is returned in the response to a previous list request.
|
753
914
|
#
|
754
915
|
# @yield [response, operation] Access the result along with the RPC operation
|
755
916
|
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::DataCatalog::V1::PolicyTag>]
|
@@ -759,6 +920,27 @@ module Google
|
|
759
920
|
#
|
760
921
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
761
922
|
#
|
923
|
+
# @example Basic example
|
924
|
+
# require "google/cloud/data_catalog/v1"
|
925
|
+
#
|
926
|
+
# # Create a client object. The client can be reused for multiple calls.
|
927
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
928
|
+
#
|
929
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
930
|
+
# request = Google::Cloud::DataCatalog::V1::ListPolicyTagsRequest.new
|
931
|
+
#
|
932
|
+
# # Call the list_policy_tags method.
|
933
|
+
# result = client.list_policy_tags request
|
934
|
+
#
|
935
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
936
|
+
# # iterate over all elements by calling #each, and the enumerable
|
937
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
938
|
+
# # methods are also available for managing paging directly.
|
939
|
+
# result.each do |response|
|
940
|
+
# # Each element is of type ::Google::Cloud::DataCatalog::V1::PolicyTag.
|
941
|
+
# p response
|
942
|
+
# end
|
943
|
+
#
|
762
944
|
def list_policy_tags request, options = nil
|
763
945
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
764
946
|
|
@@ -776,16 +958,20 @@ module Google
|
|
776
958
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
777
959
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
778
960
|
|
779
|
-
header_params = {
|
780
|
-
|
781
|
-
|
961
|
+
header_params = {}
|
962
|
+
if request.parent
|
963
|
+
header_params["parent"] = request.parent
|
964
|
+
end
|
965
|
+
|
782
966
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
783
967
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
784
968
|
|
785
969
|
options.apply_defaults timeout: @config.rpcs.list_policy_tags.timeout,
|
786
970
|
metadata: metadata,
|
787
971
|
retry_policy: @config.rpcs.list_policy_tags.retry_policy
|
788
|
-
|
972
|
+
|
973
|
+
options.apply_defaults timeout: @config.timeout,
|
974
|
+
metadata: @config.metadata,
|
789
975
|
retry_policy: @config.retry_policy
|
790
976
|
|
791
977
|
@policy_tag_manager_stub.call_rpc :list_policy_tags, request, options: options do |response, operation|
|
@@ -816,7 +1002,7 @@ module Google
|
|
816
1002
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
817
1003
|
#
|
818
1004
|
# @param name [::String]
|
819
|
-
# Required. Resource name of the
|
1005
|
+
# Required. Resource name of the policy tag.
|
820
1006
|
#
|
821
1007
|
# @yield [response, operation] Access the result along with the RPC operation
|
822
1008
|
# @yieldparam response [::Google::Cloud::DataCatalog::V1::PolicyTag]
|
@@ -826,6 +1012,21 @@ module Google
|
|
826
1012
|
#
|
827
1013
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
828
1014
|
#
|
1015
|
+
# @example Basic example
|
1016
|
+
# require "google/cloud/data_catalog/v1"
|
1017
|
+
#
|
1018
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1019
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
1020
|
+
#
|
1021
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1022
|
+
# request = Google::Cloud::DataCatalog::V1::GetPolicyTagRequest.new
|
1023
|
+
#
|
1024
|
+
# # Call the get_policy_tag method.
|
1025
|
+
# result = client.get_policy_tag request
|
1026
|
+
#
|
1027
|
+
# # The returned object is of type Google::Cloud::DataCatalog::V1::PolicyTag.
|
1028
|
+
# p result
|
1029
|
+
#
|
829
1030
|
def get_policy_tag request, options = nil
|
830
1031
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
831
1032
|
|
@@ -843,16 +1044,20 @@ module Google
|
|
843
1044
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
844
1045
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
845
1046
|
|
846
|
-
header_params = {
|
847
|
-
|
848
|
-
|
1047
|
+
header_params = {}
|
1048
|
+
if request.name
|
1049
|
+
header_params["name"] = request.name
|
1050
|
+
end
|
1051
|
+
|
849
1052
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
850
1053
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
851
1054
|
|
852
1055
|
options.apply_defaults timeout: @config.rpcs.get_policy_tag.timeout,
|
853
1056
|
metadata: metadata,
|
854
1057
|
retry_policy: @config.rpcs.get_policy_tag.retry_policy
|
855
|
-
|
1058
|
+
|
1059
|
+
options.apply_defaults timeout: @config.timeout,
|
1060
|
+
metadata: @config.metadata,
|
856
1061
|
retry_policy: @config.retry_policy
|
857
1062
|
|
858
1063
|
@policy_tag_manager_stub.call_rpc :get_policy_tag, request, options: options do |response, operation|
|
@@ -896,6 +1101,21 @@ module Google
|
|
896
1101
|
#
|
897
1102
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
898
1103
|
#
|
1104
|
+
# @example Basic example
|
1105
|
+
# require "google/cloud/data_catalog/v1"
|
1106
|
+
#
|
1107
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1108
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
1109
|
+
#
|
1110
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1111
|
+
# request = Google::Iam::V1::GetIamPolicyRequest.new
|
1112
|
+
#
|
1113
|
+
# # Call the get_iam_policy method.
|
1114
|
+
# result = client.get_iam_policy request
|
1115
|
+
#
|
1116
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
1117
|
+
# p result
|
1118
|
+
#
|
899
1119
|
def get_iam_policy request, options = nil
|
900
1120
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
901
1121
|
|
@@ -913,16 +1133,20 @@ module Google
|
|
913
1133
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
914
1134
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
915
1135
|
|
916
|
-
header_params = {
|
917
|
-
|
918
|
-
|
1136
|
+
header_params = {}
|
1137
|
+
if request.resource
|
1138
|
+
header_params["resource"] = request.resource
|
1139
|
+
end
|
1140
|
+
|
919
1141
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
920
1142
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
921
1143
|
|
922
1144
|
options.apply_defaults timeout: @config.rpcs.get_iam_policy.timeout,
|
923
1145
|
metadata: metadata,
|
924
1146
|
retry_policy: @config.rpcs.get_iam_policy.retry_policy
|
925
|
-
|
1147
|
+
|
1148
|
+
options.apply_defaults timeout: @config.timeout,
|
1149
|
+
metadata: @config.metadata,
|
926
1150
|
retry_policy: @config.retry_policy
|
927
1151
|
|
928
1152
|
@policy_tag_manager_stub.call_rpc :get_iam_policy, request, options: options do |response, operation|
|
@@ -968,6 +1192,21 @@ module Google
|
|
968
1192
|
#
|
969
1193
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
970
1194
|
#
|
1195
|
+
# @example Basic example
|
1196
|
+
# require "google/cloud/data_catalog/v1"
|
1197
|
+
#
|
1198
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1199
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
1200
|
+
#
|
1201
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1202
|
+
# request = Google::Iam::V1::SetIamPolicyRequest.new
|
1203
|
+
#
|
1204
|
+
# # Call the set_iam_policy method.
|
1205
|
+
# result = client.set_iam_policy request
|
1206
|
+
#
|
1207
|
+
# # The returned object is of type Google::Iam::V1::Policy.
|
1208
|
+
# p result
|
1209
|
+
#
|
971
1210
|
def set_iam_policy request, options = nil
|
972
1211
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
973
1212
|
|
@@ -985,16 +1224,20 @@ module Google
|
|
985
1224
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
986
1225
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
987
1226
|
|
988
|
-
header_params = {
|
989
|
-
|
990
|
-
|
1227
|
+
header_params = {}
|
1228
|
+
if request.resource
|
1229
|
+
header_params["resource"] = request.resource
|
1230
|
+
end
|
1231
|
+
|
991
1232
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
992
1233
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
993
1234
|
|
994
1235
|
options.apply_defaults timeout: @config.rpcs.set_iam_policy.timeout,
|
995
1236
|
metadata: metadata,
|
996
1237
|
retry_policy: @config.rpcs.set_iam_policy.retry_policy
|
997
|
-
|
1238
|
+
|
1239
|
+
options.apply_defaults timeout: @config.timeout,
|
1240
|
+
metadata: @config.metadata,
|
998
1241
|
retry_policy: @config.retry_policy
|
999
1242
|
|
1000
1243
|
@policy_tag_manager_stub.call_rpc :set_iam_policy, request, options: options do |response, operation|
|
@@ -1006,7 +1249,7 @@ module Google
|
|
1006
1249
|
end
|
1007
1250
|
|
1008
1251
|
##
|
1009
|
-
# Returns
|
1252
|
+
# Returns your permissions on a specified policy tag or
|
1010
1253
|
# taxonomy.
|
1011
1254
|
#
|
1012
1255
|
# @overload test_iam_permissions(request, options = nil)
|
@@ -1041,6 +1284,21 @@ module Google
|
|
1041
1284
|
#
|
1042
1285
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1043
1286
|
#
|
1287
|
+
# @example Basic example
|
1288
|
+
# require "google/cloud/data_catalog/v1"
|
1289
|
+
#
|
1290
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1291
|
+
# client = Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new
|
1292
|
+
#
|
1293
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1294
|
+
# request = Google::Iam::V1::TestIamPermissionsRequest.new
|
1295
|
+
#
|
1296
|
+
# # Call the test_iam_permissions method.
|
1297
|
+
# result = client.test_iam_permissions request
|
1298
|
+
#
|
1299
|
+
# # The returned object is of type Google::Iam::V1::TestIamPermissionsResponse.
|
1300
|
+
# p result
|
1301
|
+
#
|
1044
1302
|
def test_iam_permissions request, options = nil
|
1045
1303
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1046
1304
|
|
@@ -1058,16 +1316,20 @@ module Google
|
|
1058
1316
|
gapic_version: ::Google::Cloud::DataCatalog::V1::VERSION
|
1059
1317
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1060
1318
|
|
1061
|
-
header_params = {
|
1062
|
-
|
1063
|
-
|
1319
|
+
header_params = {}
|
1320
|
+
if request.resource
|
1321
|
+
header_params["resource"] = request.resource
|
1322
|
+
end
|
1323
|
+
|
1064
1324
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1065
1325
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1066
1326
|
|
1067
1327
|
options.apply_defaults timeout: @config.rpcs.test_iam_permissions.timeout,
|
1068
1328
|
metadata: metadata,
|
1069
1329
|
retry_policy: @config.rpcs.test_iam_permissions.retry_policy
|
1070
|
-
|
1330
|
+
|
1331
|
+
options.apply_defaults timeout: @config.timeout,
|
1332
|
+
metadata: @config.metadata,
|
1071
1333
|
retry_policy: @config.retry_policy
|
1072
1334
|
|
1073
1335
|
@policy_tag_manager_stub.call_rpc :test_iam_permissions, request, options: options do |response, operation|
|
@@ -1091,22 +1353,21 @@ module Google
|
|
1091
1353
|
# Configuration can be applied globally to all clients, or to a single client
|
1092
1354
|
# on construction.
|
1093
1355
|
#
|
1094
|
-
#
|
1095
|
-
#
|
1096
|
-
#
|
1097
|
-
# to 20 seconds,
|
1098
|
-
#
|
1099
|
-
#
|
1100
|
-
#
|
1101
|
-
#
|
1102
|
-
#
|
1103
|
-
#
|
1104
|
-
#
|
1105
|
-
#
|
1106
|
-
#
|
1107
|
-
#
|
1108
|
-
#
|
1109
|
-
# end
|
1356
|
+
# @example
|
1357
|
+
#
|
1358
|
+
# # Modify the global config, setting the timeout for
|
1359
|
+
# # create_taxonomy to 20 seconds,
|
1360
|
+
# # and all remaining timeouts to 10 seconds.
|
1361
|
+
# ::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.configure do |config|
|
1362
|
+
# config.timeout = 10.0
|
1363
|
+
# config.rpcs.create_taxonomy.timeout = 20.0
|
1364
|
+
# end
|
1365
|
+
#
|
1366
|
+
# # Apply the above configuration only to a new client.
|
1367
|
+
# client = ::Google::Cloud::DataCatalog::V1::PolicyTagManager::Client.new do |config|
|
1368
|
+
# config.timeout = 10.0
|
1369
|
+
# config.rpcs.create_taxonomy.timeout = 20.0
|
1370
|
+
# end
|
1110
1371
|
#
|
1111
1372
|
# @!attribute [rw] endpoint
|
1112
1373
|
# The hostname or hostname:port of the service endpoint.
|