google-cloud-retail-v2 0.4.1 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1dc44cab7183e8c99dcff0174ca915af53d47e792de193605d4333dd65777ced
4
- data.tar.gz: 31deb9ad3ab11a76193b85fe3bc30c39eaa372dda44dd1b83c12a01a89e9e06c
3
+ metadata.gz: b07d919181d8706e180a703f7cecd52fb464e69cfa4fd0ede43cf5b351a0e88e
4
+ data.tar.gz: 04bee385524f62ef1d40025669309f5d094b228e5ec833805baad6bacd1d2365
5
5
  SHA512:
6
- metadata.gz: 8925f2040c7b54c45d4dc158735550f20cda1aacbf42b6e46e7abc02dcab586921cd2744b6b44573dd0fbe3164cfab9e5432ecb55a81c9275321337e3a654515
7
- data.tar.gz: 502150bb18dbb2fdbb9ba9911d1e6e1272c80506feb6a625bb4ac335d5fdfbfa5b62d901385dc115c0921dbcfd092b35219c44709e9cb1904d1ba02dd4ace9a9
6
+ metadata.gz: f41c60eb5f15c54e8f4ac41a94be47f87013ece357de71a7699a3b6a8af7ddb0f5d955092c446df68c06ea1aad20d162aca6aa5785680ecf619af408e494a284
7
+ data.tar.gz: 536710d9c52c19162bc9a2effd65d2f7861b1b81a50ad3c659a4b1d4034a9acbfbcdb4a205a4de36df434a338ceb076ee68de0566cc29d259449568d876c557f
@@ -41,13 +41,12 @@ module Google
41
41
  # See {::Google::Cloud::Retail::V2::CatalogService::Client::Configuration}
42
42
  # for a description of the configuration fields.
43
43
  #
44
- # ## Example
44
+ # @example
45
45
  #
46
- # To modify the configuration for all CatalogService clients:
47
- #
48
- # ::Google::Cloud::Retail::V2::CatalogService::Client.configure do |config|
49
- # config.timeout = 10.0
50
- # end
46
+ # # Modify the configuration for all CatalogService clients
47
+ # ::Google::Cloud::Retail::V2::CatalogService::Client.configure do |config|
48
+ # config.timeout = 10.0
49
+ # end
51
50
  #
52
51
  # @yield [config] Configure the Client client.
53
52
  # @yieldparam config [Client::Configuration]
@@ -99,19 +98,15 @@ module Google
99
98
  ##
100
99
  # Create a new CatalogService client object.
101
100
  #
102
- # ## Examples
103
- #
104
- # To create a new CatalogService client with the default
105
- # configuration:
106
- #
107
- # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new
101
+ # @example
108
102
  #
109
- # To create a new CatalogService client with a custom
110
- # configuration:
103
+ # # Create a client using the default configuration
104
+ # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new
111
105
  #
112
- # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new do |config|
113
- # config.timeout = 10.0
114
- # end
106
+ # # Create a client using a custom configuration
107
+ # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new do |config|
108
+ # config.timeout = 10.0
109
+ # end
115
110
  #
116
111
  # @yield [config] Configure the CatalogService client.
117
112
  # @yieldparam config [Client::Configuration]
@@ -131,10 +126,9 @@ module Google
131
126
 
132
127
  # Create credentials
133
128
  credentials = @config.credentials
134
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
129
+ # Use self-signed JWT if the endpoint is unchanged from default,
135
130
  # but only if the default endpoint does not have a region prefix.
136
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
137
- @config.endpoint == Client.configure.endpoint &&
131
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
138
132
  !@config.endpoint.split(".").first.include?("-")
139
133
  credentials ||= Credentials.default scope: @config.scope,
140
134
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -233,7 +227,9 @@ module Google
233
227
  options.apply_defaults timeout: @config.rpcs.list_catalogs.timeout,
234
228
  metadata: metadata,
235
229
  retry_policy: @config.rpcs.list_catalogs.retry_policy
236
- options.apply_defaults metadata: @config.metadata,
230
+
231
+ options.apply_defaults timeout: @config.timeout,
232
+ metadata: @config.metadata,
237
233
  retry_policy: @config.retry_policy
238
234
 
239
235
  @catalog_service_stub.call_rpc :list_catalogs, request, options: options do |response, operation|
@@ -313,7 +309,9 @@ module Google
313
309
  options.apply_defaults timeout: @config.rpcs.update_catalog.timeout,
314
310
  metadata: metadata,
315
311
  retry_policy: @config.rpcs.update_catalog.retry_policy
