google-cloud-compute-v1 2.5.0 → 2.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +72 -101
- data/lib/google/cloud/compute/v1/accelerator_types/rest/client.rb +37 -10
- data/lib/google/cloud/compute/v1/accelerator_types/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/addresses/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/addresses/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/autoscalers/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/autoscalers/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/backend_buckets/rest/client.rb +311 -8
- data/lib/google/cloud/compute/v1/backend_buckets/rest/service_stub.rb +196 -2
- data/lib/google/cloud/compute/v1/backend_services/rest/client.rb +230 -10
- data/lib/google/cloud/compute/v1/backend_services/rest/service_stub.rb +134 -2
- data/lib/google/cloud/compute/v1/compute_pb.rb +79 -1
- data/lib/google/cloud/compute/v1/disk_types/rest/client.rb +37 -10
- data/lib/google/cloud/compute/v1/disk_types/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/disks/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/disks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/external_vpn_gateways/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/firewall_policies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/firewall_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/firewalls/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/firewalls/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/forwarding_rules/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_addresses/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/global_addresses/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/global_forwarding_rules/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/client.rb +36 -9
- data/lib/google/cloud/compute/v1/global_network_endpoint_groups/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_operations/rest/client.rb +37 -10
- data/lib/google/cloud/compute/v1/global_operations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/global_organization_operations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/global_public_delegated_prefixes/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/health_checks/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/health_checks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/image_family_views/rest/client.rb +33 -7
- data/lib/google/cloud/compute/v1/image_family_views/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/images/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/images/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/client.rb +41 -13
- data/lib/google/cloud/compute/v1/instance_group_managers/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/instance_groups/rest/client.rb +39 -11
- data/lib/google/cloud/compute/v1/instance_groups/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/instance_templates/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/instance_templates/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/instances/rest/client.rb +143 -11
- data/lib/google/cloud/compute/v1/instances/rest/service_stub.rb +76 -2
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/interconnect_attachments/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/interconnect_locations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/interconnect_remote_locations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/interconnects/rest/client.rb +128 -9
- data/lib/google/cloud/compute/v1/interconnects/rest/service_stub.rb +74 -2
- data/lib/google/cloud/compute/v1/license_codes/rest/client.rb +33 -7
- data/lib/google/cloud/compute/v1/license_codes/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/licenses/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/licenses/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/machine_images/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/machine_images/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/machine_types/rest/client.rb +37 -10
- data/lib/google/cloud/compute/v1/machine_types/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/network_attachments/rest/client.rb +142 -10
- data/lib/google/cloud/compute/v1/network_attachments/rest/service_stub.rb +76 -2
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/client.rb +37 -9
- data/lib/google/cloud/compute/v1/network_edge_security_services/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/client.rb +39 -11
- data/lib/google/cloud/compute/v1/network_endpoint_groups/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/network_firewall_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/networks/rest/client.rb +36 -9
- data/lib/google/cloud/compute/v1/networks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/node_groups/rest/client.rb +39 -11
- data/lib/google/cloud/compute/v1/node_groups/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/node_templates/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/node_templates/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/node_types/rest/client.rb +37 -10
- data/lib/google/cloud/compute/v1/node_types/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/packet_mirrorings/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/projects/rest/client.rb +36 -9
- data/lib/google/cloud/compute/v1/projects/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/client.rb +236 -11
- data/lib/google/cloud/compute/v1/public_advertised_prefixes/rest/service_stub.rb +134 -2
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/client.rb +242 -10
- data/lib/google/cloud/compute/v1/public_delegated_prefixes/rest/service_stub.rb +136 -2
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_autoscalers/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_backend_services/rest/client.rb +335 -8
- data/lib/google/cloud/compute/v1/region_backend_services/rest/service_stub.rb +198 -2
- data/lib/google/cloud/compute/v1/region_commitments/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/region_commitments/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_disk_types/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/region_disk_types/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_disks/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_disks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_health_check_services/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_health_checks/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_health_checks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/client.rb +38 -11
- data/lib/google/cloud/compute/v1/region_instance_group_managers/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/client.rb +36 -9
- data/lib/google/cloud/compute/v1/region_instance_groups/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_instance_templates/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_instance_templates/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_instances/rest/client.rb +34 -7
- data/lib/google/cloud/compute/v1/region_instances/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/client.rb +348 -11
- data/lib/google/cloud/compute/v1/region_network_endpoint_groups/rest/service_stub.rb +199 -2
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_network_firewall_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_notification_endpoints/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_operations/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/region_operations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_security_policies/rest/client.rb +451 -12
- data/lib/google/cloud/compute/v1/region_security_policies/rest/service_stub.rb +260 -2
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_ssl_certificates/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/client.rb +36 -9
- data/lib/google/cloud/compute/v1/region_ssl_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_target_http_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_target_https_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_target_tcp_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/region_url_maps/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/region_url_maps/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/regions/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/regions/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/reservations/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/reservations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/resource_policies/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/resource_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/rest.rb +1 -0
- data/lib/google/cloud/compute/v1/routers/rest/client.rb +135 -11
- data/lib/google/cloud/compute/v1/routers/rest/service_stub.rb +75 -2
- data/lib/google/cloud/compute/v1/routes/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/routes/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/security_policies/rest/client.rb +45 -13
- data/lib/google/cloud/compute/v1/security_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/service_attachments/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/service_attachments/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/snapshot_settings_service/credentials.rb +52 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/client.rb +507 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest/service_stub.rb +179 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service/rest.rb +51 -0
- data/lib/google/cloud/compute/v1/snapshot_settings_service.rb +47 -0
- data/lib/google/cloud/compute/v1/snapshots/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/snapshots/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/ssl_certificates/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/ssl_policies/rest/client.rb +39 -11
- data/lib/google/cloud/compute/v1/ssl_policies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/subnetworks/rest/client.rb +39 -11
- data/lib/google/cloud/compute/v1/subnetworks/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/target_grpc_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/target_http_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/target_https_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_instances/rest/client.rb +142 -10
- data/lib/google/cloud/compute/v1/target_instances/rest/service_stub.rb +76 -2
- data/lib/google/cloud/compute/v1/target_pools/rest/client.rb +142 -10
- data/lib/google/cloud/compute/v1/target_pools/rest/service_stub.rb +76 -2
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/client.rb +35 -8
- data/lib/google/cloud/compute/v1/target_ssl_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/target_tcp_proxies/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/target_vpn_gateways/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/url_maps/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/url_maps/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/version.rb +1 -1
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/vpn_gateways/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/client.rb +38 -10
- data/lib/google/cloud/compute/v1/vpn_tunnels/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/zone_operations/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/zone_operations/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1/zones/rest/client.rb +34 -8
- data/lib/google/cloud/compute/v1/zones/rest/service_stub.rb +14 -2
- data/lib/google/cloud/compute/v1.rb +1 -0
- data/proto_docs/google/api/client.rb +14 -0
- data/proto_docs/google/cloud/compute/v1/compute.rb +1654 -196
- data/proto_docs/google/protobuf/any.rb +144 -0
- metadata +11 -5
@@ -33,6 +33,9 @@ module Google
|
|
33
33
|
# The Subnetworks API.
|
34
34
|
#
|
35
35
|
class Client
|
36
|
+
# @private
|
37
|
+
DEFAULT_ENDPOINT_TEMPLATE = "compute.$UNIVERSE_DOMAIN$"
|
38
|
+
|
36
39
|
# @private
|
37
40
|
attr_reader :subnetworks_stub
|
38
41
|
|
@@ -130,6 +133,15 @@ module Google
|
|
130
133
|
@config
|
131
134
|
end
|
132
135
|
|
136
|
+
##
|
137
|
+
# The effective universe domain
|
138
|
+
#
|
139
|
+
# @return [String]
|
140
|
+
#
|
141
|
+
def universe_domain
|
142
|
+
@subnetworks_stub.universe_domain
|
143
|
+
end
|
144
|
+
|
133
145
|
##
|
134
146
|
# Create a new Subnetworks REST client object.
|
135
147
|
#
|
@@ -157,8 +169,9 @@ module Google
|
|
157
169
|
credentials = @config.credentials
|
158
170
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
159
171
|
# but only if the default endpoint does not have a region prefix.
|
160
|
-
enable_self_signed_jwt = @config.endpoint
|
161
|
-
|
172
|
+
enable_self_signed_jwt = @config.endpoint.nil? ||
|
173
|
+
(@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
174
|
+
!@config.endpoint.split(".").first.include?("-"))
|
162
175
|
credentials ||= Credentials.default scope: @config.scope,
|
163
176
|
enable_self_signed_jwt: enable_self_signed_jwt
|
164
177
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
@@ -172,9 +185,15 @@ module Google
|
|
172
185
|
config.credentials = credentials
|
173
186
|
config.quota_project = @quota_project_id
|
174
187
|
config.endpoint = @config.endpoint
|
188
|
+
config.universe_domain = @config.universe_domain
|
175
189
|
end
|
176
190
|
|
177
|
-
@subnetworks_stub = ::Google::Cloud::Compute::V1::Subnetworks::Rest::ServiceStub.new
|
191
|
+
@subnetworks_stub = ::Google::Cloud::Compute::V1::Subnetworks::Rest::ServiceStub.new(
|
192
|
+
endpoint: @config.endpoint,
|
193
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
194
|
+
universe_domain: @config.universe_domain,
|
195
|
+
credentials: credentials
|
196
|
+
)
|
178
197
|
end
|
179
198
|
|
180
199
|
##
|
@@ -199,13 +218,13 @@ module Google
|
|
199
218
|
# @param options [::Gapic::CallOptions, ::Hash]
|
200
219
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
201
220
|
#
|
202
|
-
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil)
|
221
|
+
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil, service_project_number: nil)
|
203
222
|
# Pass arguments to `aggregated_list` via keyword arguments. Note that at
|
204
223
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
205
224
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
206
225
|
#
|
207
226
|
# @param filter [::String]
|
208
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
227
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
209
228
|
# @param include_all_scopes [::Boolean]
|
210
229
|
# Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.
|
211
230
|
# @param max_results [::Integer]
|
@@ -218,6 +237,7 @@ module Google
|
|
218
237
|
# Project ID for this request.
|
219
238
|
# @param return_partial_success [::Boolean]
|
220
239
|
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
240
|
+
# @param service_project_number [::Integer]
|
221
241
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
222
242
|
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::String, ::Google::Cloud::Compute::V1::SubnetworksScopedList>]
|
223
243
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -743,7 +763,7 @@ module Google
|
|
743
763
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
744
764
|
#
|
745
765
|
# @param filter [::String]
|
746
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
766
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
747
767
|
# @param max_results [::Integer]
|
748
768
|
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
749
769
|
# @param order_by [::String]
|
@@ -834,7 +854,7 @@ module Google
|
|
834
854
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
835
855
|
#
|
836
856
|
# @param filter [::String]
|
837
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
857
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
838
858
|
# @param max_results [::Integer]
|
839
859
|
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
840
860
|
# @param order_by [::String]
|
@@ -1294,9 +1314,9 @@ module Google
|
|
1294
1314
|
# end
|
1295
1315
|
#
|
1296
1316
|
# @!attribute [rw] endpoint
|
1297
|
-
#
|
1298
|
-
#
|
1299
|
-
# @return [::String]
|
1317
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
1318
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
1319
|
+
# @return [::String,nil]
|
1300
1320
|
# @!attribute [rw] credentials
|
1301
1321
|
# Credentials to send with calls. You may provide any of the following types:
|
1302
1322
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -1333,13 +1353,20 @@ module Google
|
|
1333
1353
|
# @!attribute [rw] quota_project
|
1334
1354
|
# A separate project against which to charge quota.
|
1335
1355
|
# @return [::String]
|
1356
|
+
# @!attribute [rw] universe_domain
|
1357
|
+
# The universe domain within which to make requests. This determines the
|
1358
|
+
# default endpoint URL. The default value of nil uses the environment
|
1359
|
+
# universe (usually the default "googleapis.com" universe).
|
1360
|
+
# @return [::String,nil]
|
1336
1361
|
#
|
1337
1362
|
class Configuration
|
1338
1363
|
extend ::Gapic::Config
|
1339
1364
|
|
1365
|
+
# @private
|
1366
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
1340
1367
|
DEFAULT_ENDPOINT = "compute.googleapis.com"
|
1341
1368
|
|
1342
|
-
config_attr :endpoint,
|
1369
|
+
config_attr :endpoint, nil, ::String, nil
|
1343
1370
|
config_attr :credentials, nil do |value|
|
1344
1371
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
1345
1372
|
allowed.any? { |klass| klass === value }
|
@@ -1351,6 +1378,7 @@ module Google
|
|
1351
1378
|
config_attr :metadata, nil, ::Hash, nil
|
1352
1379
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
1353
1380
|
config_attr :quota_project, nil, ::String, nil
|
1381
|
+
config_attr :universe_domain, nil, ::String, nil
|
1354
1382
|
|
1355
1383
|
# @private
|
1356
1384
|
def initialize parent_config = nil
|
@@ -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: false,
|
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 aggregated_list REST call
|
45
57
|
#
|
@@ -33,6 +33,9 @@ module Google
|
|
33
33
|
# The TargetGrpcProxies API.
|
34
34
|
#
|
35
35
|
class Client
|
36
|
+
# @private
|
37
|
+
DEFAULT_ENDPOINT_TEMPLATE = "compute.$UNIVERSE_DOMAIN$"
|
38
|
+
|
36
39
|
# @private
|
37
40
|
attr_reader :target_grpc_proxies_stub
|
38
41
|
|
@@ -107,6 +110,15 @@ module Google
|
|
107
110
|
@config
|
108
111
|
end
|
109
112
|
|
113
|
+
##
|
114
|
+
# The effective universe domain
|
115
|
+
#
|
116
|
+
# @return [String]
|
117
|
+
#
|
118
|
+
def universe_domain
|
119
|
+
@target_grpc_proxies_stub.universe_domain
|
120
|
+
end
|
121
|
+
|
110
122
|
##
|
111
123
|
# Create a new TargetGrpcProxies REST client object.
|
112
124
|
#
|
@@ -134,8 +146,9 @@ module Google
|
|
134
146
|
credentials = @config.credentials
|
135
147
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
136
148
|
# but only if the default endpoint does not have a region prefix.
|
137
|
-
enable_self_signed_jwt = @config.endpoint
|
138
|
-
|
149
|
+
enable_self_signed_jwt = @config.endpoint.nil? ||
|
150
|
+
(@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
151
|
+
!@config.endpoint.split(".").first.include?("-"))
|
139
152
|
credentials ||= Credentials.default scope: @config.scope,
|
140
153
|
enable_self_signed_jwt: enable_self_signed_jwt
|
141
154
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
@@ -149,9 +162,15 @@ module Google
|
|
149
162
|
config.credentials = credentials
|
150
163
|
config.quota_project = @quota_project_id
|
151
164
|
config.endpoint = @config.endpoint
|
165
|
+
config.universe_domain = @config.universe_domain
|
152
166
|
end
|
153
167
|
|
154
|
-
@target_grpc_proxies_stub = ::Google::Cloud::Compute::V1::TargetGrpcProxies::Rest::ServiceStub.new
|
168
|
+
@target_grpc_proxies_stub = ::Google::Cloud::Compute::V1::TargetGrpcProxies::Rest::ServiceStub.new(
|
169
|
+
endpoint: @config.endpoint,
|
170
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
171
|
+
universe_domain: @config.universe_domain,
|
172
|
+
credentials: credentials
|
173
|
+
)
|
155
174
|
end
|
156
175
|
|
157
176
|
##
|
@@ -442,7 +461,7 @@ module Google
|
|
442
461
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
443
462
|
#
|
444
463
|
# @param filter [::String]
|
445
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
464
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
446
465
|
# @param max_results [::Integer]
|
447
466
|
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
448
467
|
# @param order_by [::String]
|
@@ -634,9 +653,9 @@ module Google
|
|
634
653
|
# end
|
635
654
|
#
|
636
655
|
# @!attribute [rw] endpoint
|
637
|
-
#
|
638
|
-
#
|
639
|
-
# @return [::String]
|
656
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
657
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
658
|
+
# @return [::String,nil]
|
640
659
|
# @!attribute [rw] credentials
|
641
660
|
# Credentials to send with calls. You may provide any of the following types:
|
642
661
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -673,13 +692,20 @@ module Google
|
|
673
692
|
# @!attribute [rw] quota_project
|
674
693
|
# A separate project against which to charge quota.
|
675
694
|
# @return [::String]
|
695
|
+
# @!attribute [rw] universe_domain
|
696
|
+
# The universe domain within which to make requests. This determines the
|
697
|
+
# default endpoint URL. The default value of nil uses the environment
|
698
|
+
# universe (usually the default "googleapis.com" universe).
|
699
|
+
# @return [::String,nil]
|
676
700
|
#
|
677
701
|
class Configuration
|
678
702
|
extend ::Gapic::Config
|
679
703
|
|
704
|
+
# @private
|
705
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
680
706
|
DEFAULT_ENDPOINT = "compute.googleapis.com"
|
681
707
|
|
682
|
-
config_attr :endpoint,
|
708
|
+
config_attr :endpoint, nil, ::String, nil
|
683
709
|
config_attr :credentials, nil do |value|
|
684
710
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
685
711
|
allowed.any? { |klass| klass === value }
|
@@ -691,6 +717,7 @@ module Google
|
|
691
717
|
config_attr :metadata, nil, ::Hash, nil
|
692
718
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
693
719
|
config_attr :quota_project, nil, ::String, nil
|
720
|
+
config_attr :universe_domain, nil, ::String, nil
|
694
721
|
|
695
722
|
# @private
|
696
723
|
def initialize parent_config = nil
|
@@ -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: false,
|
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 delete REST call
|
45
57
|
#
|
@@ -33,6 +33,9 @@ module Google
|
|
33
33
|
# The TargetHttpProxies API.
|
34
34
|
#
|
35
35
|
class Client
|
36
|
+
# @private
|
37
|
+
DEFAULT_ENDPOINT_TEMPLATE = "compute.$UNIVERSE_DOMAIN$"
|
38
|
+
|
36
39
|
# @private
|
37
40
|
attr_reader :target_http_proxies_stub
|
38
41
|
|
@@ -114,6 +117,15 @@ module Google
|
|
114
117
|
@config
|
115
118
|
end
|
116
119
|
|
120
|
+
##
|
121
|
+
# The effective universe domain
|
122
|
+
#
|
123
|
+
# @return [String]
|
124
|
+
#
|
125
|
+
def universe_domain
|
126
|
+
@target_http_proxies_stub.universe_domain
|
127
|
+
end
|
128
|
+
|
117
129
|
##
|
118
130
|
# Create a new TargetHttpProxies REST client object.
|
119
131
|
#
|
@@ -141,8 +153,9 @@ module Google
|
|
141
153
|
credentials = @config.credentials
|
142
154
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
143
155
|
# but only if the default endpoint does not have a region prefix.
|
144
|
-
enable_self_signed_jwt = @config.endpoint
|
145
|
-
|
156
|
+
enable_self_signed_jwt = @config.endpoint.nil? ||
|
157
|
+
(@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
158
|
+
!@config.endpoint.split(".").first.include?("-"))
|
146
159
|
credentials ||= Credentials.default scope: @config.scope,
|
147
160
|
enable_self_signed_jwt: enable_self_signed_jwt
|
148
161
|
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
@@ -156,9 +169,15 @@ module Google
|
|
156
169
|
config.credentials = credentials
|
157
170
|
config.quota_project = @quota_project_id
|
158
171
|
config.endpoint = @config.endpoint
|
172
|
+
config.universe_domain = @config.universe_domain
|
159
173
|
end
|
160
174
|
|
161
|
-
@target_http_proxies_stub = ::Google::Cloud::Compute::V1::TargetHttpProxies::Rest::ServiceStub.new
|
175
|
+
@target_http_proxies_stub = ::Google::Cloud::Compute::V1::TargetHttpProxies::Rest::ServiceStub.new(
|
176
|
+
endpoint: @config.endpoint,
|
177
|
+
endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
|
178
|
+
universe_domain: @config.universe_domain,
|
179
|
+
credentials: credentials
|
180
|
+
)
|
162
181
|
end
|
163
182
|
|
164
183
|
##
|
@@ -183,13 +202,13 @@ module Google
|
|
183
202
|
# @param options [::Gapic::CallOptions, ::Hash]
|
184
203
|
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
185
204
|
#
|
186
|
-
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil)
|
205
|
+
# @overload aggregated_list(filter: nil, include_all_scopes: nil, max_results: nil, order_by: nil, page_token: nil, project: nil, return_partial_success: nil, service_project_number: nil)
|
187
206
|
# Pass arguments to `aggregated_list` via keyword arguments. Note that at
|
188
207
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
189
208
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
190
209
|
#
|
191
210
|
# @param filter [::String]
|
192
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
211
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
193
212
|
# @param include_all_scopes [::Boolean]
|
194
213
|
# Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.
|
195
214
|
# @param max_results [::Integer]
|
@@ -202,6 +221,7 @@ module Google
|
|
202
221
|
# Name of the project scoping this request.
|
203
222
|
# @param return_partial_success [::Boolean]
|
204
223
|
# Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.
|
224
|
+
# @param service_project_number [::Integer]
|
205
225
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
206
226
|
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::String, ::Google::Cloud::Compute::V1::TargetHttpProxiesScopedList>]
|
207
227
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -540,7 +560,7 @@ module Google
|
|
540
560
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
541
561
|
#
|
542
562
|
# @param filter [::String]
|
543
|
-
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The
|
563
|
+
# A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, `>=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted literal"` `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name "instance", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.
|
544
564
|
# @param max_results [::Integer]
|
545
565
|
# The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)
|
546
566
|
# @param order_by [::String]
|
@@ -824,9 +844,9 @@ module Google
|
|
824
844
|
# end
|
825
845
|
#
|
826
846
|
# @!attribute [rw] endpoint
|
827
|
-
#
|
828
|
-
#
|
829
|
-
# @return [::String]
|
847
|
+
# A custom service endpoint, as a hostname or hostname:port. The default is
|
848
|
+
# nil, indicating to use the default endpoint in the current universe domain.
|
849
|
+
# @return [::String,nil]
|
830
850
|
# @!attribute [rw] credentials
|
831
851
|
# Credentials to send with calls. You may provide any of the following types:
|
832
852
|
# * (`String`) The path to a service account key file in JSON format
|
@@ -863,13 +883,20 @@ module Google
|
|
863
883
|
# @!attribute [rw] quota_project
|
864
884
|
# A separate project against which to charge quota.
|
865
885
|
# @return [::String]
|
886
|
+
# @!attribute [rw] universe_domain
|
887
|
+
# The universe domain within which to make requests. This determines the
|
888
|
+
# default endpoint URL. The default value of nil uses the environment
|
889
|
+
# universe (usually the default "googleapis.com" universe).
|
890
|
+
# @return [::String,nil]
|
866
891
|
#
|
867
892
|
class Configuration
|
868
893
|
extend ::Gapic::Config
|
869
894
|
|
895
|
+
# @private
|
896
|
+
# The endpoint specific to the default "googleapis.com" universe. Deprecated.
|
870
897
|
DEFAULT_ENDPOINT = "compute.googleapis.com"
|
871
898
|
|
872
|
-
config_attr :endpoint,
|
899
|
+
config_attr :endpoint, nil, ::String, nil
|
873
900
|
config_attr :credentials, nil do |value|
|
874
901
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
875
902
|
allowed.any? { |klass| klass === value }
|
@@ -881,6 +908,7 @@ module Google
|
|
881
908
|
config_attr :metadata, nil, ::Hash, nil
|
882
909
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
883
910
|
config_attr :quota_project, nil, ::String, nil
|
911
|
+
config_attr :universe_domain, nil, ::String, nil
|
884
912
|
|
885
913
|
# @private
|
886
914
|
def initialize parent_config = nil
|
@@ -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: false,
|
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 aggregated_list REST call
|
45
57
|
#
|