google-cloud-talent-v4beta1 0.11.0 → 0.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (24) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +30 -20
  3. data/lib/google/cloud/talent/v4beta1/company_service/client.rb +41 -11
  4. data/lib/google/cloud/talent/v4beta1/company_service/rest/client.rb +41 -11
  5. data/lib/google/cloud/talent/v4beta1/company_service/rest/service_stub.rb +54 -32
  6. data/lib/google/cloud/talent/v4beta1/completion/client.rb +32 -3
  7. data/lib/google/cloud/talent/v4beta1/completion/rest/client.rb +32 -3
  8. data/lib/google/cloud/talent/v4beta1/completion/rest/service_stub.rb +22 -8
  9. data/lib/google/cloud/talent/v4beta1/event_service/client.rb +32 -3
  10. data/lib/google/cloud/talent/v4beta1/event_service/rest/client.rb +32 -3
  11. data/lib/google/cloud/talent/v4beta1/event_service/rest/service_stub.rb +22 -8
  12. data/lib/google/cloud/talent/v4beta1/job_service/client.rb +53 -21
  13. data/lib/google/cloud/talent/v4beta1/job_service/operations.rb +25 -20
  14. data/lib/google/cloud/talent/v4beta1/job_service/rest/client.rb +53 -21
  15. data/lib/google/cloud/talent/v4beta1/job_service/rest/operations.rb +54 -42
  16. data/lib/google/cloud/talent/v4beta1/job_service/rest/service_stub.rb +94 -62
  17. data/lib/google/cloud/talent/v4beta1/tenant_service/client.rb +41 -11
  18. data/lib/google/cloud/talent/v4beta1/tenant_service/rest/client.rb +41 -11
  19. data/lib/google/cloud/talent/v4beta1/tenant_service/rest/service_stub.rb +54 -32
  20. data/lib/google/cloud/talent/v4beta1/version.rb +1 -1
  21. data/proto_docs/google/api/client.rb +74 -10
  22. data/proto_docs/google/api/resource.rb +7 -2
  23. data/proto_docs/google/longrunning/operations.rb +19 -14
  24. metadata +5 -5
@@ -26,6 +26,9 @@ module Google
26
26
  module JobService
27
27
  # Service that implements Longrunning Operations API.
28
28
  class Operations
29
+ # @private
30
+ API_VERSION = ""
31
+
29
32
  # @private
30
33
  DEFAULT_ENDPOINT_TEMPLATE = "jobs.$UNIVERSE_DOMAIN$"
31
34
 
@@ -121,14 +124,6 @@ module Google
121
124
  # Lists operations that match the specified filter in the request. If the
122
125
  # server doesn't support this method, it returns `UNIMPLEMENTED`.
123
126
  #
124
- # NOTE: the `name` binding allows API services to override the binding
125
- # to use different resource name schemes, such as `users/*/operations`. To
126
- # override the binding, API services can add a binding such as
127
- # `"/v1/{name=users/*}/operations"` to their service configuration.
128
- # For backwards compatibility, the default name includes the operations
129
- # collection id, however overriding users must ensure the name binding
130
- # is the parent resource, without the operations collection id.
131
- #
132
127
  # @overload list_operations(request, options = nil)
133
128
  # Pass arguments to `list_operations` via a request object, either of type
134
129
  # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash.
@@ -191,10 +186,11 @@ module Google
191
186
  # Customize the options with defaults
192
187
  metadata = @config.rpcs.list_operations.metadata.to_h
193
188
 
194
- # Set x-goog-api-client and x-goog-user-project headers
189
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
195
190
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
196
191
  lib_name: @config.lib_name, lib_version: @config.lib_version,
197
192
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
193
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
198
194
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
199
195
 
200
196
  header_params = {}
@@ -217,7 +213,7 @@ module Google
217
213
  wrap_lro_operation = ->(op_response) { ::Gapic::Operation.new op_response, @operations_client }
218
214
  response = ::Gapic::PagedEnumerable.new @operations_stub, :list_operations, request, response, operation, options, format_resource: wrap_lro_operation
219
215
  yield response, operation if block_given?
220
- return response
216
+ throw :response, response
221
217
  end
222
218
  rescue ::GRPC::BadStatus => e
223
219
  raise ::Google::Cloud::Error.from_error(e)