316
- options.apply_defaults metadata: @config.metadata,
312
+
313
+ options.apply_defaults timeout: @config.timeout,
314
+ metadata: @config.metadata,
317
315
  retry_policy: @config.retry_policy
318
316
 
319
317
  @catalog_service_stub.call_rpc :update_catalog, request, options: options do |response, operation|
@@ -428,7 +426,9 @@ module Google
428
426
  options.apply_defaults timeout: @config.rpcs.set_default_branch.timeout,
429
427
  metadata: metadata,
430
428
  retry_policy: @config.rpcs.set_default_branch.retry_policy
431
- options.apply_defaults metadata: @config.metadata,
429
+
430
+ options.apply_defaults timeout: @config.timeout,
431
+ metadata: @config.metadata,
432
432
  retry_policy: @config.retry_policy
433
433
 
434
434
  @catalog_service_stub.call_rpc :set_default_branch, request, options: options do |response, operation|
@@ -501,7 +501,9 @@ module Google
501
501
  options.apply_defaults timeout: @config.rpcs.get_default_branch.timeout,
502
502
  metadata: metadata,
503
503
  retry_policy: @config.rpcs.get_default_branch.retry_policy
504
- options.apply_defaults metadata: @config.metadata,
504
+
505
+ options.apply_defaults timeout: @config.timeout,
506
+ metadata: @config.metadata,
505
507
  retry_policy: @config.retry_policy
506
508
 
507
509
  @catalog_service_stub.call_rpc :get_default_branch, request, options: options do |response, operation|
@@ -525,22 +527,21 @@ module Google
525
527
  # Configuration can be applied globally to all clients, or to a single client
526
528
  # on construction.
527
529
  #
528
- # # Examples
529
- #
530
- # To modify the global config, setting the timeout for list_catalogs
531
- # to 20 seconds, and all remaining timeouts to 10 seconds:
532
- #
533
- # ::Google::Cloud::Retail::V2::CatalogService::Client.configure do |config|
534
- # config.timeout = 10.0
535
- # config.rpcs.list_catalogs.timeout = 20.0
536
- # end
537
- #
538
- # To apply the above configuration only to a new client:
539
- #
540
- # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new do |config|
541
- # config.timeout = 10.0
542
- # config.rpcs.list_catalogs.timeout = 20.0
543
- # end
530
+ # @example
531
+ #
532
+ # # Modify the global config, setting the timeout for
533
+ # # list_catalogs to 20 seconds,
534
+ # # and all remaining timeouts to 10 seconds.
535
+ # ::Google::Cloud::Retail::V2::CatalogService::Client.configure do |config|
536
+ # config.timeout = 10.0
537
+ # config.rpcs.list_catalogs.timeout = 20.0
538
+ # end
539
+ #
540
+ # # Apply the above configuration only to a new client.
541
+ # client = ::Google::Cloud::Retail::V2::CatalogService::Client.new do |config|
542
+ # config.timeout = 10.0
543
+ # config.rpcs.list_catalogs.timeout = 20.0
544
+ # end
544
545
  #
545
546
  # @!attribute [rw] endpoint
546
547
  # The hostname or hostname:port of the service endpoint.
@@ -45,13 +45,12 @@ module Google
45
45
  # See {::Google::Cloud::Retail::V2::CompletionService::Client::Configuration}
46
46
  # for a description of the configuration fields.
47
47
  #
48
- # ## Example
48
+ # @example
49
49
  #
50
- # To modify the configuration for all CompletionService clients:
51
- #
52
- # ::Google::Cloud::Retail::V2::CompletionService::Client.configure do |config|
53
- # config.timeout = 10.0
54
- # end
50
+ # # Modify the configuration for all CompletionService clients
51
+ # ::Google::Cloud::Retail::V2::CompletionService::Client.configure do |config|
52
+ # config.timeout = 10.0
53
+ # end
55
54
  #
56
55
  # @yield [config] Configure the Client client.
57
56
  # @yieldparam config [Client::Configuration]
@@ -103,19 +102,15 @@ module Google
103
102
  ##
104
103
  # Create a new CompletionService client object.
105
104
  #
106
- # ## Examples
107
- #
108
- # To create a new CompletionService client with the default
109
- # configuration:
110
- #
111
- # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new
105
+ # @example
112
106
  #
113
- # To create a new CompletionService client with a custom
114
- # configuration:
107
+ # # Create a client using the default configuration
108
+ # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new
115
109
  #
116
- # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new do |config|
117
- # config.timeout = 10.0
118
- # end
110
+ # # Create a client using a custom configuration
111
+ # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new do |config|
112
+ # config.timeout = 10.0
113
+ # end
119
114
  #
