google-cloud-service_usage-v1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (38) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +169 -0
  4. data/LICENSE.md +201 -0
  5. data/README.md +139 -0
  6. data/lib/google-cloud-service_usage-v1.rb +21 -0
  7. data/lib/google/api/serviceusage/v1/resources_pb.rb +57 -0
  8. data/lib/google/api/serviceusage/v1/serviceusage_pb.rb +86 -0
  9. data/lib/google/api/serviceusage/v1/serviceusage_services_pb.rb +80 -0
  10. data/lib/google/cloud/service_usage/v1.rb +38 -0
  11. data/lib/google/cloud/service_usage/v1/service_usage.rb +53 -0
  12. data/lib/google/cloud/service_usage/v1/service_usage/client.rb +850 -0
  13. data/lib/google/cloud/service_usage/v1/service_usage/credentials.rb +53 -0
  14. data/lib/google/cloud/service_usage/v1/service_usage/operations.rb +655 -0
  15. data/lib/google/cloud/service_usage/v1/version.rb +28 -0
  16. data/proto_docs/README.md +4 -0
  17. data/proto_docs/google/api/auth.rb +247 -0
  18. data/proto_docs/google/api/documentation.rb +170 -0
  19. data/proto_docs/google/api/endpoint.rb +70 -0
  20. data/proto_docs/google/api/label.rb +49 -0
  21. data/proto_docs/google/api/launch_stage.rb +71 -0
  22. data/proto_docs/google/api/monitored_resource.rb +138 -0
  23. data/proto_docs/google/api/monitoring.rb +110 -0
  24. data/proto_docs/google/api/quota.rb +207 -0
  25. data/proto_docs/google/api/resource.rb +283 -0
  26. data/proto_docs/google/api/serviceusage/v1/resources.rb +122 -0
  27. data/proto_docs/google/api/serviceusage/v1/serviceusage.rb +242 -0
  28. data/proto_docs/google/api/usage.rb +100 -0
  29. data/proto_docs/google/longrunning/operations.rb +164 -0
  30. data/proto_docs/google/protobuf/any.rb +141 -0
  31. data/proto_docs/google/protobuf/api.rb +194 -0
  32. data/proto_docs/google/protobuf/duration.rb +98 -0
  33. data/proto_docs/google/protobuf/empty.rb +36 -0
  34. data/proto_docs/google/protobuf/source_context.rb +33 -0
  35. data/proto_docs/google/protobuf/struct.rb +96 -0
  36. data/proto_docs/google/protobuf/type.rb +223 -0
  37. data/proto_docs/google/rpc/status.rb +46 -0
  38. metadata +229 -0
