google-cloud-cloud_quotas-v1beta 0.4.0 → 0.5.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/lib/google/api/cloudquotas/v1beta/quota_adjuster_settings_pb.rb +1 -1
- data/lib/google/cloud/cloud_quotas/v1beta/quota_adjuster_settings_manager/paths.rb +42 -7
- data/lib/google/cloud/cloud_quotas/v1beta/quota_adjuster_settings_manager/rest/service_stub.rb +30 -0
- data/lib/google/cloud/cloud_quotas/v1beta/version.rb +1 -1
- data/proto_docs/google/api/cloudquotas/v1beta/quota_adjuster_settings.rb +17 -4
- data/proto_docs/google/api/cloudquotas/v1beta/resources.rb +27 -25
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 81dd471b0ab3d34cebb4bd64c240568fd71bce344874530dbaffee5c47e34387
|
4
|
+
data.tar.gz: 0f5c395519d808771a202becb5d7f9ed2fba3fcb4e76843ad731cdbe8b3eaea5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9afd012de25e00d55454e89e9ecbf51b58eca1ed1449c6c6e51d869639993e1dcbd891787aba7ae62ae5a2a77d8dc6fa8bfb5b8f4e0038984d45e47a72f7a40a
|
7
|
+
data.tar.gz: da8aac61e31e81b2f5f4f279e57e92ba22dbdc8dc7e4a6fee275e826ad81b7918fd8e280d36afdbe6ec7dc37626eb734ce0322504b70e29c5ce8f3d685031460
|
@@ -12,7 +12,7 @@ require 'google/protobuf/field_mask_pb'
|
|
12
12
|
require 'google/protobuf/timestamp_pb'
|
13
13
|
|
14
14
|
|
15
|
-
descriptor_data = "\n;google/api/cloudquotas/v1beta/quota_adjuster_settings.proto\x12\x1dgoogle.api.cloudquotas.v1beta\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"i\n\x1fGetQuotaAdjusterSettingsRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0cloudquotas.googleapis.com/QuotaAdjusterSettings\"\xd2\x01\n\"UpdateQuotaAdjusterSettingsRequest\x12Z\n\x17quota_adjuster_settings\x18\x01 \x01(\x0b\x32\x34.google.api.cloudquotas.v1beta.QuotaAdjusterSettingsB\x03\xe0\x41\x02\x12\x34\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x01\x12\x1a\n\rvalidate_only\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\
|
15
|
+
descriptor_data = "\n;google/api/cloudquotas/v1beta/quota_adjuster_settings.proto\x12\x1dgoogle.api.cloudquotas.v1beta\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"i\n\x1fGetQuotaAdjusterSettingsRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0cloudquotas.googleapis.com/QuotaAdjusterSettings\"\xd2\x01\n\"UpdateQuotaAdjusterSettingsRequest\x12Z\n\x17quota_adjuster_settings\x18\x01 \x01(\x0b\x32\x34.google.api.cloudquotas.v1beta.QuotaAdjusterSettingsB\x03\xe0\x41\x02\x12\x34\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x01\x12\x1a\n\rvalidate_only\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\xf6\x04\n\x15QuotaAdjusterSettings\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12X\n\nenablement\x18\x02 \x01(\x0e\x32?.google.api.cloudquotas.v1beta.QuotaAdjusterSettings.EnablementB\x03\xe0\x41\x01\x12\x34\n\x0bupdate_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x11\n\x04\x65tag\x18\x06 \x01(\tB\x03\xe0\x41\x01\x12\x16\n\tinherited\x18\x07 \x01(\x08\x42\x03\xe0\x41\x01\x12\x1b\n\x0einherited_from\x18\x08 \x01(\tB\x03\xe0\x41\x03\"C\n\nEnablement\x12\x1a\n\x16\x45NABLEMENT_UNSPECIFIED\x10\x00\x12\x0b\n\x07\x45NABLED\x10\x02\x12\x0c\n\x08\x44ISABLED\x10\x03:\xac\x02\xea\x41\xa8\x02\n0cloudquotas.googleapis.com/QuotaAdjusterSettings\x12=projects/{project}/locations/{location}/quotaAdjusterSettings\x12Gorganizations/{organization}/locations/{location}/quotaAdjusterSettings\x12;folders/{folder}/locations/{location}/quotaAdjusterSettings*\x15quotaAdjusterSettings2\x15quotaAdjusterSettingsR\x01\x01\x32\xec\x07\n\x1cQuotaAdjusterSettingsManager\x12\x98\x04\n\x1bUpdateQuotaAdjusterSettings\x12\x41.google.api.cloudquotas.v1beta.UpdateQuotaAdjusterSettingsRequest\x1a\x34.google.api.cloudquotas.v1beta.QuotaAdjusterSettings\"\xff\x02\xda\x41#quota_adjuster_settings,update_mask\x82\xd3\xe4\x93\x02\xd2\x02\x32S/v1beta/{quota_adjuster_settings.name=projects/*/locations/*/quotaAdjusterSettings}:\x17quota_adjuster_settingsZm2R/v1beta/{quota_adjuster_settings.name=folders/*/locations/*/quotaAdjusterSettings}:\x17quota_adjuster_settingsZs2X/v1beta/{quota_adjuster_settings.name=organizations/*/locations/*/quotaAdjusterSettings}:\x17quota_adjuster_settings\x12\xe0\x02\n\x18GetQuotaAdjusterSettings\x12>.google.api.cloudquotas.v1beta.GetQuotaAdjusterSettingsRequest\x1a\x34.google.api.cloudquotas.v1beta.QuotaAdjusterSettings\"\xcd\x01\xda\x41\x04name\x82\xd3\xe4\x93\x02\xbf\x01\x12;/v1beta/{name=projects/*/locations/*/quotaAdjusterSettings}Z<\x12:/v1beta/{name=folders/*/locations/*/quotaAdjusterSettings}ZB\x12@/v1beta/{name=organizations/*/locations/*/quotaAdjusterSettings}\x1aN\xca\x41\x1a\x63loudquotas.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\xf1\x01\n!com.google.api.cloudquotas.v1betaB\x1aQuotaAdjusterSettingsProtoP\x01ZEcloud.google.com/go/cloudquotas/apiv1beta/cloudquotaspb;cloudquotaspb\xaa\x02\x1fGoogle.Cloud.CloudQuotas.V1Beta\xca\x02\x1fGoogle\\Cloud\\CloudQuotas\\V1beta\xea\x02\"Google::Cloud::CloudQuotas::V1betab\x06proto3"
|
16
16
|
|
17
17
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
18
18
|
|
@@ -27,18 +27,53 @@ module Google
|
|
27
27
|
##
|
28
28
|
# Create a fully-qualified QuotaAdjusterSettings resource string.
|
29
29
|
#
|
30
|
-
#
|
30
|
+
# @overload quota_adjuster_settings_path(project:, location:)
|
31
|
+
# The resource will be in the following format:
|
31
32
|
#
|
32
|
-
#
|
33
|
+
# `projects/{project}/locations/{location}/quotaAdjusterSettings`
|
33
34
|
#
|
34
|
-
#
|
35
|
-
#
|
35
|
+
# @param project [String]
|
36
|
+
# @param location [String]
|
37
|
+
#
|
38
|
+
# @overload quota_adjuster_settings_path(organization:, location:)
|
39
|
+
# The resource will be in the following format:
|
40
|
+
#
|
41
|
+
# `organizations/{organization}/locations/{location}/quotaAdjusterSettings`
|
42
|
+
#
|
43
|
+
# @param organization [String]
|
44
|
+
# @param location [String]
|
45
|
+
#
|
46
|
+
# @overload quota_adjuster_settings_path(folder:, location:)
|
47
|
+
# The resource will be in the following format:
|
48
|
+
#
|
49
|
+
# `folders/{folder}/locations/{location}/quotaAdjusterSettings`
|
50
|
+
#
|
51
|
+
# @param folder [String]
|
52
|
+
# @param location [String]
|
36
53
|
#
|
37
54
|
# @return [::String]
|
38
|
-
def quota_adjuster_settings_path
|
39
|
-
|
55
|
+
def quota_adjuster_settings_path **args
|
56
|
+
resources = {
|
57
|
+
"location:project" => (proc do |project:, location:|
|
58
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
59
|
+
|
60
|
+
"projects/#{project}/locations/#{location}/quotaAdjusterSettings"
|
61
|
+
end),
|
62
|
+
"location:organization" => (proc do |organization:, location:|
|
63
|
+
raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
|
64
|
+
|
65
|
+
"organizations/#{organization}/locations/#{location}/quotaAdjusterSettings"
|
66
|
+
end),
|
67
|
+
"folder:location" => (proc do |folder:, location:|
|
68
|
+
raise ::ArgumentError, "folder cannot contain /" if folder.to_s.include? "/"
|
69
|
+
|
70
|
+
"folders/#{folder}/locations/#{location}/quotaAdjusterSettings"
|
71
|
+
end)
|
72
|
+
}
|
40
73
|
|
41
|
-
"
|
74
|
+
resource = resources[args.keys.sort.join(":")]
|
75
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
76
|
+
resource.call(**args)
|
42
77
|
end
|
43
78
|
|
44
79
|
extend self
|
data/lib/google/cloud/cloud_quotas/v1beta/quota_adjuster_settings_manager/rest/service_stub.rb
CHANGED
@@ -172,6 +172,22 @@ module Google
|
|
172
172
|
["quota_adjuster_settings.name", %r{^projects/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
173
173
|
]
|
174
174
|
)
|
175
|
+
.with_bindings(
|
176
|
+
uri_method: :patch,
|
177
|
+
uri_template: "/v1beta/{quota_adjuster_settings.name}",
|
178
|
+
body: "quota_adjuster_settings",
|
179
|
+
matches: [
|
180
|
+
["quota_adjuster_settings.name", %r{^folders/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
181
|
+
]
|
182
|
+
)
|
183
|
+
.with_bindings(
|
184
|
+
uri_method: :patch,
|
185
|
+
uri_template: "/v1beta/{quota_adjuster_settings.name}",
|
186
|
+
body: "quota_adjuster_settings",
|
187
|
+
matches: [
|
188
|
+
["quota_adjuster_settings.name", %r{^organizations/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
189
|
+
]
|
190
|
+
)
|
175
191
|
transcoder.transcode request_pb
|
176
192
|
end
|
177
193
|
|
@@ -193,6 +209,20 @@ module Google
|
|
193
209
|
["name", %r{^projects/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
194
210
|
]
|
195
211
|
)
|
212
|
+
.with_bindings(
|
213
|
+
uri_method: :get,
|
214
|
+
uri_template: "/v1beta/{name}",
|
215
|
+
matches: [
|
216
|
+
["name", %r{^folders/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
217
|
+
]
|
218
|
+
)
|
219
|
+
.with_bindings(
|
220
|
+
uri_method: :get,
|
221
|
+
uri_template: "/v1beta/{name}",
|
222
|
+
matches: [
|
223
|
+
["name", %r{^organizations/[^/]+/locations/[^/]+/quotaAdjusterSettings/?$}, false]
|
224
|
+
]
|
225
|
+
)
|
196
226
|
transcoder.transcode request_pb
|
197
227
|
end
|
198
228
|
end
|
@@ -52,12 +52,13 @@ module Google
|
|
52
52
|
# Adjuster.
|
53
53
|
# @!attribute [rw] name
|
54
54
|
# @return [::String]
|
55
|
-
# Identifier. Name of the
|
56
|
-
#
|
57
|
-
#
|
55
|
+
# Identifier. Name of the config would be of the format:
|
56
|
+
# projects/PROJECT_NUMBER/locations/global/quotaAdjusterSettings
|
57
|
+
# folders/FOLDER_NUMBER/locations/global/quotaAdjusterSettings
|
58
|
+
# organizations/ORGANIZATION_NUMBER/locations/global/quotaAdjusterSettings
|
58
59
|
# @!attribute [rw] enablement
|
59
60
|
# @return [::Google::Cloud::CloudQuotas::V1beta::QuotaAdjusterSettings::Enablement]
|
60
|
-
#
|
61
|
+
# Optional. The configured value of the enablement at the given resource.
|
61
62
|
# @!attribute [r] update_time
|
62
63
|
# @return [::Google::Protobuf::Timestamp]
|
63
64
|
# Output only. The timestamp when the QuotaAdjusterSettings resource was last
|
@@ -68,6 +69,18 @@ module Google
|
|
68
69
|
# provided on update and does not match the current server's ETag in the
|
69
70
|
# QuotaAdjusterSettings, the request is blocked and returns an ABORTED error.
|
70
71
|
# See https://google.aip.dev/134#etags for more details on ETags.
|
72
|
+
# @!attribute [rw] inherited
|
73
|
+
# @return [::Boolean]
|
74
|
+
# Optional. Indicates whether the setting is inherited or explicitly
|
75
|
+
# specified.
|
76
|
+
# @!attribute [r] inherited_from
|
77
|
+
# @return [::String]
|
78
|
+
# Output only. The resource container from which the setting is inherited.
|
79
|
+
# This refers to the nearest ancestor with enablement set (either ENABLED or
|
80
|
+
# DISABLED). The value can be an organizations/\\{organization_id},
|
81
|
+
# folders/\\{folder_id}, or can be 'default' if no ancestor exists with
|
82
|
+
# enablement set. The value will be empty when enablement is directly set on
|
83
|
+
# this container.
|
71
84
|
class QuotaAdjusterSettings
|
72
85
|
include ::Google::Protobuf::MessageExts
|
73
86
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -27,21 +27,21 @@ module Google
|
|
27
27
|
# @return [::String]
|
28
28
|
# Resource name of this QuotaInfo.
|
29
29
|
# The ID component following "locations/" must be "global".
|
30
|
-
#
|
30
|
+
# For example,
|
31
31
|
# `projects/123/locations/global/services/compute.googleapis.com/quotaInfos/CpusPerProjectPerRegion`
|
32
32
|
# @!attribute [rw] quota_id
|
33
33
|
# @return [::String]
|
34
34
|
# The id of the quota, which is unquie within the service.
|
35
|
-
#
|
35
|
+
# For example, `CpusPerProjectPerRegion`
|
36
36
|
# @!attribute [rw] metric
|
37
37
|
# @return [::String]
|
38
38
|
# The metric of the quota. It specifies the resources consumption the quota
|
39
39
|
# is defined for.
|
40
|
-
#
|
40
|
+
# For example, `compute.googleapis.com/cpus`
|
41
41
|
# @!attribute [rw] service
|
42
42
|
# @return [::String]
|
43
43
|
# The name of the service in which the quota is defined.
|
44
|
-
#
|
44
|
+
# For example, `compute.googleapis.com`
|
45
45
|
# @!attribute [rw] is_precise
|
46
46
|
# @return [::Boolean]
|
47
47
|
# Whether this is a precise quota. A precise quota is tracked with absolute
|
@@ -50,8 +50,8 @@ module Google
|
|
50
50
|
# @return [::String]
|
51
51
|
# The reset time interval for the quota. Refresh interval applies to rate
|
52
52
|
# quota only.
|
53
|
-
#
|
54
|
-
# every 10 seconds.
|
53
|
+
# For example, "minute" for per minute, "day" for per day, or "10 seconds"
|
54
|
+
# for every 10 seconds.
|
55
55
|
# @!attribute [rw] container_type
|
56
56
|
# @return [::Google::Cloud::CloudQuotas::V1beta::QuotaInfo::ContainerType]
|
57
57
|
# The container type of the QuotaInfo.
|
@@ -146,25 +146,26 @@ module Google
|
|
146
146
|
# @return [::String]
|
147
147
|
# Required except in the CREATE requests.
|
148
148
|
# The resource name of the quota preference.
|
149
|
-
# The
|
150
|
-
#
|
149
|
+
# The path that follows `/locations` must be `/global`.
|
150
|
+
# For example:
|
151
151
|
# `projects/123/locations/global/quotaPreferences/my-config-for-us-east1`
|
152
152
|
# @!attribute [rw] dimensions
|
153
153
|
# @return [::Google::Protobuf::Map{::String => ::String}]
|
154
154
|
# Immutable. The dimensions that this quota preference applies to. The key of
|
155
|
-
# the map entry is the name of a dimension, such as
|
156
|
-
#
|
155
|
+
# the map entry is the name of a dimension, such as `region`, `zone`,
|
156
|
+
# `network_id`, and the value of the map entry is the dimension value.
|
157
157
|
#
|
158
158
|
# If a dimension is missing from the map of dimensions, the quota preference
|
159
159
|
# applies to all the dimension values except for those that have other quota
|
160
160
|
# preferences configured for the specific value.
|
161
161
|
#
|
162
|
-
#
|
163
|
-
#
|
162
|
+
# Note: QuotaPreferences can only be applied across all values of `user` and
|
163
|
+
# `resource` dimension. Do not set values for `user` or `resource` in the
|
164
164
|
# dimension map.
|
165
165
|
#
|
166
|
-
#
|
167
|
-
# dimension
|
166
|
+
# For example: `{"provider" : "Example Organization"}` where `provider` is a
|
167
|
+
# service-specific quota dimension and `Example Organization` is the provider
|
168
|
+
# name.
|
168
169
|
# @!attribute [rw] quota_config
|
169
170
|
# @return [::Google::Cloud::CloudQuotas::V1beta::QuotaConfig]
|
170
171
|
# Required. Preferred quota configuration.
|
@@ -186,7 +187,7 @@ module Google
|
|
186
187
|
# @!attribute [rw] quota_id
|
187
188
|
# @return [::String]
|
188
189
|
# Required. The id of the quota to which the quota preference is applied. A
|
189
|
-
# quota name is unique in the service.
|
190
|
+
# quota name is unique in the service. For example, `CpusPerProjectPerRegion`
|
190
191
|
# @!attribute [r] reconciling
|
191
192
|
# @return [::Boolean]
|
192
193
|
# Output only. Is the quota preference pending Google Cloud approval and
|
@@ -196,9 +197,9 @@ module Google
|
|
196
197
|
# The reason / justification for this quota preference.
|
197
198
|
# @!attribute [rw] contact_email
|
198
199
|
# @return [::String]
|
199
|
-
# Input only. An email address that can be used to contact the
|
200
|
-
#
|
201
|
-
#
|
200
|
+
# Input only. An email address that can be used to contact the user, in case
|
201
|
+
# Google Cloud needs more information to make a decision before additional
|
202
|
+
# quota can be granted.
|
202
203
|
#
|
203
204
|
# When requesting a quota increase, the email address is required.
|
204
205
|
# When requesting a quota decrease, the email address is optional.
|
@@ -275,20 +276,21 @@ module Google
|
|
275
276
|
# combination of dimensions.
|
276
277
|
# @!attribute [rw] dimensions
|
277
278
|
# @return [::Google::Protobuf::Map{::String => ::String}]
|
278
|
-
# The map of dimensions
|
279
|
-
# is "region", "zone" or the name of a service
|
280
|
-
# value of a map entry is the value of the dimension.
|
279
|
+
# The map of dimensions in key-value pairs. The key of a map entry
|
280
|
+
# is "region", "zone", or the name of a service-specific dimension, and the
|
281
|
+
# value of a map entry is the value of the dimension. If a dimension does
|
281
282
|
# not appear in the map of dimensions, the dimensions info applies to all
|
282
|
-
# the dimension values except for those that have another
|
283
|
+
# the dimension values except for those that have another DimensionInfo
|
283
284
|
# instance configured for the specific value.
|
284
|
-
#
|
285
|
-
# dimension
|
285
|
+
# For example: `{"provider" : "Example Organization"}` where `provider` is a
|
286
|
+
# service-specific quota dimension and `Example Organization` is the provider
|
287
|
+
# name.
|
286
288
|
# @!attribute [rw] details
|
287
289
|
# @return [::Google::Cloud::CloudQuotas::V1beta::QuotaDetails]
|
288
290
|
# Quota details for the specified dimensions.
|
289
291
|
# @!attribute [rw] applicable_locations
|
290
292
|
# @return [::Array<::String>]
|
291
|
-
# The applicable regions or zones of this
|
293
|
+
# The applicable regions or zones of this dimension. The field is
|
292
294
|
# set to ['global'] for quotas that are not per region or per zone.
|
293
295
|
# Otherwise, it will be set to the list of locations this dimension info is
|
294
296
|
# applicable to.
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-cloud_quotas-v1beta
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
@@ -104,7 +104,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
104
104
|
- !ruby/object:Gem::Version
|
105
105
|
version: '0'
|
106
106
|
requirements: []
|
107
|
-
rubygems_version: 3.6.
|
107
|
+
rubygems_version: 3.6.9
|
108
108
|
specification_version: 4
|
109
109
|
summary: Cloud Quotas API provides Google Cloud service consumers with management
|
110
110
|
and observability for resource usage, quotas, and restrictions of the services they
|