120
115
  # @yield [config] Configure the CompletionService client.
121
116
  # @yieldparam config [Client::Configuration]
@@ -135,10 +130,9 @@ module Google
135
130
 
136
131
  # Create credentials
137
132
  credentials = @config.credentials
138
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
133
+ # Use self-signed JWT if the endpoint is unchanged from default,
139
134
  # but only if the default endpoint does not have a region prefix.
140
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
141
- @config.endpoint == Client.configure.endpoint &&
135
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
142
136
  !@config.endpoint.split(".").first.include?("-")
143
137
  credentials ||= Credentials.default scope: @config.scope,
144
138
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -286,7 +280,9 @@ module Google
286
280
  options.apply_defaults timeout: @config.rpcs.complete_query.timeout,
287
281
  metadata: metadata,
288
282
  retry_policy: @config.rpcs.complete_query.retry_policy
289
- options.apply_defaults metadata: @config.metadata,
283
+
284
+ options.apply_defaults timeout: @config.timeout,
285
+ metadata: @config.metadata,
290
286
  retry_policy: @config.retry_policy
291
287
 
292
288
  @completion_service_stub.call_rpc :complete_query, request, options: options do |response, operation|
@@ -368,7 +364,9 @@ module Google
368
364
  options.apply_defaults timeout: @config.rpcs.import_completion_data.timeout,
369
365
  metadata: metadata,
370
366
  retry_policy: @config.rpcs.import_completion_data.retry_policy
371
- options.apply_defaults metadata: @config.metadata,
367
+
368
+ options.apply_defaults timeout: @config.timeout,
369
+ metadata: @config.metadata,
372
370
  retry_policy: @config.retry_policy
373
371
 
374
372
  @completion_service_stub.call_rpc :import_completion_data, request, options: options do |response, operation|
@@ -393,22 +391,21 @@ module Google
393
391
  # Configuration can be applied globally to all clients, or to a single client
394
392
  # on construction.
395
393
  #
396
- # # Examples
397
- #
398
- # To modify the global config, setting the timeout for complete_query
399
- # to 20 seconds, and all remaining timeouts to 10 seconds:
400
- #
401
- # ::Google::Cloud::Retail::V2::CompletionService::Client.configure do |config|
402
- # config.timeout = 10.0
403
- # config.rpcs.complete_query.timeout = 20.0
404
- # end
405
- #
406
- # To apply the above configuration only to a new client:
407
- #
408
- # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new do |config|
409
- # config.timeout = 10.0
410
- # config.rpcs.complete_query.timeout = 20.0
411
- # end
394
+ # @example
395
+ #
396
+ # # Modify the global config, setting the timeout for
397
+ # # complete_query to 20 seconds,
398
+ # # and all remaining timeouts to 10 seconds.
399
+ # ::Google::Cloud::Retail::V2::CompletionService::Client.configure do |config|
400
+ # config.timeout = 10.0
401
+ # config.rpcs.complete_query.timeout = 20.0
402
+ # end
403
+ #
404
+ # # Apply the above configuration only to a new client.
405
+ # client = ::Google::Cloud::Retail::V2::CompletionService::Client.new do |config|
406
+ # config.timeout = 10.0
407
+ # config.rpcs.complete_query.timeout = 20.0
408
+ # end
412
409
  #
413
410
  # @!attribute [rw] endpoint
414
411
  # The hostname or hostname:port of the service endpoint.
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -41,13 +41,12 @@ module Google
41
41
  # See {::Google::Cloud::Retail::V2::PredictionService::Client::Configuration}
42
42
  # for a description of the configuration fields.
43
43
  #
44
- # ## Example
44
+ # @example
45
45
  #
46
- # To modify the configuration for all PredictionService clients:
47
- #
48
- # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
49
- # config.timeout = 10.0
50
- # end
46
+ # # Modify the configuration for all PredictionService clients
47
+ # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
48
+ # config.timeout = 10.0
49
+ # end
51
50
  #
52
51
  # @yield [config] Configure the Client client.
53
52
  # @yieldparam config [Client::Configuration]
@@ -99,19 +98,15 @@ module Google
99
98
  ##
100
99
  # Create a new PredictionService client object.
101
100
  #
102
- # ## Examples
103
- #
104
- # To create a new PredictionService client with the default
105
- # configuration:
101
+ # @example
106
102
  #
107
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new
103
+ # # Create a client using the default configuration
104
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new
108
105
  #