@@ -287,10 +283,11 @@ module Google
287
283
  # Customize the options with defaults
288
284
  metadata = @config.rpcs.get_operation.metadata.to_h
289
285
 
290
- # Set x-goog-api-client and x-goog-user-project headers
286
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
291
287
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
292
288
  lib_name: @config.lib_name, lib_version: @config.lib_version,
293
289
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
290
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
294
291
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
295
292
 
296
293
  header_params = {}
@@ -312,7 +309,7 @@ module Google
312
309
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
313
310
  response = ::Gapic::Operation.new response, @operations_client, options: options
314
311
  yield response, operation if block_given?
315
- return response
312
+ throw :response, response
316
313
  end
317
314
  rescue ::GRPC::BadStatus => e
318
315
  raise ::Google::Cloud::Error.from_error(e)
@@ -376,10 +373,11 @@ module Google
376
373
  # Customize the options with defaults
377
374
  metadata = @config.rpcs.delete_operation.metadata.to_h
378
375
 
379
- # Set x-goog-api-client and x-goog-user-project headers
376
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
380
377
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
381
378
  lib_name: @config.lib_name, lib_version: @config.lib_version,
382
379
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
380
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
383
381
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
384
382
 
385
383
  header_params = {}
@@ -400,7 +398,6 @@ module Google
400
398
 
401
399
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
402
400
  yield response, operation if block_given?
403
- return response
404
401
  end
405
402
  rescue ::GRPC::BadStatus => e
406
403
  raise ::Google::Cloud::Error.from_error(e)
@@ -415,8 +412,9 @@ module Google
415
412
  # other methods to check whether the cancellation succeeded or whether the
416
413
  # operation completed despite cancellation. On successful cancellation,
417
414
  # the operation is not deleted; instead, it becomes an operation with
418
- # an {::Google::Longrunning::Operation#error Operation.error} value with a {::Google::Rpc::Status#code google.rpc.Status.code} of 1,
419
- # corresponding to `Code.CANCELLED`.
415
+ # an {::Google::Longrunning::Operation#error Operation.error} value with a
416
+ # {::Google::Rpc::Status#code google.rpc.Status.code} of `1`, corresponding to
417
+ # `Code.CANCELLED`.
420
418
  #
421
419
  # @overload cancel_operation(request, options = nil)
422
420
  # Pass arguments to `cancel_operation` via a request object, either of type
@@ -470,10 +468,11 @@ module Google
470
468
  # Customize the options with defaults
471
469
  metadata = @config.rpcs.cancel_operation.metadata.to_h
472
470
 
473
- # Set x-goog-api-client and x-goog-user-project headers
471
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
474
472
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
475
473
  lib_name: @config.lib_name, lib_version: @config.lib_version,
476
474
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
475
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
477
476
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
478
477
 
479
478
  header_params = {}
@@ -494,7 +493,6 @@ module Google
494
493
 
495
494
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
496
495
  yield response, operation if block_given?
497
- return response
498
496
  end
499
497
  rescue ::GRPC::BadStatus => e
500
498
  raise ::Google::Cloud::Error.from_error(e)
@@ -574,10 +572,11 @@ module Google
574
572
  # Customize the options with defaults
575
573
  metadata = @config.rpcs.wait_operation.metadata.to_h
576
574
 
577
- # Set x-goog-api-client and x-goog-user-project headers
575
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
578
576
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
579
577
  lib_name: @config.lib_name, lib_version: @config.lib_version,
580
578
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION
579
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
581
580
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
582
581
 
583
582
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
@@ -591,7 +590,7 @@ module Google
591
590
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
592
591
  response = ::Gapic::Operation.new response, @operations_client, options: options
593
592
  yield response, operation if block_given?
594
- return response
593
+ throw :response, response
595
594
  end
596
595
  rescue ::GRPC::BadStatus => e
597
596
  raise ::Google::Cloud::Error.from_error(e)
@@ -680,6 +679,11 @@ module Google
680
679
  # default endpoint URL. The default value of nil uses the environment
681
680
  # universe (usually the default "googleapis.com" universe).
682
681
  # @return [::String,nil]
