google-cloud-apigee_registry-v1 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +30 -20
- data/lib/google/cloud/apigee_registry/v1/provisioning/client.rb +40 -7
- data/lib/google/cloud/apigee_registry/v1/provisioning/operations.rb +25 -20
- data/lib/google/cloud/apigee_registry/v1/provisioning/rest/client.rb +40 -7
- data/lib/google/cloud/apigee_registry/v1/provisioning/rest/operations.rb +54 -42
- data/lib/google/cloud/apigee_registry/v1/provisioning/rest/service_stub.rb +38 -20
- data/lib/google/cloud/apigee_registry/v1/registry/client.rb +109 -71
- data/lib/google/cloud/apigee_registry/v1/registry/rest/client.rb +109 -71
- data/lib/google/cloud/apigee_registry/v1/registry/rest/service_stub.rb +294 -212
- data/lib/google/cloud/apigee_registry/v1/version.rb +1 -1
- data/proto_docs/google/api/client.rb +74 -10
- data/proto_docs/google/api/resource.rb +7 -2
- data/proto_docs/google/longrunning/operations.rb +19 -14
- metadata +5 -5
@@ -34,6 +34,9 @@ module Google
|
|
34
34
|
# The Registry service allows teams to manage descriptions of APIs.
|
35
35
|
#
|
36
36
|
class Client
|
37
|
+
# @private
|
38
|
+
API_VERSION = ""
|
39
|
+
|
37
40
|
# @private
|
38
41
|
DEFAULT_ENDPOINT_TEMPLATE = "apigeeregistry.$UNIVERSE_DOMAIN$"
|
39
42
|
|
@@ -318,15 +321,27 @@ module Google
|
|
318
321
|
endpoint: @config.endpoint,
|
319
322
|
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
320
323
|
universe_domain: @config.universe_domain,
|
321
|
-
credentials: credentials
|
324
|
+
credentials: credentials,
|
325
|
+
logger: @config.logger
|
322
326
|
)
|
323
327
|
|
328
|
+
@registry_stub.logger(stub: true)&.info do |entry|
|
329
|
+
entry.set_system_name
|
330
|
+
entry.set_service
|
331
|
+
entry.message = "Created client for #{entry.service}"
|
332
|
+
entry.set_credentials_fields credentials
|
333
|
+
entry.set "customEndpoint", @config.endpoint if @config.endpoint
|
334
|
+
entry.set "defaultTimeout", @config.timeout if @config.timeout
|
335
|
+
entry.set "quotaProject", @quota_project_id if @quota_project_id
|
336
|
+
end
|
337
|
+
|
324
338
|
@location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
|
325
339
|
config.credentials = credentials
|
326
340
|
config.quota_project = @quota_project_id
|
327
341
|
config.endpoint = @registry_stub.endpoint
|
328
342
|
config.universe_domain = @registry_stub.universe_domain
|
329
343
|
config.bindings_override = @config.bindings_override
|
344
|
+
config.logger = @registry_stub.logger if config.respond_to? :logger=
|
330
345
|
end
|
331
346
|
|
332
347
|
@iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
|
@@ -335,6 +350,7 @@ module Google
|
|
335
350
|
config.endpoint = @registry_stub.endpoint
|
336
351
|
config.universe_domain = @registry_stub.universe_domain
|
337
352
|
config.bindings_override = @config.bindings_override
|
353
|
+
config.logger = @registry_stub.logger if config.respond_to? :logger=
|
338
354
|
end
|
339
355
|
end
|
340
356
|
|
@@ -352,6 +368,15 @@ module Google
|
|
352
368
|
#
|
353
369
|
attr_reader :iam_policy_client
|
354
370
|
|
371
|
+
##
|
372
|
+
# The logger used for request/response debug logging.
|
373
|
+
#
|
374
|
+
# @return [Logger]
|
375
|
+
#
|
376
|
+
def logger
|
377
|
+
@registry_stub.logger
|
378
|
+
end
|
379
|
+
|
355
380
|
# Service calls
|
356
381
|
|
357
382
|
##
|
@@ -427,12 +452,13 @@ module Google
|
|
427
452
|
# Customize the options with defaults
|
428
453
|
call_metadata = @config.rpcs.list_apis.metadata.to_h
|
429
454
|
|
430
|
-
# Set x-goog-api-client
|
455
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
431
456
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
432
457
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
433
458
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
434
459
|
transports_version_send: [:rest]
|
435
460
|
|
461
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
436
462
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
437
463
|
|
438
464
|
options.apply_defaults timeout: @config.rpcs.list_apis.timeout,
|
@@ -446,7 +472,7 @@ module Google
|
|
446
472
|
@registry_stub.list_apis request, options do |result, operation|
|
447
473
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_apis, "apis", request, result, options
|
448
474
|
yield result, operation if block_given?
|
449
|
-
|
475
|
+
throw :response, result
|
450
476
|
end
|
451
477
|
rescue ::Gapic::Rest::Error => e
|
452
478
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -507,12 +533,13 @@ module Google
|
|
507
533
|
# Customize the options with defaults
|
508
534
|
call_metadata = @config.rpcs.get_api.metadata.to_h
|
509
535
|
|
510
|
-
# Set x-goog-api-client
|
536
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
511
537
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
512
538
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
513
539
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
514
540
|
transports_version_send: [:rest]
|
515
541
|
|
542
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
516
543
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
517
544
|
|
518
545
|
options.apply_defaults timeout: @config.rpcs.get_api.timeout,
|
@@ -525,7 +552,6 @@ module Google
|
|
525
552
|
|
526
553
|
@registry_stub.get_api request, options do |result, operation|
|
527
554
|
yield result, operation if block_given?
|
528
|
-
return result
|
529
555
|
end
|
530
556
|
rescue ::Gapic::Rest::Error => e
|
531
557
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -596,12 +622,13 @@ module Google
|
|
596
622
|
# Customize the options with defaults
|
597
623
|
call_metadata = @config.rpcs.create_api.metadata.to_h
|
598
624
|
|
599
|
-
# Set x-goog-api-client
|
625
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
600
626
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
601
627
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
602
628
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
603
629
|
transports_version_send: [:rest]
|
604
630
|
|
631
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
605
632
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
606
633
|
|
607
634
|
options.apply_defaults timeout: @config.rpcs.create_api.timeout,
|
@@ -614,7 +641,6 @@ module Google
|
|
614
641
|
|
615
642
|
@registry_stub.create_api request, options do |result, operation|
|
616
643
|
yield result, operation if block_given?
|
617
|
-
return result
|
618
644
|
end
|
619
645
|
rescue ::Gapic::Rest::Error => e
|
620
646
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -685,12 +711,13 @@ module Google
|
|
685
711
|
# Customize the options with defaults
|
686
712
|
call_metadata = @config.rpcs.update_api.metadata.to_h
|
687
713
|
|
688
|
-
# Set x-goog-api-client
|
714
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
689
715
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
690
716
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
691
717
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
692
718
|
transports_version_send: [:rest]
|
693
719
|
|
720
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
694
721
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
695
722
|
|
696
723
|
options.apply_defaults timeout: @config.rpcs.update_api.timeout,
|
@@ -703,7 +730,6 @@ module Google
|
|
703
730
|
|
704
731
|
@registry_stub.update_api request, options do |result, operation|
|
705
732
|
yield result, operation if block_given?
|
706
|
-
return result
|
707
733
|
end
|
708
734
|
rescue ::Gapic::Rest::Error => e
|
709
735
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -768,12 +794,13 @@ module Google
|
|
768
794
|
# Customize the options with defaults
|
769
795
|
call_metadata = @config.rpcs.delete_api.metadata.to_h
|
770
796
|
|
771
|
-
# Set x-goog-api-client
|
797
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
772
798
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
773
799
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
774
800
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
775
801
|
transports_version_send: [:rest]
|
776
802
|
|
803
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
777
804
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
778
805
|
|
779
806
|
options.apply_defaults timeout: @config.rpcs.delete_api.timeout,
|
@@ -786,7 +813,6 @@ module Google
|
|
786
813
|
|
787
814
|
@registry_stub.delete_api request, options do |result, operation|
|
788
815
|
yield result, operation if block_given?
|
789
|
-
return result
|
790
816
|
end
|
791
817
|
rescue ::Gapic::Rest::Error => e
|
792
818
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -865,12 +891,13 @@ module Google
|
|
865
891
|
# Customize the options with defaults
|
866
892
|
call_metadata = @config.rpcs.list_api_versions.metadata.to_h
|
867
893
|
|
868
|
-
# Set x-goog-api-client
|
894
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
869
895
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
870
896
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
871
897
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
872
898
|
transports_version_send: [:rest]
|
873
899
|
|
900
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
874
901
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
875
902
|
|
876
903
|
options.apply_defaults timeout: @config.rpcs.list_api_versions.timeout,
|
@@ -884,7 +911,7 @@ module Google
|
|
884
911
|
@registry_stub.list_api_versions request, options do |result, operation|
|
885
912
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_versions, "api_versions", request, result, options
|
886
913
|
yield result, operation if block_given?
|
887
|
-
|
914
|
+
throw :response, result
|
888
915
|
end
|
889
916
|
rescue ::Gapic::Rest::Error => e
|
890
917
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -945,12 +972,13 @@ module Google
|
|
945
972
|
# Customize the options with defaults
|
946
973
|
call_metadata = @config.rpcs.get_api_version.metadata.to_h
|
947
974
|
|
948
|
-
# Set x-goog-api-client
|
975
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
949
976
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
950
977
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
951
978
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
952
979
|
transports_version_send: [:rest]
|
953
980
|
|
981
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
954
982
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
955
983
|
|
956
984
|
options.apply_defaults timeout: @config.rpcs.get_api_version.timeout,
|
@@ -963,7 +991,6 @@ module Google
|
|
963
991
|
|
964
992
|
@registry_stub.get_api_version request, options do |result, operation|
|
965
993
|
yield result, operation if block_given?
|
966
|
-
return result
|
967
994
|
end
|
968
995
|
rescue ::Gapic::Rest::Error => e
|
969
996
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1034,12 +1061,13 @@ module Google
|
|
1034
1061
|
# Customize the options with defaults
|
1035
1062
|
call_metadata = @config.rpcs.create_api_version.metadata.to_h
|
1036
1063
|
|
1037
|
-
# Set x-goog-api-client
|
1064
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1038
1065
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1039
1066
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1040
1067
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1041
1068
|
transports_version_send: [:rest]
|
1042
1069
|
|
1070
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1043
1071
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1044
1072
|
|
1045
1073
|
options.apply_defaults timeout: @config.rpcs.create_api_version.timeout,
|
@@ -1052,7 +1080,6 @@ module Google
|
|
1052
1080
|
|
1053
1081
|
@registry_stub.create_api_version request, options do |result, operation|
|
1054
1082
|
yield result, operation if block_given?
|
1055
|
-
return result
|
1056
1083
|
end
|
1057
1084
|
rescue ::Gapic::Rest::Error => e
|
1058
1085
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1123,12 +1150,13 @@ module Google
|
|
1123
1150
|
# Customize the options with defaults
|
1124
1151
|
call_metadata = @config.rpcs.update_api_version.metadata.to_h
|
1125
1152
|
|
1126
|
-
# Set x-goog-api-client
|
1153
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1127
1154
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1128
1155
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1129
1156
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1130
1157
|
transports_version_send: [:rest]
|
1131
1158
|
|
1159
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1132
1160
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1133
1161
|
|
1134
1162
|
options.apply_defaults timeout: @config.rpcs.update_api_version.timeout,
|
@@ -1141,7 +1169,6 @@ module Google
|
|
1141
1169
|
|
1142
1170
|
@registry_stub.update_api_version request, options do |result, operation|
|
1143
1171
|
yield result, operation if block_given?
|
1144
|
-
return result
|
1145
1172
|
end
|
1146
1173
|
rescue ::Gapic::Rest::Error => e
|
1147
1174
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1206,12 +1233,13 @@ module Google
|
|
1206
1233
|
# Customize the options with defaults
|
1207
1234
|
call_metadata = @config.rpcs.delete_api_version.metadata.to_h
|
1208
1235
|
|
1209
|
-
# Set x-goog-api-client
|
1236
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1210
1237
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1211
1238
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1212
1239
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1213
1240
|
transports_version_send: [:rest]
|
1214
1241
|
|
1242
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1215
1243
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1216
1244
|
|
1217
1245
|
options.apply_defaults timeout: @config.rpcs.delete_api_version.timeout,
|
@@ -1224,7 +1252,6 @@ module Google
|
|
1224
1252
|
|
1225
1253
|
@registry_stub.delete_api_version request, options do |result, operation|
|
1226
1254
|
yield result, operation if block_given?
|
1227
|
-
return result
|
1228
1255
|
end
|
1229
1256
|
rescue ::Gapic::Rest::Error => e
|
1230
1257
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1303,12 +1330,13 @@ module Google
|
|
1303
1330
|
# Customize the options with defaults
|
1304
1331
|
call_metadata = @config.rpcs.list_api_specs.metadata.to_h
|
1305
1332
|
|
1306
|
-
# Set x-goog-api-client
|
1333
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1307
1334
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1308
1335
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1309
1336
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1310
1337
|
transports_version_send: [:rest]
|
1311
1338
|
|
1339
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1312
1340
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1313
1341
|
|
1314
1342
|
options.apply_defaults timeout: @config.rpcs.list_api_specs.timeout,
|
@@ -1322,7 +1350,7 @@ module Google
|
|
1322
1350
|
@registry_stub.list_api_specs request, options do |result, operation|
|
1323
1351
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_specs, "api_specs", request, result, options
|
1324
1352
|
yield result, operation if block_given?
|
1325
|
-
|
1353
|
+
throw :response, result
|
1326
1354
|
end
|
1327
1355
|
rescue ::Gapic::Rest::Error => e
|
1328
1356
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1383,12 +1411,13 @@ module Google
|
|
1383
1411
|
# Customize the options with defaults
|
1384
1412
|
call_metadata = @config.rpcs.get_api_spec.metadata.to_h
|
1385
1413
|
|
1386
|
-
# Set x-goog-api-client
|
1414
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1387
1415
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1388
1416
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1389
1417
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1390
1418
|
transports_version_send: [:rest]
|
1391
1419
|
|
1420
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1392
1421
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1393
1422
|
|
1394
1423
|
options.apply_defaults timeout: @config.rpcs.get_api_spec.timeout,
|
@@ -1401,7 +1430,6 @@ module Google
|
|
1401
1430
|
|
1402
1431
|
@registry_stub.get_api_spec request, options do |result, operation|
|
1403
1432
|
yield result, operation if block_given?
|
1404
|
-
return result
|
1405
1433
|
end
|
1406
1434
|
rescue ::Gapic::Rest::Error => e
|
1407
1435
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1465,12 +1493,13 @@ module Google
|
|
1465
1493
|
# Customize the options with defaults
|
1466
1494
|
call_metadata = @config.rpcs.get_api_spec_contents.metadata.to_h
|
1467
1495
|
|
1468
|
-
# Set x-goog-api-client
|
1496
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1469
1497
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1470
1498
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1471
1499
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1472
1500
|
transports_version_send: [:rest]
|
1473
1501
|
|
1502
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1474
1503
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1475
1504
|
|
1476
1505
|
options.apply_defaults timeout: @config.rpcs.get_api_spec_contents.timeout,
|
@@ -1483,7 +1512,6 @@ module Google
|
|
1483
1512
|
|
1484
1513
|
@registry_stub.get_api_spec_contents request, options do |result, operation|
|
1485
1514
|
yield result, operation if block_given?
|
1486
|
-
return result
|
1487
1515
|
end
|
1488
1516
|
rescue ::Gapic::Rest::Error => e
|
1489
1517
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1554,12 +1582,13 @@ module Google
|
|
1554
1582
|
# Customize the options with defaults
|
1555
1583
|
call_metadata = @config.rpcs.create_api_spec.metadata.to_h
|
1556
1584
|
|
1557
|
-
# Set x-goog-api-client
|
1585
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1558
1586
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1559
1587
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1560
1588
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1561
1589
|
transports_version_send: [:rest]
|
1562
1590
|
|
1591
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1563
1592
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1564
1593
|
|
1565
1594
|
options.apply_defaults timeout: @config.rpcs.create_api_spec.timeout,
|
@@ -1572,7 +1601,6 @@ module Google
|
|
1572
1601
|
|
1573
1602
|
@registry_stub.create_api_spec request, options do |result, operation|
|
1574
1603
|
yield result, operation if block_given?
|
1575
|
-
return result
|
1576
1604
|
end
|
1577
1605
|
rescue ::Gapic::Rest::Error => e
|
1578
1606
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1643,12 +1671,13 @@ module Google
|
|
1643
1671
|
# Customize the options with defaults
|
1644
1672
|
call_metadata = @config.rpcs.update_api_spec.metadata.to_h
|
1645
1673
|
|
1646
|
-
# Set x-goog-api-client
|
1674
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1647
1675
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1648
1676
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1649
1677
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1650
1678
|
transports_version_send: [:rest]
|
1651
1679
|
|
1680
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1652
1681
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1653
1682
|
|
1654
1683
|
options.apply_defaults timeout: @config.rpcs.update_api_spec.timeout,
|
@@ -1661,7 +1690,6 @@ module Google
|
|
1661
1690
|
|
1662
1691
|
@registry_stub.update_api_spec request, options do |result, operation|
|
1663
1692
|
yield result, operation if block_given?
|
1664
|
-
return result
|
1665
1693
|
end
|
1666
1694
|
rescue ::Gapic::Rest::Error => e
|
1667
1695
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1726,12 +1754,13 @@ module Google
|
|
1726
1754
|
# Customize the options with defaults
|
1727
1755
|
call_metadata = @config.rpcs.delete_api_spec.metadata.to_h
|
1728
1756
|
|
1729
|
-
# Set x-goog-api-client
|
1757
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1730
1758
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1731
1759
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1732
1760
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1733
1761
|
transports_version_send: [:rest]
|
1734
1762
|
|
1763
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1735
1764
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1736
1765
|
|
1737
1766
|
options.apply_defaults timeout: @config.rpcs.delete_api_spec.timeout,
|
@@ -1744,7 +1773,6 @@ module Google
|
|
1744
1773
|
|
1745
1774
|
@registry_stub.delete_api_spec request, options do |result, operation|
|
1746
1775
|
yield result, operation if block_given?
|
1747
|
-
return result
|
1748
1776
|
end
|
1749
1777
|
rescue ::Gapic::Rest::Error => e
|
1750
1778
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1807,12 +1835,13 @@ module Google
|
|
1807
1835
|
# Customize the options with defaults
|
1808
1836
|
call_metadata = @config.rpcs.tag_api_spec_revision.metadata.to_h
|
1809
1837
|
|
1810
|
-
# Set x-goog-api-client
|
1838
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1811
1839
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1812
1840
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1813
1841
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1814
1842
|
transports_version_send: [:rest]
|
1815
1843
|
|
1844
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1816
1845
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1817
1846
|
|
1818
1847
|
options.apply_defaults timeout: @config.rpcs.tag_api_spec_revision.timeout,
|
@@ -1825,7 +1854,6 @@ module Google
|
|
1825
1854
|
|
1826
1855
|
@registry_stub.tag_api_spec_revision request, options do |result, operation|
|
1827
1856
|
yield result, operation if block_given?
|
1828
|
-
return result
|
1829
1857
|
end
|
1830
1858
|
rescue ::Gapic::Rest::Error => e
|
1831
1859
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1895,12 +1923,13 @@ module Google
|
|
1895
1923
|
# Customize the options with defaults
|
1896
1924
|
call_metadata = @config.rpcs.list_api_spec_revisions.metadata.to_h
|
1897
1925
|
|
1898
|
-
# Set x-goog-api-client
|
1926
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1899
1927
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1900
1928
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1901
1929
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1902
1930
|
transports_version_send: [:rest]
|
1903
1931
|
|
1932
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1904
1933
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1905
1934
|
|
1906
1935
|
options.apply_defaults timeout: @config.rpcs.list_api_spec_revisions.timeout,
|
@@ -1914,7 +1943,7 @@ module Google
|
|
1914
1943
|
@registry_stub.list_api_spec_revisions request, options do |result, operation|
|
1915
1944
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_spec_revisions, "api_specs", request, result, options
|
1916
1945
|
yield result, operation if block_given?
|
1917
|
-
|
1946
|
+
throw :response, result
|
1918
1947
|
end
|
1919
1948
|
rescue ::Gapic::Rest::Error => e
|
1920
1949
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1980,12 +2009,13 @@ module Google
|
|
1980
2009
|
# Customize the options with defaults
|
1981
2010
|
call_metadata = @config.rpcs.rollback_api_spec.metadata.to_h
|
1982
2011
|
|
1983
|
-
# Set x-goog-api-client
|
2012
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1984
2013
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1985
2014
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1986
2015
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
1987
2016
|
transports_version_send: [:rest]
|
1988
2017
|
|
2018
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1989
2019
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1990
2020
|
|
1991
2021
|
options.apply_defaults timeout: @config.rpcs.rollback_api_spec.timeout,
|
@@ -1998,7 +2028,6 @@ module Google
|
|
1998
2028
|
|
1999
2029
|
@registry_stub.rollback_api_spec request, options do |result, operation|
|
2000
2030
|
yield result, operation if block_given?
|
2001
|
-
return result
|
2002
2031
|
end
|
2003
2032
|
rescue ::Gapic::Rest::Error => e
|
2004
2033
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2062,12 +2091,13 @@ module Google
|
|
2062
2091
|
# Customize the options with defaults
|
2063
2092
|
call_metadata = @config.rpcs.delete_api_spec_revision.metadata.to_h
|
2064
2093
|
|
2065
|
-
# Set x-goog-api-client
|
2094
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2066
2095
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2067
2096
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2068
2097
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2069
2098
|
transports_version_send: [:rest]
|
2070
2099
|
|
2100
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2071
2101
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2072
2102
|
|
2073
2103
|
options.apply_defaults timeout: @config.rpcs.delete_api_spec_revision.timeout,
|
@@ -2080,7 +2110,6 @@ module Google
|
|
2080
2110
|
|
2081
2111
|
@registry_stub.delete_api_spec_revision request, options do |result, operation|
|
2082
2112
|
yield result, operation if block_given?
|
2083
|
-
return result
|
2084
2113
|
end
|
2085
2114
|
rescue ::Gapic::Rest::Error => e
|
2086
2115
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2159,12 +2188,13 @@ module Google
|
|
2159
2188
|
# Customize the options with defaults
|
2160
2189
|
call_metadata = @config.rpcs.list_api_deployments.metadata.to_h
|
2161
2190
|
|
2162
|
-
# Set x-goog-api-client
|
2191
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2163
2192
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2164
2193
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2165
2194
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2166
2195
|
transports_version_send: [:rest]
|
2167
2196
|
|
2197
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2168
2198
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2169
2199
|
|
2170
2200
|
options.apply_defaults timeout: @config.rpcs.list_api_deployments.timeout,
|
@@ -2178,7 +2208,7 @@ module Google
|
|
2178
2208
|
@registry_stub.list_api_deployments request, options do |result, operation|
|
2179
2209
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_deployments, "api_deployments", request, result, options
|
2180
2210
|
yield result, operation if block_given?
|
2181
|
-
|
2211
|
+
throw :response, result
|
2182
2212
|
end
|
2183
2213
|
rescue ::Gapic::Rest::Error => e
|
2184
2214
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2239,12 +2269,13 @@ module Google
|
|
2239
2269
|
# Customize the options with defaults
|
2240
2270
|
call_metadata = @config.rpcs.get_api_deployment.metadata.to_h
|
2241
2271
|
|
2242
|
-
# Set x-goog-api-client
|
2272
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2243
2273
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2244
2274
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2245
2275
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2246
2276
|
transports_version_send: [:rest]
|
2247
2277
|
|
2278
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2248
2279
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2249
2280
|
|
2250
2281
|
options.apply_defaults timeout: @config.rpcs.get_api_deployment.timeout,
|
@@ -2257,7 +2288,6 @@ module Google
|
|
2257
2288
|
|
2258
2289
|
@registry_stub.get_api_deployment request, options do |result, operation|
|
2259
2290
|
yield result, operation if block_given?
|
2260
|
-
return result
|
2261
2291
|
end
|
2262
2292
|
rescue ::Gapic::Rest::Error => e
|
2263
2293
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2328,12 +2358,13 @@ module Google
|
|
2328
2358
|
# Customize the options with defaults
|
2329
2359
|
call_metadata = @config.rpcs.create_api_deployment.metadata.to_h
|
2330
2360
|
|
2331
|
-
# Set x-goog-api-client
|
2361
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2332
2362
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2333
2363
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2334
2364
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2335
2365
|
transports_version_send: [:rest]
|
2336
2366
|
|
2367
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2337
2368
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2338
2369
|
|
2339
2370
|
options.apply_defaults timeout: @config.rpcs.create_api_deployment.timeout,
|
@@ -2346,7 +2377,6 @@ module Google
|
|
2346
2377
|
|
2347
2378
|
@registry_stub.create_api_deployment request, options do |result, operation|
|
2348
2379
|
yield result, operation if block_given?
|
2349
|
-
return result
|
2350
2380
|
end
|
2351
2381
|
rescue ::Gapic::Rest::Error => e
|
2352
2382
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2417,12 +2447,13 @@ module Google
|
|
2417
2447
|
# Customize the options with defaults
|
2418
2448
|
call_metadata = @config.rpcs.update_api_deployment.metadata.to_h
|
2419
2449
|
|
2420
|
-
# Set x-goog-api-client
|
2450
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2421
2451
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2422
2452
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2423
2453
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2424
2454
|
transports_version_send: [:rest]
|
2425
2455
|
|
2456
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2426
2457
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2427
2458
|
|
2428
2459
|
options.apply_defaults timeout: @config.rpcs.update_api_deployment.timeout,
|
@@ -2435,7 +2466,6 @@ module Google
|
|
2435
2466
|
|
2436
2467
|
@registry_stub.update_api_deployment request, options do |result, operation|
|
2437
2468
|
yield result, operation if block_given?
|
2438
|
-
return result
|
2439
2469
|
end
|
2440
2470
|
rescue ::Gapic::Rest::Error => e
|
2441
2471
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2500,12 +2530,13 @@ module Google
|
|
2500
2530
|
# Customize the options with defaults
|
2501
2531
|
call_metadata = @config.rpcs.delete_api_deployment.metadata.to_h
|
2502
2532
|
|
2503
|
-
# Set x-goog-api-client
|
2533
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2504
2534
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2505
2535
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2506
2536
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2507
2537
|
transports_version_send: [:rest]
|
2508
2538
|
|
2539
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2509
2540
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2510
2541
|
|
2511
2542
|
options.apply_defaults timeout: @config.rpcs.delete_api_deployment.timeout,
|
@@ -2518,7 +2549,6 @@ module Google
|
|
2518
2549
|
|
2519
2550
|
@registry_stub.delete_api_deployment request, options do |result, operation|
|
2520
2551
|
yield result, operation if block_given?
|
2521
|
-
return result
|
2522
2552
|
end
|
2523
2553
|
rescue ::Gapic::Rest::Error => e
|
2524
2554
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2582,12 +2612,13 @@ module Google
|
|
2582
2612
|
# Customize the options with defaults
|
2583
2613
|
call_metadata = @config.rpcs.tag_api_deployment_revision.metadata.to_h
|
2584
2614
|
|
2585
|
-
# Set x-goog-api-client
|
2615
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2586
2616
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2587
2617
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2588
2618
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2589
2619
|
transports_version_send: [:rest]
|
2590
2620
|
|
2621
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2591
2622
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2592
2623
|
|
2593
2624
|
options.apply_defaults timeout: @config.rpcs.tag_api_deployment_revision.timeout,
|
@@ -2600,7 +2631,6 @@ module Google
|
|
2600
2631
|
|
2601
2632
|
@registry_stub.tag_api_deployment_revision request, options do |result, operation|
|
2602
2633
|
yield result, operation if block_given?
|
2603
|
-
return result
|
2604
2634
|
end
|
2605
2635
|
rescue ::Gapic::Rest::Error => e
|
2606
2636
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2670,12 +2700,13 @@ module Google
|
|
2670
2700
|
# Customize the options with defaults
|
2671
2701
|
call_metadata = @config.rpcs.list_api_deployment_revisions.metadata.to_h
|
2672
2702
|
|
2673
|
-
# Set x-goog-api-client
|
2703
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2674
2704
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2675
2705
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2676
2706
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2677
2707
|
transports_version_send: [:rest]
|
2678
2708
|
|
2709
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2679
2710
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2680
2711
|
|
2681
2712
|
options.apply_defaults timeout: @config.rpcs.list_api_deployment_revisions.timeout,
|
@@ -2689,7 +2720,7 @@ module Google
|
|
2689
2720
|
@registry_stub.list_api_deployment_revisions request, options do |result, operation|
|
2690
2721
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_deployment_revisions, "api_deployments", request, result, options
|
2691
2722
|
yield result, operation if block_given?
|
2692
|
-
|
2723
|
+
throw :response, result
|
2693
2724
|
end
|
2694
2725
|
rescue ::Gapic::Rest::Error => e
|
2695
2726
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2755,12 +2786,13 @@ module Google
|
|
2755
2786
|
# Customize the options with defaults
|
2756
2787
|
call_metadata = @config.rpcs.rollback_api_deployment.metadata.to_h
|
2757
2788
|
|
2758
|
-
# Set x-goog-api-client
|
2789
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2759
2790
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2760
2791
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2761
2792
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2762
2793
|
transports_version_send: [:rest]
|
2763
2794
|
|
2795
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2764
2796
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2765
2797
|
|
2766
2798
|
options.apply_defaults timeout: @config.rpcs.rollback_api_deployment.timeout,
|
@@ -2773,7 +2805,6 @@ module Google
|
|
2773
2805
|
|
2774
2806
|
@registry_stub.rollback_api_deployment request, options do |result, operation|
|
2775
2807
|
yield result, operation if block_given?
|
2776
|
-
return result
|
2777
2808
|
end
|
2778
2809
|
rescue ::Gapic::Rest::Error => e
|
2779
2810
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2837,12 +2868,13 @@ module Google
|
|
2837
2868
|
# Customize the options with defaults
|
2838
2869
|
call_metadata = @config.rpcs.delete_api_deployment_revision.metadata.to_h
|
2839
2870
|
|
2840
|
-
# Set x-goog-api-client
|
2871
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2841
2872
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2842
2873
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2843
2874
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2844
2875
|
transports_version_send: [:rest]
|
2845
2876
|
|
2877
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2846
2878
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2847
2879
|
|
2848
2880
|
options.apply_defaults timeout: @config.rpcs.delete_api_deployment_revision.timeout,
|
@@ -2855,7 +2887,6 @@ module Google
|
|
2855
2887
|
|
2856
2888
|
@registry_stub.delete_api_deployment_revision request, options do |result, operation|
|
2857
2889
|
yield result, operation if block_given?
|
2858
|
-
return result
|
2859
2890
|
end
|
2860
2891
|
rescue ::Gapic::Rest::Error => e
|
2861
2892
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2934,12 +2965,13 @@ module Google
|
|
2934
2965
|
# Customize the options with defaults
|
2935
2966
|
call_metadata = @config.rpcs.list_artifacts.metadata.to_h
|
2936
2967
|
|
2937
|
-
# Set x-goog-api-client
|
2968
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2938
2969
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2939
2970
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2940
2971
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
2941
2972
|
transports_version_send: [:rest]
|
2942
2973
|
|
2974
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2943
2975
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2944
2976
|
|
2945
2977
|
options.apply_defaults timeout: @config.rpcs.list_artifacts.timeout,
|
@@ -2953,7 +2985,7 @@ module Google
|
|
2953
2985
|
@registry_stub.list_artifacts request, options do |result, operation|
|
2954
2986
|
result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_artifacts, "artifacts", request, result, options
|
2955
2987
|
yield result, operation if block_given?
|
2956
|
-
|
2988
|
+
throw :response, result
|
2957
2989
|
end
|
2958
2990
|
rescue ::Gapic::Rest::Error => e
|
2959
2991
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3014,12 +3046,13 @@ module Google
|
|
3014
3046
|
# Customize the options with defaults
|
3015
3047
|
call_metadata = @config.rpcs.get_artifact.metadata.to_h
|
3016
3048
|
|
3017
|
-
# Set x-goog-api-client
|
3049
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3018
3050
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3019
3051
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3020
3052
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
3021
3053
|
transports_version_send: [:rest]
|
3022
3054
|
|
3055
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3023
3056
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3024
3057
|
|
3025
3058
|
options.apply_defaults timeout: @config.rpcs.get_artifact.timeout,
|
@@ -3032,7 +3065,6 @@ module Google
|
|
3032
3065
|
|
3033
3066
|
@registry_stub.get_artifact request, options do |result, operation|
|
3034
3067
|
yield result, operation if block_given?
|
3035
|
-
return result
|
3036
3068
|
end
|
3037
3069
|
rescue ::Gapic::Rest::Error => e
|
3038
3070
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3096,12 +3128,13 @@ module Google
|
|
3096
3128
|
# Customize the options with defaults
|
3097
3129
|
call_metadata = @config.rpcs.get_artifact_contents.metadata.to_h
|
3098
3130
|
|
3099
|
-
# Set x-goog-api-client
|
3131
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3100
3132
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3101
3133
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3102
3134
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
3103
3135
|
transports_version_send: [:rest]
|
3104
3136
|
|
3137
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3105
3138
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3106
3139
|
|
3107
3140
|
options.apply_defaults timeout: @config.rpcs.get_artifact_contents.timeout,
|
@@ -3114,7 +3147,6 @@ module Google
|
|
3114
3147
|
|
3115
3148
|
@registry_stub.get_artifact_contents request, options do |result, operation|
|
3116
3149
|
yield result, operation if block_given?
|
3117
|
-
return result
|
3118
3150
|
end
|
3119
3151
|
rescue ::Gapic::Rest::Error => e
|
3120
3152
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3185,12 +3217,13 @@ module Google
|
|
3185
3217
|
# Customize the options with defaults
|
3186
3218
|
call_metadata = @config.rpcs.create_artifact.metadata.to_h
|
3187
3219
|
|
3188
|
-
# Set x-goog-api-client
|
3220
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3189
3221
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3190
3222
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3191
3223
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
3192
3224
|
transports_version_send: [:rest]
|
3193
3225
|
|
3226
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3194
3227
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3195
3228
|
|
3196
3229
|
options.apply_defaults timeout: @config.rpcs.create_artifact.timeout,
|
@@ -3203,7 +3236,6 @@ module Google
|
|
3203
3236
|
|
3204
3237
|
@registry_stub.create_artifact request, options do |result, operation|
|
3205
3238
|
yield result, operation if block_given?
|
3206
|
-
return result
|
3207
3239
|
end
|
3208
3240
|
rescue ::Gapic::Rest::Error => e
|
3209
3241
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3266,12 +3298,13 @@ module Google
|
|
3266
3298
|
# Customize the options with defaults
|
3267
3299
|
call_metadata = @config.rpcs.replace_artifact.metadata.to_h
|
3268
3300
|
|
3269
|
-
# Set x-goog-api-client
|
3301
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3270
3302
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3271
3303
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3272
3304
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
3273
3305
|
transports_version_send: [:rest]
|
3274
3306
|
|
3307
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3275
3308
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3276
3309
|
|
3277
3310
|
options.apply_defaults timeout: @config.rpcs.replace_artifact.timeout,
|
@@ -3284,7 +3317,6 @@ module Google
|
|
3284
3317
|
|
3285
3318
|
@registry_stub.replace_artifact request, options do |result, operation|
|
3286
3319
|
yield result, operation if block_given?
|
3287
|
-
return result
|
3288
3320
|
end
|
3289
3321
|
rescue ::Gapic::Rest::Error => e
|
3290
3322
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3345,12 +3377,13 @@ module Google
|
|
3345
3377
|
# Customize the options with defaults
|
3346
3378
|
call_metadata = @config.rpcs.delete_artifact.metadata.to_h
|
3347
3379
|
|
3348
|
-
# Set x-goog-api-client
|
3380
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3349
3381
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3350
3382
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3351
3383
|
gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION,
|
3352
3384
|
transports_version_send: [:rest]
|
3353
3385
|
|
3386
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3354
3387
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3355
3388
|
|
3356
3389
|
options.apply_defaults timeout: @config.rpcs.delete_artifact.timeout,
|
@@ -3363,7 +3396,6 @@ module Google
|
|
3363
3396
|
|
3364
3397
|
@registry_stub.delete_artifact request, options do |result, operation|
|
3365
3398
|
yield result, operation if block_given?
|
3366
|
-
return result
|
3367
3399
|
end
|
3368
3400
|
rescue ::Gapic::Rest::Error => e
|
3369
3401
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3443,6 +3475,11 @@ module Google
|
|
3443
3475
|
# default endpoint URL. The default value of nil uses the environment
|
3444
3476
|
# universe (usually the default "googleapis.com" universe).
|
3445
3477
|
# @return [::String,nil]
|
3478
|
+
# @!attribute [rw] logger
|
3479
|
+
# A custom logger to use for request/response debug logging, or the value
|
3480
|
+
# `:default` (the default) to construct a default logger, or `nil` to
|
3481
|
+
# explicitly disable logging.
|
3482
|
+
# @return [::Logger,:default,nil]
|
3446
3483
|
#
|
3447
3484
|
class Configuration
|
3448
3485
|
extend ::Gapic::Config
|
@@ -3471,6 +3508,7 @@ module Google
|
|
3471
3508
|
# by the host service.
|
3472
3509
|
# @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
|
3473
3510
|
config_attr :bindings_override, {}, ::Hash, nil
|
3511
|
+
config_attr :logger, :default, ::Logger, nil, :default
|
3474
3512
|
|
3475
3513
|
# @private
|
3476
3514
|
def initialize parent_config = nil
|