109
- # To create a new PredictionService client with a custom
110
- # configuration:
111
- #
112
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
113
- # config.timeout = 10.0
114
- # end
106
+ # # Create a client using a custom configuration
107
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
108
+ # config.timeout = 10.0
109
+ # end
115
110
  #
116
111
  # @yield [config] Configure the PredictionService client.
117
112
  # @yieldparam config [Client::Configuration]
@@ -131,10 +126,9 @@ module Google
131
126
 
132
127
  # Create credentials
133
128
  credentials = @config.credentials
134
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
129
+ # Use self-signed JWT if the endpoint is unchanged from default,
135
130
  # but only if the default endpoint does not have a region prefix.
136
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
137
- @config.endpoint == Client.configure.endpoint &&
131
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
138
132
  !@config.endpoint.split(".").first.include?("-")
139
133
  credentials ||= Credentials.default scope: @config.scope,
140
134
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -306,7 +300,9 @@ module Google
306
300
  options.apply_defaults timeout: @config.rpcs.predict.timeout,
307
301
  metadata: metadata,
308
302
  retry_policy: @config.rpcs.predict.retry_policy
309
- options.apply_defaults metadata: @config.metadata,
303
+
304
+ options.apply_defaults timeout: @config.timeout,
305
+ metadata: @config.metadata,
310
306
  retry_policy: @config.retry_policy
311
307
 
312
308
  @prediction_service_stub.call_rpc :predict, request, options: options do |response, operation|
@@ -330,22 +326,21 @@ module Google
330
326
  # Configuration can be applied globally to all clients, or to a single client
331
327
  # on construction.
332
328
  #
333
- # # Examples
334
- #
335
- # To modify the global config, setting the timeout for predict
336
- # to 20 seconds, and all remaining timeouts to 10 seconds:
337
- #
338
- # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
339
- # config.timeout = 10.0
340
- # config.rpcs.predict.timeout = 20.0
341
- # end
342
- #
343
- # To apply the above configuration only to a new client:
344
- #
345
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
346
- # config.timeout = 10.0
347
- # config.rpcs.predict.timeout = 20.0
348
- # end
329
+ # @example
330
+ #
331
+ # # Modify the global config, setting the timeout for
332
+ # # predict to 20 seconds,
333
+ # # and all remaining timeouts to 10 seconds.
334
+ # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
335
+ # config.timeout = 10.0
336
+ # config.rpcs.predict.timeout = 20.0
337
+ # end
338
+ #
339
+ # # Apply the above configuration only to a new client.
340
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
341
+ # config.timeout = 10.0
342
+ # config.rpcs.predict.timeout = 20.0
343
+ # end
349
344
  #
350
345
  # @!attribute [rw] endpoint
351
346
  # The hostname or hostname:port of the service endpoint.
@@ -42,13 +42,12 @@ module Google
42
42
  # See {::Google::Cloud::Retail::V2::ProductService::Client::Configuration}
43
43
  # for a description of the configuration fields.
44
44
  #
45
- # ## Example
45
+ # @example
46
46
  #
47
- # To modify the configuration for all ProductService clients:
48
- #
49
- # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
50
- # config.timeout = 10.0
51
- # end
47
+ # # Modify the configuration for all ProductService clients
48
+ # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
49
+ # config.timeout = 10.0
50
+ # end
52
51
  #
53
52
  # @yield [config] Configure the Client client.
54
53
  # @yieldparam config [Client::Configuration]
@@ -100,19 +99,15 @@ module Google
100
99
  ##
101
100
  # Create a new ProductService client object.
102
101
  #
103
- # ## Examples
104
- #
105
- # To create a new ProductService client with the default
106
- # configuration:
102
+ # @example
107
103
  #
108
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new
104
+ # # Create a client using the default configuration
105
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new
109
106
  #
110
- # To create a new ProductService client with a custom
111
- # configuration:
112
- #
113
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
114
- # config.timeout = 10.0
115
- # end
107
+ # # Create a client using a custom configuration
108
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
109
+ # config.timeout = 10.0
110
+ # end
116
111
  #
117
112
  # @yield [config] Configure the ProductService client.
118
113
  # @yieldparam config [Client::Configuration]
@@ -132,10 +127,9 @@ module Google
132
127
 
133
128
  # Create credentials
134
129
  credentials = @config.credentials
135
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
130
+ # Use self-signed JWT if the endpoint is unchanged from default,
136
131
  # but only if the default endpoint does not have a region prefix.
137
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
138
- @config.endpoint == Client.configure.endpoint &&
132
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
139
133
  !@config.endpoint.split(".").first.include?("-")
140
134
  credentials ||= Credentials.default scope: @config.scope,