682
+ # @!attribute [rw] logger
683
+ # A custom logger to use for request/response debug logging, or the value
684
+ # `:default` (the default) to construct a default logger, or `nil` to
685
+ # explicitly disable logging.
686
+ # @return [::Logger,:default,nil]
683
687
  #
684
688
  class Configuration
685
689
  extend ::Gapic::Config
@@ -704,6 +708,7 @@ module Google
704
708
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
705
709
  config_attr :quota_project, nil, ::String, nil
706
710
  config_attr :universe_domain, nil, ::String, nil
711
+ config_attr :logger, :default, ::Logger, nil, :default
707
712
 
708
713
  # @private
709
714
  def initialize parent_config = nil
@@ -32,6 +32,9 @@ module Google
32
32
  # A service handles job management, including job CRUD, enumeration and search.
33
33
  #
34
34
  class Client
35
+ # @private
36
+ API_VERSION = ""
37
+
35
38
  # @private
36
39
  DEFAULT_ENDPOINT_TEMPLATE = "jobs.$UNIVERSE_DOMAIN$"
37
40
 
@@ -183,8 +186,19 @@ module Google
183
186
  endpoint: @config.endpoint,
184
187
  endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
185
188
  universe_domain: @config.universe_domain,
186
- credentials: credentials
189
+ credentials: credentials,
190
+ logger: @config.logger
187
191
  )
192
+
193
+ @job_service_stub.logger(stub: true)&.info do |entry|
194
+ entry.set_system_name
195
+ entry.set_service
196
+ entry.message = "Created client for #{entry.service}"
197
+ entry.set_credentials_fields credentials
198
+ entry.set "customEndpoint", @config.endpoint if @config.endpoint
199
+ entry.set "defaultTimeout", @config.timeout if @config.timeout
200
+ entry.set "quotaProject", @quota_project_id if @quota_project_id
201
+ end
188
202
  end
189
203
 
190
204
  ##
@@ -194,6 +208,15 @@ module Google
194
208
  #
195
209
  attr_reader :operations_client
196
210
 
211
+ ##
212
+ # The logger used for request/response debug logging.
213
+ #
214
+ # @return [Logger]
215
+ #
216
+ def logger
217
+ @job_service_stub.logger
218
+ end
219
+
197
220
  # Service calls
198
221
 
199
222
  ##
@@ -259,12 +282,13 @@ module Google
259
282
  # Customize the options with defaults
260
283
  call_metadata = @config.rpcs.create_job.metadata.to_h
261
284
 
262
- # Set x-goog-api-client and x-goog-user-project headers
285
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
263
286
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
264
287
  lib_name: @config.lib_name, lib_version: @config.lib_version,
265
288
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
266
289
  transports_version_send: [:rest]
267
290
 
291
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
268
292
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
269
293
 
270
294
  options.apply_defaults timeout: @config.rpcs.create_job.timeout,
@@ -277,7 +301,6 @@ module Google
277
301
 
278
302
  @job_service_stub.create_job request, options do |result, operation|
279
303
  yield result, operation if block_given?
280
- return result
281
304
  end
282
305
  rescue ::Gapic::Rest::Error => e
283
306
  raise ::Google::Cloud::Error.from_error(e)
@@ -350,12 +373,13 @@ module Google
350
373
  # Customize the options with defaults
351
374
  call_metadata = @config.rpcs.batch_create_jobs.metadata.to_h
352
375
 
353
- # Set x-goog-api-client and x-goog-user-project headers
376
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
354
377
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
355
378
  lib_name: @config.lib_name, lib_version: @config.lib_version,
356
379
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
357
380
  transports_version_send: [:rest]
358
381
 
382
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
359
383
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
360
384
 
361
385
  options.apply_defaults timeout: @config.rpcs.batch_create_jobs.timeout,
@@ -369,7 +393,7 @@ module Google
369
393
  @job_service_stub.batch_create_jobs request, options do |result, operation|
370
394
  result = ::Gapic::Operation.new result, @operations_client, options: options
371
395
  yield result, operation if block_given?
372
- return result
396
+ throw :response, result
373
397
  end
374
398
  rescue ::Gapic::Rest::Error => e
375
399
  raise ::Google::Cloud::Error.from_error(e)
@@ -437,12 +461,13 @@ module Google
437
461
  # Customize the options with defaults
438
462
  call_metadata = @config.rpcs.get_job.metadata.to_h