@@ -0,0 +1,70 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # `Endpoint` describes a network endpoint of a service that serves a set of
23
+ # APIs. It is commonly known as a service endpoint. A service may expose
24
+ # any number of service endpoints, and all service endpoints share the same
25
+ # service definition, such as quota limits and monitoring metrics.
26
+ #
27
+ # Example service configuration:
28
+ #
29
+ # name: library-example.googleapis.com
30
+ # endpoints:
31
+ # # Below entry makes 'google.example.library.v1.Library'
32
+ # # API be served from endpoint address library-example.googleapis.com.
33
+ # # It also allows HTTP OPTIONS calls to be passed to the backend, for
34
+ # # it to decide whether the subsequent cross-origin request is
35
+ # # allowed to proceed.
36
+ # - name: library-example.googleapis.com
37
+ # allow_cors: true
38
+ # @!attribute [rw] name
39
+ # @return [::String]
40
+ # The canonical name of this endpoint.
41
+ # @!attribute [rw] aliases
42
+ # @return [::Array<::String>]
43
+ # Unimplemented. Dot not use.
44
+ #
45
+ # DEPRECATED: This field is no longer supported. Instead of using aliases,
46
+ # please specify multiple {::Google::Api::Endpoint google.api.Endpoint} for each of the intended
47
+ # aliases.
48
+ #
49
+ # Additional names that this endpoint will be hosted on.
50
+ # @!attribute [rw] target
51
+ # @return [::String]
52
+ # The specification of an Internet routable address of API frontend that will
53
+ # handle requests to this [API
54
+ # Endpoint](https://cloud.google.com/apis/design/glossary). It should be
55
+ # either a valid IPv4 address or a fully-qualified domain name. For example,
56
+ # "8.8.8.8" or "myservice.appspot.com".
57
+ # @!attribute [rw] allow_cors
58
+ # @return [::Boolean]
59
+ # Allowing
60
+ # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
61
+ # cross-domain traffic, would allow the backends served from this endpoint to
62
+ # receive and respond to HTTP OPTIONS requests. The response will be used by
63
+ # the browser to determine whether the subsequent cross-origin request is
64
+ # allowed to proceed.
65
+ class Endpoint
66
+ include ::Google::Protobuf::MessageExts
67
+ extend ::Google::Protobuf::MessageExts::ClassMethods
68
+ end
69
+ end
70
+ end
@@ -0,0 +1,49 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # A description of a label.
23
+ # @!attribute [rw] key
24
+ # @return [::String]
25
+ # The label key.
26
+ # @!attribute [rw] value_type
27
+ # @return [::Google::Api::LabelDescriptor::ValueType]
28
+ # The type of data that can be assigned to the label.
29
+ # @!attribute [rw] description
30
+ # @return [::String]
31
+ # A human-readable description for the label.
32
+ class LabelDescriptor
33
+ include ::Google::Protobuf::MessageExts
34
+ extend ::Google::Protobuf::MessageExts::ClassMethods
35
+
36
+ # Value types that can be used as label values.
37
+ module ValueType
38
+ # A variable-length string. This is the default.
39
+ STRING = 0
40
+
41
+ # Boolean; true or false.
42
+ BOOL = 1
43
+
44
+ # A 64-bit signed integer.
45
+ INT64 = 2
46
+ end
47
+ end
48
+ end
49
+ end
@@ -0,0 +1,71 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # The launch stage as defined by [Google Cloud Platform
23
+ # Launch Stages](http://cloud.google.com/terms/launch-stages).
24
+ module LaunchStage
25
+ # Do not use this default value.
26
+ LAUNCH_STAGE_UNSPECIFIED = 0
27
+
28
+ # The feature is not yet implemented. Users can not use it.
29
+ UNIMPLEMENTED = 6
30
+
31
+ # Prelaunch features are hidden from users and are only visible internally.
32
+ PRELAUNCH = 7
33
+
34
+ # Early Access features are limited to a closed group of testers. To use
35
+ # these features, you must sign up in advance and sign a Trusted Tester
36
+ # agreement (which includes confidentiality provisions). These features may
37
+ # be unstable, changed in backward-incompatible ways, and are not
38
+ # guaranteed to be released.
39
+ EARLY_ACCESS = 1
40
+
41
+ # Alpha is a limited availability test for releases before they are cleared
42
+ # for widespread use. By Alpha, all significant design issues are resolved
43
+ # and we are in the process of verifying functionality. Alpha customers
44
+ # need to apply for access, agree to applicable terms, and have their
45
+ # projects allowlisted. Alpha releases don’t have to be feature complete,
46
+ # no SLAs are provided, and there are no technical support obligations, but
47
+ # they will be far enough along that customers can actually use them in
48
+ # test environments or for limited-use tests -- just like they would in
49
+ # normal production cases.
50
+ ALPHA = 2
51
+
52
+ # Beta is the point at which we are ready to open a release for any
53
+ # customer to use. There are no SLA or technical support obligations in a
54
+ # Beta release. Products will be complete from a feature perspective, but
55
+ # may have some open outstanding issues. Beta releases are suitable for
56
+ # limited production use cases.
57
+ BETA = 3
58
+
59
+ # GA features are open to all developers and are considered stable and
60
+ # fully qualified for production use.
61
+ GA = 4
62
+
63
+ # Deprecated features are scheduled to be shut down and removed. For more
64
+ # information, see the “Deprecation Policy” section of our [Terms of
65
+ # Service](https://cloud.google.com/terms/)
66
+ # and the [Google Cloud Platform Subject to the Deprecation
67
+ # Policy](https://cloud.google.com/terms/deprecation) documentation.
68
+ DEPRECATED = 5
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,138 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # An object that describes the schema of a {::Google::Api::MonitoredResource MonitoredResource} object using a
23
+ # type name and a set of labels. For example, the monitored resource
24
+ # descriptor for Google Compute Engine VM instances has a type of
25
+ # `"gce_instance"` and specifies the use of the labels `"instance_id"` and
26
+ # `"zone"` to identify particular VM instances.
27
+ #
28
+ # Different APIs can support different monitored resource types. APIs generally
29
+ # provide a `list` method that returns the monitored resource descriptors used
30
+ # by the API.
31
+ # @!attribute [rw] name
32
+ # @return [::String]
33
+ # Optional. The resource name of the monitored resource descriptor:
34
+ # `"projects/{project_id}/monitoredResourceDescriptors/{type}"` where
35
+ # \\{type} is the value of the `type` field in this object and
36
+ # \\{project_id} is a project ID that provides API-specific context for
37
+ # accessing the type. APIs that do not use project information can use the
38
+ # resource name format `"monitoredResourceDescriptors/{type}"`.
39
+ # @!attribute [rw] type
40
+ # @return [::String]
41
+ # Required. The monitored resource type. For example, the type
42
+ # `"cloudsql_database"` represents databases in Google Cloud SQL.
43
+ # @!attribute [rw] display_name
44
+ # @return [::String]
45
+ # Optional. A concise name for the monitored resource type that might be
46
+ # displayed in user interfaces. It should be a Title Cased Noun Phrase,
47
+ # without any article or other determiners. For example,
48
+ # `"Google Cloud SQL Database"`.
49
+ # @!attribute [rw] description
50
+ # @return [::String]
51
+ # Optional. A detailed description of the monitored resource type that might
52
+ # be used in documentation.
53
+ # @!attribute [rw] labels
54
+ # @return [::Array<::Google::Api::LabelDescriptor>]
55
+ # Required. A set of labels used to describe instances of this monitored
56
+ # resource type. For example, an individual Google Cloud SQL database is
57
+ # identified by values for the labels `"database_id"` and `"zone"`.
58
+ # @!attribute [rw] launch_stage
59
+ # @return [::Google::Api::LaunchStage]
60
+ # Optional. The launch stage of the monitored resource definition.
61
+ class MonitoredResourceDescriptor
62
+ include ::Google::Protobuf::MessageExts
63
+ extend ::Google::Protobuf::MessageExts::ClassMethods
64
+ end
65
+
66
+ # An object representing a resource that can be used for monitoring, logging,
67
+ # billing, or other purposes. Examples include virtual machine instances,
68
+ # databases, and storage devices such as disks. The `type` field identifies a
69
+ # {::Google::Api::MonitoredResourceDescriptor MonitoredResourceDescriptor} object that describes the resource's
70
+ # schema. Information in the `labels` field identifies the actual resource and
71
+ # its attributes according to the schema. For example, a particular Compute
72
+ # Engine VM instance could be represented by the following object, because the
73
+ # {::Google::Api::MonitoredResourceDescriptor MonitoredResourceDescriptor} for `"gce_instance"` has labels
74
+ # `"instance_id"` and `"zone"`:
75
+ #
76
+ # { "type": "gce_instance",
77
+ # "labels": { "instance_id": "12345678901234",
78
+ # "zone": "us-central1-a" }}
79
+ # @!attribute [rw] type
80
+ # @return [::String]
81
+ # Required. The monitored resource type. This field must match
82
+ # the `type` field of a {::Google::Api::MonitoredResourceDescriptor MonitoredResourceDescriptor} object. For
83
+ # example, the type of a Compute Engine VM instance is `gce_instance`.
84
+ # @!attribute [rw] labels
85
+ # @return [::Google::Protobuf::Map{::String => ::String}]
86
+ # Required. Values for all of the labels listed in the associated monitored
87
+ # resource descriptor. For example, Compute Engine VM instances use the
88
+ # labels `"project_id"`, `"instance_id"`, and `"zone"`.
89
+ class MonitoredResource
90
+ include ::Google::Protobuf::MessageExts
91
+ extend ::Google::Protobuf::MessageExts::ClassMethods
92
+
93
+ # @!attribute [rw] key
94
+ # @return [::String]
95
+ # @!attribute [rw] value
96
+ # @return [::String]
97
+ class LabelsEntry
98
+ include ::Google::Protobuf::MessageExts
99
+ extend ::Google::Protobuf::MessageExts::ClassMethods
100
+ end
101
+ end
102
+
103
+ # Auxiliary metadata for a {::Google::Api::MonitoredResource MonitoredResource} object.
104
+ # {::Google::Api::MonitoredResource MonitoredResource} objects contain the minimum set of information to
105
+ # uniquely identify a monitored resource instance. There is some other useful
106
+ # auxiliary metadata. Monitoring and Logging use an ingestion
107
+ # pipeline to extract metadata for cloud resources of all types, and store
108
+ # the metadata in this message.
109
+ # @!attribute [rw] system_labels
110
+ # @return [::Google::Protobuf::Struct]
111
+ # Output only. Values for predefined system metadata labels.
112
+ # System labels are a kind of metadata extracted by Google, including
113
+ # "machine_image", "vpc", "subnet_id",
114
+ # "security_group", "name", etc.
115
+ # System label values can be only strings, Boolean values, or a list of
116
+ # strings. For example:
117
+ #
118
+ # { "name": "my-test-instance",
119
+ # "security_group": ["a", "b", "c"],
120
+ # "spot_instance": false }
121
+ # @!attribute [rw] user_labels
122
+ # @return [::Google::Protobuf::Map{::String => ::String}]
123
+ # Output only. A map of user-defined metadata labels.
124
+ class MonitoredResourceMetadata
125
+ include ::Google::Protobuf::MessageExts
126
+ extend ::Google::Protobuf::MessageExts::ClassMethods
127
+
128
+ # @!attribute [rw] key
129
+ # @return [::String]
130
+ # @!attribute [rw] value
131
+ # @return [::String]
132
+ class UserLabelsEntry
133
+ include ::Google::Protobuf::MessageExts
134
+ extend ::Google::Protobuf::MessageExts::ClassMethods
135
+ end
136
+ end
137
+ end
138
+ end
@@ -0,0 +1,110 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # Monitoring configuration of the service.
23
+ #
24
+ # The example below shows how to configure monitored resources and metrics
25
+ # for monitoring. In the example, a monitored resource and two metrics are
26
+ # defined. The `library.googleapis.com/book/returned_count` metric is sent
27
+ # to both producer and consumer projects, whereas the
28
+ # `library.googleapis.com/book/num_overdue` metric is only sent to the
29
+ # consumer project.
30
+ #
31
+ # monitored_resources:
32
+ # - type: library.googleapis.com/Branch
33
+ # display_name: "Library Branch"
34
+ # description: "A branch of a library."
35
+ # launch_stage: GA
36
+ # labels:
37
+ # - key: resource_container
38
+ # description: "The Cloud container (ie. project id) for the Branch."
39
+ # - key: location
40
+ # description: "The location of the library branch."
41
+ # - key: branch_id
42
+ # description: "The id of the branch."
43
+ # metrics:
44
+ # - name: library.googleapis.com/book/returned_count
45
+ # display_name: "Books Returned"
46
+ # description: "The count of books that have been returned."
47
+ # launch_stage: GA
48
+ # metric_kind: DELTA
49
+ # value_type: INT64
50
+ # unit: "1"
51
+ # labels:
52
+ # - key: customer_id
53
+ # description: "The id of the customer."
54
+ # - name: library.googleapis.com/book/num_overdue
55
+ # display_name: "Books Overdue"
56
+ # description: "The current number of overdue books."
57
+ # launch_stage: GA
58
+ # metric_kind: GAUGE
59
+ # value_type: INT64
60
+ # unit: "1"
61
+ # labels:
62
+ # - key: customer_id
63
+ # description: "The id of the customer."
64
+ # monitoring:
65
+ # producer_destinations:
66
+ # - monitored_resource: library.googleapis.com/Branch
67
+ # metrics:
68
+ # - library.googleapis.com/book/returned_count
69
+ # consumer_destinations:
70
+ # - monitored_resource: library.googleapis.com/Branch
71
+ # metrics:
72
+ # - library.googleapis.com/book/returned_count
73
+ # - library.googleapis.com/book/num_overdue
74
+ # @!attribute [rw] producer_destinations
75
+ # @return [::Array<::Google::Api::Monitoring::MonitoringDestination>]
76
+ # Monitoring configurations for sending metrics to the producer project.
77
+ # There can be multiple producer destinations. A monitored resource type may
78
+ # appear in multiple monitoring destinations if different aggregations are
79
+ # needed for different sets of metrics associated with that monitored
80
+ # resource type. A monitored resource and metric pair may only be used once
81
+ # in the Monitoring configuration.
82
+ # @!attribute [rw] consumer_destinations
83
+ # @return [::Array<::Google::Api::Monitoring::MonitoringDestination>]
84
+ # Monitoring configurations for sending metrics to the consumer project.
85
+ # There can be multiple consumer destinations. A monitored resource type may
86
+ # appear in multiple monitoring destinations if different aggregations are
87
+ # needed for different sets of metrics associated with that monitored
88
+ # resource type. A monitored resource and metric pair may only be used once
89
+ # in the Monitoring configuration.
90
+ class Monitoring
91
+ include ::Google::Protobuf::MessageExts
92
+ extend ::Google::Protobuf::MessageExts::ClassMethods
93
+
94
+ # Configuration of a specific monitoring destination (the producer project
95
+ # or the consumer project).
96
+ # @!attribute [rw] monitored_resource
97
+ # @return [::String]
98
+ # The monitored resource type. The type must be defined in
99
+ # [Service.monitored_resources][google.api.Service.monitored_resources] section.
100
+ # @!attribute [rw] metrics
101
+ # @return [::Array<::String>]
102
+ # Types of the metrics to report to this monitoring destination.
103
+ # Each type must be defined in [Service.metrics][google.api.Service.metrics] section.
104
+ class MonitoringDestination
105
+ include ::Google::Protobuf::MessageExts
106
+ extend ::Google::Protobuf::MessageExts::ClassMethods
107
+ end
108
+ end
109
+ end
110
+ end
@@ -0,0 +1,207 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # Quota configuration helps to achieve fairness and budgeting in service
23
+ # usage.
24
+ #
25
+ # The metric based quota configuration works this way:
26
+ # - The service configuration defines a set of metrics.
27
+ # - For API calls, the quota.metric_rules maps methods to metrics with
28
+ # corresponding costs.
29
+ # - The quota.limits defines limits on the metrics, which will be used for
30
+ # quota checks at runtime.
31
+ #
32
+ # An example quota configuration in yaml format:
33
+ #
34
+ # quota:
35
+ # limits:
36
+ #
37
+ # - name: apiWriteQpsPerProject
38
+ # metric: library.googleapis.com/write_calls
39
+ # unit: "1/min/\\{project}" # rate limit for consumer projects
40
+ # values:
41
+ # STANDARD: 10000
42
+ #
43
+ #
44
+ # # The metric rules bind all methods to the read_calls metric,
45
+ # # except for the UpdateBook and DeleteBook methods. These two methods
46
+ # # are mapped to the write_calls metric, with the UpdateBook method
47
+ # # consuming at twice rate as the DeleteBook method.
48
+ # metric_rules:
49
+ # - selector: "*"
50
+ # metric_costs:
51
+ # library.googleapis.com/read_calls: 1
52
+ # - selector: google.example.library.v1.LibraryService.UpdateBook
53
+ # metric_costs:
54
+ # library.googleapis.com/write_calls: 2
55
+ # - selector: google.example.library.v1.LibraryService.DeleteBook
56
+ # metric_costs:
57
+ # library.googleapis.com/write_calls: 1
58
+ #
59
+ # Corresponding Metric definition:
60
+ #
61
+ # metrics:
62
+ # - name: library.googleapis.com/read_calls
63
+ # display_name: Read requests
64
+ # metric_kind: DELTA
65
+ # value_type: INT64
66
+ #
67
+ # - name: library.googleapis.com/write_calls
68
+ # display_name: Write requests
69
+ # metric_kind: DELTA
70
+ # value_type: INT64
71
+ # @!attribute [rw] limits
72
+ # @return [::Array<::Google::Api::QuotaLimit>]
73
+ # List of `QuotaLimit` definitions for the service.
74
+ # @!attribute [rw] metric_rules
75
+ # @return [::Array<::Google::Api::MetricRule>]
76
+ # List of `MetricRule` definitions, each one mapping a selected method to one
77
+ # or more metrics.
78
+ class Quota
79
+ include ::Google::Protobuf::MessageExts
80
+ extend ::Google::Protobuf::MessageExts::ClassMethods
81
+ end
82
+
83
+ # Bind API methods to metrics. Binding a method to a metric causes that
84
+ # metric's configured quota behaviors to apply to the method call.
85
+ # @!attribute [rw] selector
86
+ # @return [::String]
87
+ # Selects the methods to which this rule applies.
88
+ #
89
+ # Refer to {::Google::Api::DocumentationRule#selector selector} for syntax details.
90
+ # @!attribute [rw] metric_costs
91
+ # @return [::Google::Protobuf::Map{::String => ::Integer}]
92
+ # Metrics to update when the selected methods are called, and the associated
93
+ # cost applied to each metric.
94
+ #
95
+ # The key of the map is the metric name, and the values are the amount
96
+ # increased for the metric against which the quota limits are defined.
97
+ # The value must not be negative.
98
+ class MetricRule
99
+ include ::Google::Protobuf::MessageExts
100
+ extend ::Google::Protobuf::MessageExts::ClassMethods
101
+
102
+ # @!attribute [rw] key
103
+ # @return [::String]
104
+ # @!attribute [rw] value
105
+ # @return [::Integer]
106
+ class MetricCostsEntry
107
+ include ::Google::Protobuf::MessageExts
108
+ extend ::Google::Protobuf::MessageExts::ClassMethods
109
+ end
110
+ end
111
+
112
+ # `QuotaLimit` defines a specific limit that applies over a specified duration
113
+ # for a limit type. There can be at most one limit for a duration and limit
114
+ # type combination defined within a `QuotaGroup`.
115
+ # @!attribute [rw] name
116
+ # @return [::String]
117
+ # Name of the quota limit.
118
+ #
119
+ # The name must be provided, and it must be unique within the service. The
120
+ # name can only include alphanumeric characters as well as '-'.
121
+ #
122
+ # The maximum length of the limit name is 64 characters.
123
+ # @!attribute [rw] description
124
+ # @return [::String]
125
+ # Optional. User-visible, extended description for this quota limit.
126
+ # Should be used only when more context is needed to understand this limit
127
+ # than provided by the limit's display name (see: `display_name`).
128
+ # @!attribute [rw] default_limit
129
+ # @return [::Integer]
130
+ # Default number of tokens that can be consumed during the specified
131
+ # duration. This is the number of tokens assigned when a client
132
+ # application developer activates the service for his/her project.
133
+ #
134
+ # Specifying a value of 0 will block all requests. This can be used if you
135
+ # are provisioning quota to selected consumers and blocking others.
136
+ # Similarly, a value of -1 will indicate an unlimited quota. No other
137
+ # negative values are allowed.
138
+ #
139
+ # Used by group-based quotas only.
140
+ # @!attribute [rw] max_limit
141
+ # @return [::Integer]
142
+ # Maximum number of tokens that can be consumed during the specified
143
+ # duration. Client application developers can override the default limit up
144
+ # to this maximum. If specified, this value cannot be set to a value less
145
+ # than the default limit. If not specified, it is set to the default limit.
146
+ #
147
+ # To allow clients to apply overrides with no upper bound, set this to -1,
148
+ # indicating unlimited maximum quota.
149
+ #
150
+ # Used by group-based quotas only.
151
+ # @!attribute [rw] free_tier
152
+ # @return [::Integer]
153
+ # Free tier value displayed in the Developers Console for this limit.
154
+ # The free tier is the number of tokens that will be subtracted from the
155
+ # billed amount when billing is enabled.
156
+ # This field can only be set on a limit with duration "1d", in a billable
157
+ # group; it is invalid on any other limit. If this field is not set, it
158
+ # defaults to 0, indicating that there is no free tier for this service.
159
+ #
160
+ # Used by group-based quotas only.
161
+ # @!attribute [rw] duration
162
+ # @return [::String]
163
+ # Duration of this limit in textual notation. Must be "100s" or "1d".
164
+ #
165
+ # Used by group-based quotas only.
166
+ # @!attribute [rw] metric
167
+ # @return [::String]
168
+ # The name of the metric this quota limit applies to. The quota limits with
169
+ # the same metric will be checked together during runtime. The metric must be
170
+ # defined within the service config.
171
+ # @!attribute [rw] unit
172
+ # @return [::String]
173
+ # Specify the unit of the quota limit. It uses the same syntax as
174
+ # [Metric.unit][]. The supported unit kinds are determined by the quota
175
+ # backend system.
176
+ #
177
+ # Here are some examples:
178
+ # * "1/min/\\{project}" for quota per minute per project.
179
+ #
180
+ # Note: the order of unit components is insignificant.
181
+ # The "1" at the beginning is required to follow the metric unit syntax.
182
+ # @!attribute [rw] values
183
+ # @return [::Google::Protobuf::Map{::String => ::Integer}]
184
+ # Tiered limit values. You must specify this as a key:value pair, with an
185
+ # integer value that is the maximum number of requests allowed for the
186
+ # specified unit. Currently only STANDARD is supported.
187
+ # @!attribute [rw] display_name
188
+ # @return [::String]
189
+ # User-visible display name for this limit.
190
+ # Optional. If not set, the UI will provide a default display name based on
191
+ # the quota configuration. This field can be used to override the default
192
+ # display name generated from the configuration.
193
+ class QuotaLimit
194
+ include ::Google::Protobuf::MessageExts
195
+ extend ::Google::Protobuf::MessageExts::ClassMethods
196
+
197
+ # @!attribute [rw] key
198
+ # @return [::String]
199
+ # @!attribute [rw] value
200
+ # @return [::Integer]
201
+ class ValuesEntry
202
+ include ::Google::Protobuf::MessageExts
203
+ extend ::Google::Protobuf::MessageExts::ClassMethods
204
+ end
205
+ end
206
+ end
207
+ end