141
135
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -242,7 +236,9 @@ module Google
242
236
  options.apply_defaults timeout: @config.rpcs.create_product.timeout,
243
237
  metadata: metadata,
244
238
  retry_policy: @config.rpcs.create_product.retry_policy
245
- options.apply_defaults metadata: @config.metadata,
239
+
240
+ options.apply_defaults timeout: @config.timeout,
241
+ metadata: @config.metadata,
246
242
  retry_policy: @config.retry_policy
247
243
 
248
244
  @product_service_stub.call_rpc :create_product, request, options: options do |response, operation|
@@ -317,7 +313,9 @@ module Google
317
313
  options.apply_defaults timeout: @config.rpcs.get_product.timeout,
318
314
  metadata: metadata,
319
315
  retry_policy: @config.rpcs.get_product.retry_policy
320
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
321
319
  retry_policy: @config.retry_policy
322
320
 
323
321
  @product_service_stub.call_rpc :get_product, request, options: options do |response, operation|
@@ -454,7 +452,9 @@ module Google
454
452
  options.apply_defaults timeout: @config.rpcs.list_products.timeout,
455
453
  metadata: metadata,
456
454
  retry_policy: @config.rpcs.list_products.retry_policy
457
- options.apply_defaults metadata: @config.metadata,
455
+
456
+ options.apply_defaults timeout: @config.timeout,
457
+ metadata: @config.metadata,
458
458
  retry_policy: @config.retry_policy
459
459
 
460
460
  @product_service_stub.call_rpc :list_products, request, options: options do |response, operation|
@@ -542,7 +542,9 @@ module Google
542
542
  options.apply_defaults timeout: @config.rpcs.update_product.timeout,
543
543
  metadata: metadata,
544
544
  retry_policy: @config.rpcs.update_product.retry_policy
545
- options.apply_defaults metadata: @config.metadata,
545
+
546
+ options.apply_defaults timeout: @config.timeout,
547
+ metadata: @config.metadata,
546
548
  retry_policy: @config.retry_policy
547
549
 
548
550
  @product_service_stub.call_rpc :update_product, request, options: options do |response, operation|
@@ -628,7 +630,9 @@ module Google
628
630
  options.apply_defaults timeout: @config.rpcs.delete_product.timeout,
629
631
  metadata: metadata,
630
632
  retry_policy: @config.rpcs.delete_product.retry_policy
631
- options.apply_defaults metadata: @config.metadata,
633
+
634
+ options.apply_defaults timeout: @config.timeout,
635
+ metadata: @config.metadata,
632
636
  retry_policy: @config.retry_policy
633
637
 
634
638
  @product_service_stub.call_rpc :delete_product, request, options: options do |response, operation|
@@ -735,7 +739,9 @@ module Google
735
739
  options.apply_defaults timeout: @config.rpcs.import_products.timeout,
736
740
  metadata: metadata,
737
741
  retry_policy: @config.rpcs.import_products.retry_policy
738
- options.apply_defaults metadata: @config.metadata,
742
+
743
+ options.apply_defaults timeout: @config.timeout,
744
+ metadata: @config.metadata,
739
745
  retry_policy: @config.retry_policy
740
746
 
741
747
  @product_service_stub.call_rpc :import_products, request, options: options do |response, operation|
@@ -893,7 +899,9 @@ module Google
893
899
  options.apply_defaults timeout: @config.rpcs.set_inventory.timeout,
894
900
  metadata: metadata,
895
901
  retry_policy: @config.rpcs.set_inventory.retry_policy
896
- options.apply_defaults metadata: @config.metadata,
902
+
903
+ options.apply_defaults timeout: @config.timeout,
904
+ metadata: @config.metadata,
897
905
  retry_policy: @config.retry_policy
898
906
 
899
907
  @product_service_stub.call_rpc :set_inventory, request, options: options do |response, operation|
@@ -1027,7 +1035,9 @@ module Google
1027
1035
  options.apply_defaults timeout: @config.rpcs.add_fulfillment_places.timeout,
1028
1036
  metadata: metadata,
1029
1037
  retry_policy: @config.rpcs.add_fulfillment_places.retry_policy
1030
- options.apply_defaults metadata: @config.metadata,
1038
+
1039
+ options.apply_defaults timeout: @config.timeout,
1040
+ metadata: @config.metadata,
1031
1041
  retry_policy: @config.retry_policy
1032
1042
 
1033
1043
  @product_service_stub.call_rpc :add_fulfillment_places, request, options: options do |response, operation|