439
463
 
440
- # Set x-goog-api-client and x-goog-user-project headers
464
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
441
465
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
442
466
  lib_name: @config.lib_name, lib_version: @config.lib_version,
443
467
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
444
468
  transports_version_send: [:rest]
445
469
 
470
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
446
471
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
447
472
 
448
473
  options.apply_defaults timeout: @config.rpcs.get_job.timeout,
@@ -455,7 +480,6 @@ module Google
455
480
 
456
481
  @job_service_stub.get_job request, options do |result, operation|
457
482
  yield result, operation if block_given?
458
- return result
459
483
  end
460
484
  rescue ::Gapic::Rest::Error => e
461
485
  raise ::Google::Cloud::Error.from_error(e)
@@ -528,12 +552,13 @@ module Google
528
552
  # Customize the options with defaults
529
553
  call_metadata = @config.rpcs.update_job.metadata.to_h
530
554
 
531
- # Set x-goog-api-client and x-goog-user-project headers
555
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
532
556
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
533
557
  lib_name: @config.lib_name, lib_version: @config.lib_version,
534
558
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
535
559
  transports_version_send: [:rest]
536
560
 
561
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
537
562
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
538
563
 
539
564
  options.apply_defaults timeout: @config.rpcs.update_job.timeout,
@@ -546,7 +571,6 @@ module Google
546
571
 
547
572
  @job_service_stub.update_job request, options do |result, operation|
548
573
  yield result, operation if block_given?
549
- return result
550
574
  end
551
575
  rescue ::Gapic::Rest::Error => e
552
576
  raise ::Google::Cloud::Error.from_error(e)
@@ -639,12 +663,13 @@ module Google
639
663
  # Customize the options with defaults
640
664
  call_metadata = @config.rpcs.batch_update_jobs.metadata.to_h
641
665
 
642
- # Set x-goog-api-client and x-goog-user-project headers
666
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
643
667
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
644
668
  lib_name: @config.lib_name, lib_version: @config.lib_version,
645
669
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
646
670
  transports_version_send: [:rest]
647
671
 
672
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
648
673
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
649
674
 
650
675
  options.apply_defaults timeout: @config.rpcs.batch_update_jobs.timeout,
@@ -658,7 +683,7 @@ module Google
658
683
  @job_service_stub.batch_update_jobs request, options do |result, operation|
659
684
  result = ::Gapic::Operation.new result, @operations_client, options: options
660
685
  yield result, operation if block_given?
661
- return result
686
+ throw :response, result
662
687
  end
663
688
  rescue ::Gapic::Rest::Error => e
664
689
  raise ::Google::Cloud::Error.from_error(e)
@@ -728,12 +753,13 @@ module Google
728
753
  # Customize the options with defaults
729
754
  call_metadata = @config.rpcs.delete_job.metadata.to_h
730
755
 
731
- # Set x-goog-api-client and x-goog-user-project headers
756
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
732
757
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
733
758
  lib_name: @config.lib_name, lib_version: @config.lib_version,
734
759
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
735
760
  transports_version_send: [:rest]
736
761
 
762
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
737
763
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
738
764
 
739
765
  options.apply_defaults timeout: @config.rpcs.delete_job.timeout,
@@ -746,7 +772,6 @@ module Google
746
772
 
747
773
  @job_service_stub.delete_job request, options do |result, operation|
748
774
  yield result, operation if block_given?
749
- return result
750
775
  end
751
776
  rescue ::Gapic::Rest::Error => e
752
777
  raise ::Google::Cloud::Error.from_error(e)
@@ -822,12 +847,13 @@ module Google
822
847
  # Customize the options with defaults
823
848
  call_metadata = @config.rpcs.batch_delete_jobs.metadata.to_h
824
849
 
825
- # Set x-goog-api-client and x-goog-user-project headers
850
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
826
851
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
827
852
  lib_name: @config.lib_name, lib_version: @config.lib_version,
828
853
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
829
854
  transports_version_send: [:rest]
830
855
 
856
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
831
857
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
832
858
 
833
859
  options.apply_defaults timeout: @config.rpcs.batch_delete_jobs.timeout,
@@ -840,7 +866,6 @@ module Google
840
866
 
841
867
  @job_service_stub.batch_delete_jobs request, options do |result, operation|
