google-cloud-deploy-v1 0.15.0 → 0.17.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/AUTHENTICATION.md +72 -99
- data/lib/google/cloud/deploy/v1/cloud_deploy/client.rb +85 -59
- data/lib/google/cloud/deploy/v1/cloud_deploy/operations.rb +28 -6
- data/lib/google/cloud/deploy/v1/cloud_deploy/rest/client.rb +87 -58
- data/lib/google/cloud/deploy/v1/cloud_deploy/rest/operations.rb +33 -8
- data/lib/google/cloud/deploy/v1/cloud_deploy/rest/service_stub.rb +14 -2
- data/lib/google/cloud/deploy/v1/cloud_deploy_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/deliverypipeline_notification_payload_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/jobrun_notification_payload_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/release_notification_payload_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/release_render_payload_pb.rb +2 -1
- data/lib/google/cloud/deploy/v1/rollout_notification_payload_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/rollout_update_payload_pb.rb +1 -1
- data/lib/google/cloud/deploy/v1/version.rb +1 -1
- data/proto_docs/google/api/client.rb +1 -0
- data/proto_docs/google/cloud/deploy/v1/cloud_deploy.rb +69 -66
- data/proto_docs/google/cloud/deploy/v1/deliverypipeline_notification_payload.rb +3 -0
- data/proto_docs/google/cloud/deploy/v1/jobrun_notification_payload.rb +6 -0
- data/proto_docs/google/cloud/deploy/v1/release_notification_payload.rb +6 -0
- data/proto_docs/google/cloud/deploy/v1/release_render_payload.rb +8 -0
- data/proto_docs/google/cloud/deploy/v1/rollout_notification_payload.rb +9 -3
- data/proto_docs/google/cloud/deploy/v1/rollout_update_payload.rb +11 -6
- metadata +9 -9
@@ -26,6 +26,9 @@ module Google
|
|
26
26
|
module CloudDeploy
|
27
27
|
# Service that implements Longrunning Operations API.
|
28
28
|
class Operations
|
29
|
+
# @private
|
30
|
+
DEFAULT_ENDPOINT_TEMPLATE = "clouddeploy.$UNIVERSE_DOMAIN$"
|
31
|
+
|
29
32
|
# @private
|
30
33
|
attr_reader :operations_stub
|
31
34
|
|
@@ -60,6 +63,15 @@ module Google
|
|
60
63
|
@config
|
61
64
|
end
|
62
65
|
|
66
|
+
##
|
67
|
+
# The effective universe domain
|
68
|
+
#
|
69
|
+
# @return [String]
|
70
|
+
#
|
71
|
+
def universe_domain
|
72
|
+
@operations_stub.universe_domain
|
73
|
+
end
|
74
|
+
|
63
75
|
##
|
64
76
|
# Create a new Operations client object.
|
65
77
|
#
|
@@ -90,8 +102,10 @@ module Google
|
|
90
102
|
|
91
103
|
@operations_stub = ::Gapic::ServiceStub.new(
|
92
104
|
::Google::Longrunning::Operations::Stub,
|
93
|
-
credentials:
|
94
|
-
endpoint:
|
105
|
+
credentials: credentials,
|
106
|
+
endpoint: @config.endpoint,
|
107
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
108
|
+
universe_domain: @config.universe_domain,
|
95
109
|
channel_args: @config.channel_args,
|
96
110
|
interceptors: @config.interceptors,
|
97
111
|
channel_pool_config: @config.channel_pool
|
@@ -613,9 +627,9 @@ module Google
|
|
613
627
|
# end
|
614
628
|
#
|
615
629
|
# @!attribute [rw] endpoint
|
616
|
-
#
|
617
|
-
#
|
618
|
-
# @return [::String]
|
630
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
631
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
632
|
+
# @return [::String,nil]
|
619
633
|
# @!attribute [rw] credentials
|
620
634
|
# Credentials to send with calls. You may provide any of the following types:
|
621
635
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -661,13 +675,20 @@ module Google
|
|
661
675
|
# @!attribute [rw] quota_project
|
662
676
|
# A separate project against which to charge quota.
|
663
677
|
# @return [::String]
|
678
|
+
# @!attribute [rw] universe_domain
|
679
|
+
# The universe domain within which to make requests. This determines the
|
680
|
+
# default endpoint URL. The default value of nil uses the environment
|
681
|
+
# universe (usually the default "googleapis.com" universe).
|
682
|
+
# @return [::String,nil]
|
664
683
|
#
|
665
684
|
class Configuration
|
666
685
|
extend ::Gapic::Config
|
667
686
|
|
687
|
+
# @private
|
688
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
668
689
|
DEFAULT_ENDPOINT = "clouddeploy.googleapis.com"
|
669
690
|
|
670
|
-
config_attr :endpoint,
|
691
|
+
config_attr :endpoint, nil, ::String, nil
|
671
692
|
config_attr :credentials, nil do |value|
|
672
693
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
673
694
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -682,6 +703,7 @@ module Google
|
|
682
703
|
config_attr :metadata, nil, ::Hash, nil
|
683
704
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
684
705
|
config_attr :quota_project, nil, ::String, nil
|
706
|
+
config_attr :universe_domain, nil, ::String, nil
|
685
707
|
|
686
708
|
# @private
|
687
709
|
def initialize parent_config = nil
|
@@ -35,6 +35,9 @@ module Google
|
|
35
35
|
# on Google Cloud Platform via Skaffold (https://skaffold.dev).
|
36
36
|
#
|
37
37
|
class Client
|
38
|
+
# @private
|
39
|
+
DEFAULT_ENDPOINT_TEMPLATE = "clouddeploy.$UNIVERSE_DOMAIN$"
|
40
|
+
|
38
41
|
include Paths
|
39
42
|
|
40
43
|
# @private
|
@@ -224,6 +227,15 @@ module Google
|
|
224
227
|
@config
|
225
228
|
end
|
226
229
|
|
230
|
+
##
|
231
|
+
# The effective universe domain
|
232
|
+
#
|
233
|
+
# @return [String]
|
234
|
+
#
|
235
|
+
def universe_domain
|
236
|
+
@cloud_deploy_stub.universe_domain
|
237
|
+
end
|
238
|
+
|
227
239
|
##
|
228
240
|
# Create a new CloudDeploy REST client object.
|
229
241
|
#
|
@@ -251,8 +263,9 @@ module Google
|
|
251
263
|
credentials = @config.credentials
|
252
264
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
253
265
|
# but only if the default endpoint does not have a region prefix.
|
254
|
-
enable_self_signed_jwt = @config.endpoint
|
255
|
-
|
266
|
+
enable_self_signed_jwt = @config.endpoint.nil? ||
|
267
|
+
(@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
268
|
+
!@config.endpoint.split(".").first.include?("-"))
|
256
269
|
credentials ||= Credentials.default scope: @config.scope,
|
257
270
|
enable_self_signed_jwt: enable_self_signed_jwt
|
258
271
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
@@ -266,12 +279,14 @@ module Google
|
|
266
279
|
config.credentials = credentials
|
267
280
|
config.quota_project = @quota_project_id
|
268
281
|
config.endpoint = @config.endpoint
|
282
|
+
config.universe_domain = @config.universe_domain
|
269
283
|
end
|
270
284
|
|
271
285
|
@location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
|
272
286
|
config.credentials = credentials
|
273
287
|
config.quota_project = @quota_project_id
|
274
288
|
config.endpoint = @config.endpoint
|
289
|
+
config.universe_domain = @config.universe_domain
|
275
290
|
config.bindings_override = @config.bindings_override
|
276
291
|
end
|
277
292
|
|
@@ -279,10 +294,16 @@ module Google
|
|
279
294
|
config.credentials = credentials
|
280
295
|
config.quota_project = @quota_project_id
|
281
296
|
config.endpoint = @config.endpoint
|
297
|
+
config.universe_domain = @config.universe_domain
|
282
298
|
config.bindings_override = @config.bindings_override
|
283
299
|
end
|
284
300
|
|
285
|
-
@cloud_deploy_stub = ::Google::Cloud::Deploy::V1::CloudDeploy::Rest::ServiceStub.new
|
301
|
+
@cloud_deploy_stub = ::Google::Cloud::Deploy::V1::CloudDeploy::Rest::ServiceStub.new(
|
302
|
+
endpoint: @config.endpoint,
|
303
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
304
|
+
universe_domain: @config.universe_domain,
|
305
|
+
credentials: credentials
|
306
|
+
)
|
286
307
|
end
|
287
308
|
|
288
309
|
##
|
@@ -514,9 +535,9 @@ module Google
|
|
514
535
|
# Required. The `DeliveryPipeline` to create.
|
515
536
|
# @param request_id [::String]
|
516
537
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
517
|
-
# so that if you must retry your request, the server
|
518
|
-
#
|
519
|
-
#
|
538
|
+
# so that if you must retry your request, the server knows to ignore the
|
539
|
+
# request if it has already been completed. The server guarantees that for
|
540
|
+
# at least 60 minutes after the first request.
|
520
541
|
#
|
521
542
|
# For example, consider a situation where you make an initial request and the
|
522
543
|
# request times out. If you make the request again with the same request ID,
|
@@ -617,15 +638,15 @@ module Google
|
|
617
638
|
# Required. Field mask is used to specify the fields to be overwritten in the
|
618
639
|
# `DeliveryPipeline` resource by the update.
|
619
640
|
# The fields specified in the update_mask are relative to the resource, not
|
620
|
-
# the full request. A field will be overwritten if it
|
621
|
-
# user
|
641
|
+
# the full request. A field will be overwritten if it's in the mask. If the
|
642
|
+
# user doesn't provide a mask then all fields are overwritten.
|
622
643
|
# @param delivery_pipeline [::Google::Cloud::Deploy::V1::DeliveryPipeline, ::Hash]
|
623
644
|
# Required. The `DeliveryPipeline` to update.
|
624
645
|
# @param request_id [::String]
|
625
646
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
626
|
-
# so that if you must retry your request, the server
|
627
|
-
#
|
628
|
-
#
|
647
|
+
# so that if you must retry your request, the server knows to ignore the
|
648
|
+
# request if it has already been completed. The server guarantees that for
|
649
|
+
# at least 60 minutes after the first request.
|
629
650
|
#
|
630
651
|
# For example, consider a situation where you make an initial request and the
|
631
652
|
# request times out. If you make the request again with the same request ID,
|
@@ -730,9 +751,9 @@ module Google
|
|
730
751
|
# `projects/{project_id}/locations/{location_name}/deliveryPipelines/{pipeline_name}`.
|
731
752
|
# @param request_id [::String]
|
732
753
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
733
|
-
# so that if you must retry your request, the server
|
734
|
-
#
|
735
|
-
#
|
754
|
+
# so that if you must retry your request, the server knows to ignore the
|
755
|
+
# request if it has already been completed. The server guarantees that for
|
756
|
+
# at least 60 minutes after the first request.
|
736
757
|
#
|
737
758
|
# For example, consider a situation where you make an initial request and the
|
738
759
|
# request times out. If you make the request again with the same request ID,
|
@@ -1125,9 +1146,9 @@ module Google
|
|
1125
1146
|
# Required. The `Target` to create.
|
1126
1147
|
# @param request_id [::String]
|
1127
1148
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1128
|
-
# so that if you must retry your request, the server
|
1129
|
-
#
|
1130
|
-
#
|
1149
|
+
# so that if you must retry your request, the server knows to ignore the
|
1150
|
+
# request if it has already been completed. The server guarantees that for
|
1151
|
+
# at least 60 minutes after the first request.
|
1131
1152
|
#
|
1132
1153
|
# For example, consider a situation where you make an initial request and the
|
1133
1154
|
# request times out. If you make the request again with the same request ID,
|
@@ -1228,15 +1249,15 @@ module Google
|
|
1228
1249
|
# Required. Field mask is used to specify the fields to be overwritten in the
|
1229
1250
|
# Target resource by the update.
|
1230
1251
|
# The fields specified in the update_mask are relative to the resource, not
|
1231
|
-
# the full request. A field will be overwritten if it
|
1232
|
-
# user
|
1252
|
+
# the full request. A field will be overwritten if it's in the mask. If the
|
1253
|
+
# user doesn't provide a mask then all fields are overwritten.
|
1233
1254
|
# @param target [::Google::Cloud::Deploy::V1::Target, ::Hash]
|
1234
1255
|
# Required. The `Target` to update.
|
1235
1256
|
# @param request_id [::String]
|
1236
1257
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1237
|
-
# so that if you must retry your request, the server
|
1238
|
-
#
|
1239
|
-
#
|
1258
|
+
# so that if you must retry your request, the server knows to ignore the
|
1259
|
+
# request if it has already been completed. The server guarantees that for
|
1260
|
+
# at least 60 minutes after the first request.
|
1240
1261
|
#
|
1241
1262
|
# For example, consider a situation where you make an initial request and the
|
1242
1263
|
# request times out. If you make the request again with the same request ID,
|
@@ -1341,9 +1362,9 @@ module Google
|
|
1341
1362
|
# `projects/{project_id}/locations/{location_name}/targets/{target_name}`.
|
1342
1363
|
# @param request_id [::String]
|
1343
1364
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1344
|
-
# so that if you must retry your request, the server
|
1345
|
-
#
|
1346
|
-
#
|
1365
|
+
# so that if you must retry your request, the server knows to ignore the
|
1366
|
+
# request if it has already been completed. The server guarantees that for
|
1367
|
+
# at least 60 minutes after the first request.
|
1347
1368
|
#
|
1348
1369
|
# For example, consider a situation where you make an initial request and the
|
1349
1370
|
# request times out. If you make the request again with the same request ID,
|
@@ -1628,7 +1649,7 @@ module Google
|
|
1628
1649
|
#
|
1629
1650
|
# @param parent [::String]
|
1630
1651
|
# Required. The parent collection in which the `CustomTargetType` should be
|
1631
|
-
# created
|
1652
|
+
# created. Format should be
|
1632
1653
|
# `projects/{project_id}/locations/{location_name}`.
|
1633
1654
|
# @param custom_target_type_id [::String]
|
1634
1655
|
# Required. ID of the `CustomTargetType`.
|
@@ -1636,9 +1657,9 @@ module Google
|
|
1636
1657
|
# Required. The `CustomTargetType` to create.
|
1637
1658
|
# @param request_id [::String]
|
1638
1659
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1639
|
-
# so that if you must retry your request, the server
|
1640
|
-
#
|
1641
|
-
#
|
1660
|
+
# so that if you must retry your request, the server knows to ignore the
|
1661
|
+
# request if it has already been completed. The server guarantees that for
|
1662
|
+
# at least 60 minutes after the first request.
|
1642
1663
|
#
|
1643
1664
|
# For example, consider a situation where you make an initial request and the
|
1644
1665
|
# request times out. If you make the request again with the same request ID,
|
@@ -1739,15 +1760,15 @@ module Google
|
|
1739
1760
|
# Required. Field mask is used to specify the fields to be overwritten in the
|
1740
1761
|
# `CustomTargetType` resource by the update.
|
1741
1762
|
# The fields specified in the update_mask are relative to the resource, not
|
1742
|
-
# the full request. A field will be overwritten if it
|
1743
|
-
# user
|
1763
|
+
# the full request. A field will be overwritten if it's in the mask. If the
|
1764
|
+
# user doesn't provide a mask then all fields are overwritten.
|
1744
1765
|
# @param custom_target_type [::Google::Cloud::Deploy::V1::CustomTargetType, ::Hash]
|
1745
1766
|
# Required. The `CustomTargetType` to update.
|
1746
1767
|
# @param request_id [::String]
|
1747
1768
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1748
|
-
# so that if you must retry your request, the server
|
1749
|
-
#
|
1750
|
-
#
|
1769
|
+
# so that if you must retry your request, the server knows to ignore the
|
1770
|
+
# request if it has already been completed. The server guarantees that for
|
1771
|
+
# at least 60 minutes after the first request.
|
1751
1772
|
#
|
1752
1773
|
# For example, consider a situation where you make an initial request and the
|
1753
1774
|
# request times out. If you make the request again with the same request ID,
|
@@ -1852,9 +1873,9 @@ module Google
|
|
1852
1873
|
# `projects/{project_id}/locations/{location_name}/customTargetTypes/{custom_target_type}`.
|
1853
1874
|
# @param request_id [::String]
|
1854
1875
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
1855
|
-
# so that if you must retry your request, the server
|
1856
|
-
#
|
1857
|
-
#
|
1876
|
+
# so that if you must retry your request, the server knows to ignore the
|
1877
|
+
# request if it has already been completed. The server guarantees that for
|
1878
|
+
# at least 60 minutes after the first request.
|
1858
1879
|
#
|
1859
1880
|
# For example, consider a situation where you make an initial request and the
|
1860
1881
|
# request times out. If you make the request again with the same request ID,
|
@@ -2147,9 +2168,9 @@ module Google
|
|
2147
2168
|
# Required. The `Release` to create.
|
2148
2169
|
# @param request_id [::String]
|
2149
2170
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
2150
|
-
# so that if you must retry your request, the server
|
2151
|
-
#
|
2152
|
-
#
|
2171
|
+
# so that if you must retry your request, the server knows to ignore the
|
2172
|
+
# request if it has already been completed. The server guarantees that for
|
2173
|
+
# at least 60 minutes after the first request.
|
2153
2174
|
#
|
2154
2175
|
# For example, consider a situation where you make an initial request and the
|
2155
2176
|
# request times out. If you make the request again with the same request ID,
|
@@ -2754,9 +2775,9 @@ module Google
|
|
2754
2775
|
# Required. The `Rollout` to create.
|
2755
2776
|
# @param request_id [::String]
|
2756
2777
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
2757
|
-
# so that if you must retry your request, the server
|
2758
|
-
#
|
2759
|
-
#
|
2778
|
+
# so that if you must retry your request, the server knows to ignore the
|
2779
|
+
# request if it has already been completed. The server guarantees that for
|
2780
|
+
# at least 60 minutes after the first request.
|
2760
2781
|
#
|
2761
2782
|
# For example, consider a situation where you make an initial request and the
|
2762
2783
|
# request times out. If you make the request again with the same request ID,
|
@@ -3367,9 +3388,9 @@ module Google
|
|
3367
3388
|
# Required. The `Automation` to create.
|
3368
3389
|
# @param request_id [::String]
|
3369
3390
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
3370
|
-
# so that if you must retry your request, the server
|
3371
|
-
#
|
3372
|
-
#
|
3391
|
+
# so that if you must retry your request, the server knows to ignore the
|
3392
|
+
# request if it has already been completed. The server guarantees that for
|
3393
|
+
# at least 60 minutes after the first request.
|
3373
3394
|
#
|
3374
3395
|
# For example, consider a situation where you make an initial request and the
|
3375
3396
|
# request times out. If you make the request again with the same request ID,
|
@@ -3470,15 +3491,15 @@ module Google
|
|
3470
3491
|
# Required. Field mask is used to specify the fields to be overwritten in the
|
3471
3492
|
# `Automation` resource by the update.
|
3472
3493
|
# The fields specified in the update_mask are relative to the resource, not
|
3473
|
-
# the full request. A field will be overwritten if it
|
3474
|
-
# user
|
3494
|
+
# the full request. A field will be overwritten if it's in the mask. If the
|
3495
|
+
# user doesn't provide a mask then all fields are overwritten.
|
3475
3496
|
# @param automation [::Google::Cloud::Deploy::V1::Automation, ::Hash]
|
3476
3497
|
# Required. The `Automation` to update.
|
3477
3498
|
# @param request_id [::String]
|
3478
3499
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
3479
|
-
# so that if you must retry your request, the server
|
3480
|
-
#
|
3481
|
-
#
|
3500
|
+
# so that if you must retry your request, the server knows to ignore the
|
3501
|
+
# request if it has already been completed. The server guarantees that for
|
3502
|
+
# at least 60 minutes after the first request.
|
3482
3503
|
#
|
3483
3504
|
# For example, consider a situation where you make an initial request and the
|
3484
3505
|
# request times out. If you make the request again with the same request ID,
|
@@ -3583,9 +3604,9 @@ module Google
|
|
3583
3604
|
# `projects/{project_id}/locations/{location_name}/deliveryPipelines/{pipeline_name}/automations/{automation_name}`.
|
3584
3605
|
# @param request_id [::String]
|
3585
3606
|
# Optional. A request ID to identify requests. Specify a unique request ID
|
3586
|
-
# so that if you must retry your request, the server
|
3587
|
-
#
|
3588
|
-
#
|
3607
|
+
# so that if you must retry your request, the server knows to ignore the
|
3608
|
+
# request if it has already been completed. The server guarantees that for
|
3609
|
+
# at least 60 minutes after the first request.
|
3589
3610
|
#
|
3590
3611
|
# For example, consider a situation where you make an initial request and the
|
3591
3612
|
# request times out. If you make the request again with the same request ID,
|
@@ -4142,9 +4163,9 @@ module Google
|
|
4142
4163
|
# end
|
4143
4164
|
#
|
4144
4165
|
# @!attribute [rw] endpoint
|
4145
|
-
#
|
4146
|
-
#
|
4147
|
-
# @return [::String]
|
4166
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
4167
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
4168
|
+
# @return [::String,nil]
|
4148
4169
|
# @!attribute [rw] credentials
|
4149
4170
|
# Credentials to send with calls. You may provide any of the following types:
|
4150
4171
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -4181,13 +4202,20 @@ module Google
|
|
4181
4202
|
# @!attribute [rw] quota_project
|
4182
4203
|
# A separate project against which to charge quota.
|
4183
4204
|
# @return [::String]
|
4205
|
+
# @!attribute [rw] universe_domain
|
4206
|
+
# The universe domain within which to make requests. This determines the
|
4207
|
+
# default endpoint URL. The default value of nil uses the environment
|
4208
|
+
# universe (usually the default "googleapis.com" universe).
|
4209
|
+
# @return [::String,nil]
|
4184
4210
|
#
|
4185
4211
|
class Configuration
|
4186
4212
|
extend ::Gapic::Config
|
4187
4213
|
|
4214
|
+
# @private
|
4215
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
4188
4216
|
DEFAULT_ENDPOINT = "clouddeploy.googleapis.com"
|
4189
4217
|
|
4190
|
-
config_attr :endpoint,
|
4218
|
+
config_attr :endpoint, nil, ::String, nil
|
4191
4219
|
config_attr :credentials, nil do |value|
|
4192
4220
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
4193
4221
|
allowed.any? { |klass| klass === value }
|
@@ -4199,6 +4227,7 @@ module Google
|
|
4199
4227
|
config_attr :metadata, nil, ::Hash, nil
|
4200
4228
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
4201
4229
|
config_attr :quota_project, nil, ::String, nil
|
4230
|
+
config_attr :universe_domain, nil, ::String, nil
|
4202
4231
|
|
4203
4232
|
# @private
|
4204
4233
|
# Overrides for http bindings for the RPCs of this service
|
@@ -26,6 +26,9 @@ module Google
|
|
26
26
|
module Rest
|
27
27
|
# Service that implements Longrunning Operations API.
|
28
28
|
class Operations
|
29
|
+
# @private
|
30
|
+
DEFAULT_ENDPOINT_TEMPLATE = "clouddeploy.$UNIVERSE_DOMAIN$"
|
31
|
+
|
29
32
|
# @private
|
30
33
|
attr_reader :operations_stub
|
31
34
|
|
@@ -60,6 +63,15 @@ module Google
|
|
60
63
|
@config
|
61
64
|
end
|
62
65
|
|
66
|
+
##
|
67
|
+
# The effective universe domain
|
68
|
+
#
|
69
|
+
# @return [String]
|
70
|
+
#
|
71
|
+
def universe_domain
|
72
|
+
@operations_stub.universe_domain
|
73
|
+
end
|
74
|
+
|
63
75
|
##
|
64
76
|
# Create a new Operations client object.
|
65
77
|
#
|
@@ -84,8 +96,10 @@ module Google
|
|
84
96
|
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
85
97
|
|
86
98
|
@operations_stub = OperationsServiceStub.new(
|
87
|
-
endpoint:
|
88
|
-
|
99
|
+
endpoint: @config.endpoint,
|
100
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
101
|
+
universe_domain: @config.universe_domain,
|
102
|
+
credentials: credentials
|
89
103
|
)
|
90
104
|
|
91
105
|
# Used by an LRO wrapper for some methods of this service
|
@@ -478,9 +492,9 @@ module Google
|
|
478
492
|
# end
|
479
493
|
#
|
480
494
|
# @!attribute [rw] endpoint
|
481
|
-
#
|
482
|
-
#
|
483
|
-
# @return [::String]
|
495
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
496
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
497
|
+
# @return [::String,nil]
|
484
498
|
# @!attribute [rw] credentials
|
485
499
|
# Credentials to send with calls. You may provide any of the following types:
|
486
500
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -517,13 +531,20 @@ module Google
|
|
517
531
|
# @!attribute [rw] quota_project
|
518
532
|
# A separate project against which to charge quota.
|
519
533
|
# @return [::String]
|
534
|
+
# @!attribute [rw] universe_domain
|
535
|
+
# The universe domain within which to make requests. This determines the
|
536
|
+
# default endpoint URL. The default value of nil uses the environment
|
537
|
+
# universe (usually the default "googleapis.com" universe).
|
538
|
+
# @return [::String,nil]
|
520
539
|
#
|
521
540
|
class Configuration
|
522
541
|
extend ::Gapic::Config
|
523
542
|
|
543
|
+
# @private
|
544
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
524
545
|
DEFAULT_ENDPOINT = "clouddeploy.googleapis.com"
|
525
546
|
|
526
|
-
config_attr :endpoint,
|
547
|
+
config_attr :endpoint, nil, ::String, nil
|
527
548
|
config_attr :credentials, nil do |value|
|
528
549
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
529
550
|
allowed.any? { |klass| klass === value }
|
@@ -535,6 +556,7 @@ module Google
|
|
535
556
|
config_attr :metadata, nil, ::Hash, nil
|
536
557
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
537
558
|
config_attr :quota_project, nil, ::String, nil
|
559
|
+
config_attr :universe_domain, nil, ::String, nil
|
538
560
|
|
539
561
|
# @private
|
540
562
|
def initialize parent_config = nil
|
@@ -617,12 +639,15 @@ module Google
|
|
617
639
|
# Service stub contains baseline method implementations
|
618
640
|
# including transcoding, making the REST call, and deserialing the response.
|
619
641
|
class OperationsServiceStub
|
620
|
-
def initialize endpoint:, credentials:
|
642
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
|
621
643
|
# These require statements are intentionally placed here to initialize
|
622
644
|
# the REST modules only when it's required.
|
623
645
|
require "gapic/rest"
|
624
646
|
|
625
|
-
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
647
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
648
|
+
endpoint_template: endpoint_template,
|
649
|
+
universe_domain: universe_domain,
|
650
|
+
credentials: credentials
|
626
651
|
end
|
627
652
|
|
628
653
|
##
|
@@ -30,16 +30,28 @@ module Google
|
|
30
30
|
# including transcoding, making the REST call, and deserialing the response.
|
31
31
|
#
|
32
32
|
class ServiceStub
|
33
|
-
def initialize endpoint:, credentials:
|
33
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
|
34
34
|
# These require statements are intentionally placed here to initialize
|
35
35
|
# the REST modules only when it's required.
|
36
36
|
require "gapic/rest"
|
37
37
|
|
38
|
-
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
38
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
39
|
+
endpoint_template: endpoint_template,
|
40
|
+
universe_domain: universe_domain,
|
41
|
+
credentials: credentials,
|
39
42
|
numeric_enums: true,
|
40
43
|
raise_faraday_errors: false
|
41
44
|
end
|
42
45
|
|
46
|
+
##
|
47
|
+
# The effective universe domain
|
48
|
+
#
|
49
|
+
# @return [String]
|
50
|
+
#
|
51
|
+
def universe_domain
|
52
|
+
@client_stub.universe_domain
|
53
|
+
end
|
54
|
+
|
43
55
|
##
|
44
56
|
# Baseline implementation for the list_delivery_pipelines REST call
|
45
57
|
#
|