@@ -1156,7 +1166,9 @@ module Google
1156
1166
  options.apply_defaults timeout: @config.rpcs.remove_fulfillment_places.timeout,
1157
1167
  metadata: metadata,
1158
1168
  retry_policy: @config.rpcs.remove_fulfillment_places.retry_policy
1159
- options.apply_defaults metadata: @config.metadata,
1169
+
1170
+ options.apply_defaults timeout: @config.timeout,
1171
+ metadata: @config.metadata,
1160
1172
  retry_policy: @config.retry_policy
1161
1173
 
1162
1174
  @product_service_stub.call_rpc :remove_fulfillment_places, request, options: options do |response, operation|
@@ -1181,22 +1193,21 @@ module Google
1181
1193
  # Configuration can be applied globally to all clients, or to a single client
1182
1194
  # on construction.
1183
1195
  #
1184
- # # Examples
1185
- #
1186
- # To modify the global config, setting the timeout for create_product
1187
- # to 20 seconds, and all remaining timeouts to 10 seconds:
1188
- #
1189
- # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
1190
- # config.timeout = 10.0
1191
- # config.rpcs.create_product.timeout = 20.0
1192
- # end
1193
- #
1194
- # To apply the above configuration only to a new client:
1195
- #
1196
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
1197
- # config.timeout = 10.0
1198
- # config.rpcs.create_product.timeout = 20.0
1199
- # end
1196
+ # @example
1197
+ #
1198
+ # # Modify the global config, setting the timeout for
1199
+ # # create_product to 20 seconds,
1200
+ # # and all remaining timeouts to 10 seconds.
1201
+ # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
1202
+ # config.timeout = 10.0
1203
+ # config.rpcs.create_product.timeout = 20.0
1204
+ # end
1205
+ #
1206
+ # # Apply the above configuration only to a new client.
1207
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
1208
+ # config.timeout = 10.0
1209
+ # config.rpcs.create_product.timeout = 20.0
1210
+ # end
1200
1211
  #
1201
1212
  # @!attribute [rw] endpoint
1202
1213
  # The hostname or hostname:port of the service endpoint.
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -45,13 +45,12 @@ module Google
45
45
  # See {::Google::Cloud::Retail::V2::SearchService::Client::Configuration}
46
46
  # for a description of the configuration fields.
47
47
  #
48
- # ## Example
48
+ # @example
49
49
  #
50
- # To modify the configuration for all SearchService clients:
51
- #
52
- # ::Google::Cloud::Retail::V2::SearchService::Client.configure do |config|
53
- # config.timeout = 10.0
54
- # end
50
+ # # Modify the configuration for all SearchService clients
51
+ # ::Google::Cloud::Retail::V2::SearchService::Client.configure do |config|
52
+ # config.timeout = 10.0
53
+ # end
55
54
  #
56
55
  # @yield [config] Configure the Client client.
57
56
  # @yieldparam config [Client::Configuration]
@@ -103,19 +102,15 @@ module Google
103
102
  ##
104
103
  # Create a new SearchService client object.
105
104
  #
106
- # ## Examples
107
- #
108
- # To create a new SearchService client with the default
109
- # configuration:
105
+ # @example
110
106
  #
111
- # client = ::Google::Cloud::Retail::V2::SearchService::Client.new
107
+ # # Create a client using the default configuration
108
+ # client = ::Google::Cloud::Retail::V2::SearchService::Client.new
112
109
  #
113
- # To create a new SearchService client with a custom
114
- # configuration:
115
- #
116
- # client = ::Google::Cloud::Retail::V2::SearchService::Client.new do |config|
117
- # config.timeout = 10.0
118
- # end
110
+ # # Create a client using a custom configuration
111
+ # client = ::Google::Cloud::Retail::V2::SearchService::Client.new do |config|
112
+ # config.timeout = 10.0
113
+ # end
119
114
  #
120
115
  # @yield [config] Configure the SearchService client.
121
116
  # @yieldparam config [Client::Configuration]
@@ -135,10 +130,9 @@ module Google
135
130
 
136
131
  # Create credentials
137
132
  credentials = @config.credentials
138
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
133
+ # Use self-signed JWT if the endpoint is unchanged from default,
139
134
  # but only if the default endpoint does not have a region prefix.
140
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
141
- @config.endpoint == Client.configure.endpoint &&
135
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
142
136
  !@config.endpoint.split(".").first.include?("-")
143
137
  credentials ||= Credentials.default scope: @config.scope,
144
138
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -365,7 +359,9 @@ module Google
365
359
  options.apply_defaults timeout: @config.rpcs.search.timeout,
366
360
  metadata: metadata,