842
868
  yield result, operation if block_given?
843
- return result
844
869
  end
845
870
  rescue ::Gapic::Rest::Error => e
846
871
  raise ::Google::Cloud::Error.from_error(e)
@@ -949,12 +974,13 @@ module Google
949
974
  # Customize the options with defaults
950
975
  call_metadata = @config.rpcs.list_jobs.metadata.to_h
951
976
 
952
- # Set x-goog-api-client and x-goog-user-project headers
977
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
953
978
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
954
979
  lib_name: @config.lib_name, lib_version: @config.lib_version,
955
980
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
956
981
  transports_version_send: [:rest]
957
982
 
983
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
958
984
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
959
985
 
960
986
  options.apply_defaults timeout: @config.rpcs.list_jobs.timeout,
@@ -968,7 +994,7 @@ module Google
968
994
  @job_service_stub.list_jobs request, options do |result, operation|
969
995
  result = ::Gapic::Rest::PagedEnumerable.new @job_service_stub, :list_jobs, "jobs", request, result, options
970
996
  yield result, operation if block_given?
971
- return result
997
+ throw :response, result
972
998
  end
973
999
  rescue ::Gapic::Rest::Error => e
974
1000
  raise ::Google::Cloud::Error.from_error(e)
@@ -1310,12 +1336,13 @@ module Google
1310
1336
  # Customize the options with defaults
1311
1337
  call_metadata = @config.rpcs.search_jobs.metadata.to_h
1312
1338
 
1313
- # Set x-goog-api-client and x-goog-user-project headers
1339
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1314
1340
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1315
1341
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1316
1342
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
1317
1343
  transports_version_send: [:rest]
1318
1344
 
1345
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1319
1346
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1320
1347
 
1321
1348
  options.apply_defaults timeout: @config.rpcs.search_jobs.timeout,
@@ -1328,7 +1355,6 @@ module Google
1328
1355
 
1329
1356
  @job_service_stub.search_jobs request, options do |result, operation|
1330
1357
  yield result, operation if block_given?
1331
- return result
1332
1358
  end
1333
1359
  rescue ::Gapic::Rest::Error => e
1334
1360
  raise ::Google::Cloud::Error.from_error(e)
@@ -1675,12 +1701,13 @@ module Google
1675
1701
  # Customize the options with defaults
1676
1702
  call_metadata = @config.rpcs.search_jobs_for_alert.metadata.to_h
1677
1703
 
1678
- # Set x-goog-api-client and x-goog-user-project headers
1704
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1679
1705
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1680
1706
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1681
1707
  gapic_version: ::Google::Cloud::Talent::V4beta1::VERSION,
1682
1708
  transports_version_send: [:rest]
1683
1709
 
1710
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1684
1711
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1685
1712
 
1686
1713
  options.apply_defaults timeout: @config.rpcs.search_jobs_for_alert.timeout,
@@ -1693,7 +1720,6 @@ module Google
1693
1720
 
1694
1721
  @job_service_stub.search_jobs_for_alert request, options do |result, operation|
1695
1722
  yield result, operation if block_given?
1696
- return result
1697
1723
  end
1698
1724
  rescue ::Gapic::Rest::Error => e
1699
1725
  raise ::Google::Cloud::Error.from_error(e)
@@ -1773,6 +1799,11 @@ module Google
1773
1799
  # default endpoint URL. The default value of nil uses the environment
1774
1800
  # universe (usually the default "googleapis.com" universe).
1775
1801
  # @return [::String,nil]
1802
+ # @!attribute [rw] logger
1803
+ # A custom logger to use for request/response debug logging, or the value
1804
+ # `:default` (the default) to construct a default logger, or `nil` to
1805
+ # explicitly disable logging.
1806
+ # @return [::Logger,:default,nil]
1776
1807
  #
1777
1808
  class Configuration
1778
1809
  extend ::Gapic::Config
@@ -1794,6 +1825,7 @@ module Google
1794
1825
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
1795
1826
  config_attr :quota_project, nil, ::String, nil
1796
1827
  config_attr :universe_domain, nil, ::String, nil
1828
+ config_attr :logger, :default, ::Logger, nil, :default
1797
1829
 
1798
1830
  # @private
1799
1831
  def initialize parent_config = nil