367
361
  retry_policy: @config.rpcs.search.retry_policy
368
- options.apply_defaults metadata: @config.metadata,
362
+
363
+ options.apply_defaults timeout: @config.timeout,
364
+ metadata: @config.metadata,
369
365
  retry_policy: @config.retry_policy
370
366
 
371
367
  @search_service_stub.call_rpc :search, request, options: options do |response, operation|
@@ -390,22 +386,21 @@ module Google
390
386
  # Configuration can be applied globally to all clients, or to a single client
391
387
  # on construction.
392
388
  #
393
- # # Examples
394
- #
395
- # To modify the global config, setting the timeout for search
396
- # to 20 seconds, and all remaining timeouts to 10 seconds:
397
- #
398
- # ::Google::Cloud::Retail::V2::SearchService::Client.configure do |config|
399
- # config.timeout = 10.0
400
- # config.rpcs.search.timeout = 20.0
401
- # end
402
- #
403
- # To apply the above configuration only to a new client:
404
- #
405
- # client = ::Google::Cloud::Retail::V2::SearchService::Client.new do |config|
406
- # config.timeout = 10.0
407
- # config.rpcs.search.timeout = 20.0
408
- # end
389
+ # @example
390
+ #
391
+ # # Modify the global config, setting the timeout for
392
+ # # search to 20 seconds,
393
+ # # and all remaining timeouts to 10 seconds.
394
+ # ::Google::Cloud::Retail::V2::SearchService::Client.configure do |config|
395
+ # config.timeout = 10.0
396
+ # config.rpcs.search.timeout = 20.0
397
+ # end
398
+ #
399
+ # # Apply the above configuration only to a new client.
400
+ # client = ::Google::Cloud::Retail::V2::SearchService::Client.new do |config|
401
+ # config.timeout = 10.0
402
+ # config.rpcs.search.timeout = 20.0
403
+ # end
409
404
  #
410
405
  # @!attribute [rw] endpoint
411
406
  # The hostname or hostname:port of the service endpoint.
@@ -41,13 +41,12 @@ module Google
41
41
  # See {::Google::Cloud::Retail::V2::UserEventService::Client::Configuration}
42
42
  # for a description of the configuration fields.
43
43
  #
44
- # ## Example
44
+ # @example
45
45
  #
46
- # To modify the configuration for all UserEventService clients:
47
- #
48
- # ::Google::Cloud::Retail::V2::UserEventService::Client.configure do |config|
49
- # config.timeout = 10.0
50
- # end
46
+ # # Modify the configuration for all UserEventService clients
47
+ # ::Google::Cloud::Retail::V2::UserEventService::Client.configure do |config|
48
+ # config.timeout = 10.0
49
+ # end
51
50
  #
52
51
  # @yield [config] Configure the Client client.
53
52
  # @yieldparam config [Client::Configuration]
@@ -99,19 +98,15 @@ module Google
99
98
  ##
100
99
  # Create a new UserEventService client object.
101
100
  #
102
- # ## Examples
103
- #
104
- # To create a new UserEventService client with the default
105
- # configuration:
106
- #
107
- # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new
101
+ # @example
108
102
  #
109
- # To create a new UserEventService client with a custom
110
- # configuration:
103
+ # # Create a client using the default configuration
104
+ # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new
111
105
  #
112
- # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new do |config|
113
- # config.timeout = 10.0
114
- # end
106
+ # # Create a client using a custom configuration
107
+ # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new do |config|
108
+ # config.timeout = 10.0
109
+ # end
115
110
  #
116
111
  # @yield [config] Configure the UserEventService client.
117
112
  # @yieldparam config [Client::Configuration]
@@ -131,10 +126,9 @@ module Google
131
126
 
132
127
  # Create credentials
133
128
  credentials = @config.credentials
134
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
129
+ # Use self-signed JWT if the endpoint is unchanged from default,
135
130
  # but only if the default endpoint does not have a region prefix.
136
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
137
- @config.endpoint == Client.configure.endpoint &&
131
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
138
132
  !@config.endpoint.split(".").first.include?("-")
139
133
  credentials ||= Credentials.default scope: @config.scope,
140
134
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -225,7 +219,9 @@ module Google
225
219
  options.apply_defaults timeout: @config.rpcs.write_user_event.timeout,
226
220
  metadata: metadata,
227
221
  retry_policy: @config.rpcs.write_user_event.retry_policy
228
- options.apply_defaults metadata: @config.metadata,
222
+
223
+ options.apply_defaults timeout: @config.timeout,
224
+ metadata: @config.metadata,
229
225
  retry_policy: @config.retry_policy
230
226
 
231
227
  @user_event_service_stub.call_rpc :write_user_event, request, options: options do |response, operation|
@@ -308,7 +304,9 @@ module Google
308
304
  options.apply_defaults timeout: @config.rpcs.collect_user_event.timeout,
309
305
  metadata: metadata,
310
306
  retry_policy: @config.rpcs.collect_user_event.retry_policy
311
- options.apply_defaults metadata: @config.metadata,
307
+
308
+ options.apply_defaults timeout: @config.timeout,
309
+ metadata: @config.metadata,
312
310
  retry_policy: @config.retry_policy
313
311
 
314
312
  @user_event_service_stub.call_rpc :collect_user_event, request, options: options do |response, operation|
@@ -407,7 +405,9 @@ module Google
407
405
  options.apply_defaults timeout: @config.rpcs.purge_user_events.timeout,
408
406
  metadata: metadata,
409
407
  retry_policy: @config.rpcs.purge_user_events.retry_policy
410
- options.apply_defaults metadata: @config.metadata,
408
+
409
+ options.apply_defaults timeout: @config.timeout,
410
+ metadata: @config.metadata,
411
411
  retry_policy: @config.retry_policy
412
412
 
413
413
  @user_event_service_stub.call_rpc :purge_user_events, request, options: options do |response, operation|
@@ -485,7 +485,9 @@ module Google
485
485
  options.apply_defaults timeout: @config.rpcs.import_user_events.timeout,
486
486
  metadata: metadata,
487
487
  retry_policy: @config.rpcs.import_user_events.retry_policy
488
- options.apply_defaults metadata: @config.metadata,
488
+
489
+ options.apply_defaults timeout: @config.timeout,
490
+ metadata: @config.metadata,
489
491
  retry_policy: @config.retry_policy
490
492
 
491
493
  @user_event_service_stub.call_rpc :import_user_events, request, options: options do |response, operation|
@@ -564,7 +566,9 @@ module Google
564
566
  options.apply_defaults timeout: @config.rpcs.rejoin_user_events.timeout,
565
567
  metadata: metadata,
566
568
  retry_policy: @config.rpcs.rejoin_user_events.retry_policy
567
- options.apply_defaults metadata: @config.metadata,
569
+
570
+ options.apply_defaults timeout: @config.timeout,
571
+ metadata: @config.metadata,
568
572
  retry_policy: @config.retry_policy
569
573
 
570
574
  @user_event_service_stub.call_rpc :rejoin_user_events, request, options: options do |response, operation|
@@ -589,22 +593,21 @@ module Google
589
593
  # Configuration can be applied globally to all clients, or to a single client
590
594
  # on construction.
591
595
  #
592
- # # Examples
593
- #
594
- # To modify the global config, setting the timeout for write_user_event
595
- # to 20 seconds, and all remaining timeouts to 10 seconds:
596
- #
597
- # ::Google::Cloud::Retail::V2::UserEventService::Client.configure do |config|
598
- # config.timeout = 10.0
599
- # config.rpcs.write_user_event.timeout = 20.0
600
- # end
601
- #
602
- # To apply the above configuration only to a new client:
603
- #
604
- # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new do |config|
605
- # config.timeout = 10.0
606
- # config.rpcs.write_user_event.timeout = 20.0
607
- # end
596
+ # @example
597
+ #
598
+ # # Modify the global config, setting the timeout for
599
+ # # write_user_event to 20 seconds,
600
+ # # and all remaining timeouts to 10 seconds.
601
+ # ::Google::Cloud::Retail::V2::UserEventService::Client.configure do |config|
602
+ # config.timeout = 10.0
603
+ # config.rpcs.write_user_event.timeout = 20.0
604
+ # end
605
+ #
606
+ # # Apply the above configuration only to a new client.
607
+ # client = ::Google::Cloud::Retail::V2::UserEventService::Client.new do |config|
608
+ # config.timeout = 10.0
609
+ # config.rpcs.write_user_event.timeout = 20.0
610
+ # end
608
611
  #
609
612
  # @!attribute [rw] endpoint
610
613
  # The hostname or hostname:port of the service endpoint.
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Retail
23
23
  module V2
24
- VERSION = "0.4.1"
24
+ VERSION = "0.4.2"
25
25
  end
26
26
  end
27
27
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-retail-v2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-08-05 00:00:00.000000000 Z
11
+ date: 2021-08-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common
@@ -16,7 +16,7 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '0.5'
19
+ version: '0.7'
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 2.a
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
- version: '0.5'
29
+ version: '0.7'
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 2.a