google-cloud-monitoring 0.37.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (101) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +2 -1
  3. data/AUTHENTICATION.md +51 -59
  4. data/LICENSE.md +203 -0
  5. data/MIGRATING.md +361 -0
  6. data/README.md +34 -50
  7. data/lib/google-cloud-monitoring.rb +6 -5
  8. data/lib/google/cloud/monitoring.rb +255 -443
  9. data/lib/google/cloud/monitoring/dashboard.rb +88 -117
  10. data/lib/google/cloud/monitoring/{v3/doc/google/protobuf/wrappers.rb → dashboard/version.rb} +12 -9
  11. data/lib/google/cloud/monitoring/version.rb +6 -2
  12. metadata +72 -129
  13. data/LICENSE +0 -201
  14. data/lib/google/cloud/monitoring/dashboard/v1.rb +0 -148
  15. data/lib/google/cloud/monitoring/dashboard/v1/credentials.rb +0 -46
  16. data/lib/google/cloud/monitoring/dashboard/v1/dashboards_service_client.rb +0 -457
  17. data/lib/google/cloud/monitoring/dashboard/v1/dashboards_service_client_config.json +0 -51
  18. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/common.rb +0 -394
  19. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/dashboard.rb +0 -53
  20. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/dashboards_service.rb +0 -82
  21. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/layouts.rb +0 -71
  22. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/metrics.rb +0 -151
  23. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/scorecard.rb +0 -102
  24. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/text.rb +0 -43
  25. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/widget.rb +0 -41
  26. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/monitoring/dashboard/v1/xychart.rb +0 -141
  27. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/protobuf/duration.rb +0 -91
  28. data/lib/google/cloud/monitoring/dashboard/v1/doc/google/protobuf/empty.rb +0 -29
  29. data/lib/google/cloud/monitoring/v3.rb +0 -532
  30. data/lib/google/cloud/monitoring/v3/alert_policy_service_client.rb +0 -553
  31. data/lib/google/cloud/monitoring/v3/alert_policy_service_client_config.json +0 -51
  32. data/lib/google/cloud/monitoring/v3/credentials.rb +0 -44
  33. data/lib/google/cloud/monitoring/v3/doc/google/api/distribution.rb +0 -200
  34. data/lib/google/cloud/monitoring/v3/doc/google/api/label.rb +0 -42
  35. data/lib/google/cloud/monitoring/v3/doc/google/api/metric.rb +0 -245
  36. data/lib/google/cloud/monitoring/v3/doc/google/api/monitored_resource.rb +0 -108
  37. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/alert.rb +0 -345
  38. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/alert_service.rb +0 -138
  39. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/common.rb +0 -461
  40. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/group.rb +0 -75
  41. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/group_service.rb +0 -167
  42. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/metric.rb +0 -85
  43. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/metric_service.rb +0 -230
  44. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/mutation_record.rb +0 -29
  45. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/notification.rb +0 -156
  46. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/notification_service.rb +0 -221
  47. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/service.rb +0 -361
  48. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/service_service.rb +0 -197
  49. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/uptime.rb +0 -326
  50. data/lib/google/cloud/monitoring/v3/doc/google/monitoring/v3/uptime_service.rb +0 -136
  51. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/any.rb +0 -131
  52. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/duration.rb +0 -91
  53. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/empty.rb +0 -29
  54. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/field_mask.rb +0 -222
  55. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/struct.rb +0 -74
  56. data/lib/google/cloud/monitoring/v3/doc/google/protobuf/timestamp.rb +0 -113
  57. data/lib/google/cloud/monitoring/v3/doc/google/rpc/status.rb +0 -39
  58. data/lib/google/cloud/monitoring/v3/group_service_client.rb +0 -606
  59. data/lib/google/cloud/monitoring/v3/group_service_client_config.json +0 -56
  60. data/lib/google/cloud/monitoring/v3/metric_service_client.rb +0 -750
  61. data/lib/google/cloud/monitoring/v3/metric_service_client_config.json +0 -66
  62. data/lib/google/cloud/monitoring/v3/notification_channel_service_client.rb +0 -811
  63. data/lib/google/cloud/monitoring/v3/notification_channel_service_client_config.json +0 -76
  64. data/lib/google/cloud/monitoring/v3/service_monitoring_service_client.rb +0 -788
  65. data/lib/google/cloud/monitoring/v3/service_monitoring_service_client_config.json +0 -76
  66. data/lib/google/cloud/monitoring/v3/uptime_check_service_client.rb +0 -550
  67. data/lib/google/cloud/monitoring/v3/uptime_check_service_client_config.json +0 -56
  68. data/lib/google/monitoring/dashboard/v1/common_pb.rb +0 -95
  69. data/lib/google/monitoring/dashboard/v1/dashboard_pb.rb +0 -29
  70. data/lib/google/monitoring/dashboard/v1/dashboards_service_pb.rb +0 -51
  71. data/lib/google/monitoring/dashboard/v1/dashboards_service_services_pb.rb +0 -76
  72. data/lib/google/monitoring/dashboard/v1/drilldowns_pb.rb +0 -17
  73. data/lib/google/monitoring/dashboard/v1/layouts_pb.rb +0 -41
  74. data/lib/google/monitoring/dashboard/v1/metrics_pb.rb +0 -76
  75. data/lib/google/monitoring/dashboard/v1/scorecard_pb.rb +0 -38
  76. data/lib/google/monitoring/dashboard/v1/service_pb.rb +0 -17
  77. data/lib/google/monitoring/dashboard/v1/text_pb.rb +0 -28
  78. data/lib/google/monitoring/dashboard/v1/widget_pb.rb +0 -32
  79. data/lib/google/monitoring/dashboard/v1/xychart_pb.rb +0 -66
  80. data/lib/google/monitoring/v3/alert_pb.rb +0 -87
  81. data/lib/google/monitoring/v3/alert_service_pb.rb +0 -53
  82. data/lib/google/monitoring/v3/alert_service_services_pb.rb +0 -63
  83. data/lib/google/monitoring/v3/common_pb.rb +0 -95
  84. data/lib/google/monitoring/v3/dropped_labels_pb.rb +0 -19
  85. data/lib/google/monitoring/v3/group_pb.rb +0 -24
  86. data/lib/google/monitoring/v3/group_service_pb.rb +0 -73
  87. data/lib/google/monitoring/v3/group_service_services_pb.rb +0 -66
  88. data/lib/google/monitoring/v3/metric_pb.rb +0 -82
  89. data/lib/google/monitoring/v3/metric_service_pb.rb +0 -130
  90. data/lib/google/monitoring/v3/metric_service_services_pb.rb +0 -66
  91. data/lib/google/monitoring/v3/mutation_record_pb.rb +0 -21
  92. data/lib/google/monitoring/v3/notification_pb.rb +0 -47
  93. data/lib/google/monitoring/v3/notification_service_pb.rb +0 -90
  94. data/lib/google/monitoring/v3/notification_service_services_pb.rb +0 -94
  95. data/lib/google/monitoring/v3/service_pb.rb +0 -149
  96. data/lib/google/monitoring/v3/service_service_pb.rb +0 -86
  97. data/lib/google/monitoring/v3/service_service_services_pb.rb +0 -65
  98. data/lib/google/monitoring/v3/span_context_pb.rb +0 -19
  99. data/lib/google/monitoring/v3/uptime_pb.rb +0 -109
  100. data/lib/google/monitoring/v3/uptime_service_pb.rb +0 -63
  101. data/lib/google/monitoring/v3/uptime_service_services_pb.rb +0 -67
@@ -1,75 +0,0 @@
1
- # Copyright 2020 Google LLC
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # https://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
-
16
- module Google
17
- module Monitoring
18
- module V3
19
- # The description of a dynamic collection of monitored resources. Each group
20
- # has a filter that is matched against monitored resources and their associated
21
- # metadata. If a group's filter matches an available monitored resource, then
22
- # that resource is a member of that group. Groups can contain any number of
23
- # monitored resources, and each monitored resource can be a member of any
24
- # number of groups.
25
- #
26
- # Groups can be nested in parent-child hierarchies. The `parentName` field
27
- # identifies an optional parent for each group. If a group has a parent, then
28
- # the only monitored resources available to be matched by the group's filter
29
- # are the resources contained in the parent group. In other words, a group
30
- # contains the monitored resources that match its filter and the filters of all
31
- # the group's ancestors. A group without a parent can contain any monitored
32
- # resource.
33
- #
34
- # For example, consider an infrastructure running a set of instances with two
35
- # user-defined tags: `"environment"` and `"role"`. A parent group has a filter,
36
- # `environment="production"`. A child of that parent group has a filter,
37
- # `role="transcoder"`. The parent group contains all instances in the
38
- # production environment, regardless of their roles. The child group contains
39
- # instances that have the transcoder role *and* are in the production
40
- # environment.
41
- #
42
- # The monitored resources contained in a group can change at any moment,
43
- # depending on what resources exist and what filters are associated with the
44
- # group and its ancestors.
45
- # @!attribute [rw] name
46
- # @return [String]
47
- # Output only. The name of this group. The format is:
48
- #
49
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
50
- #
51
- # When creating a group, this field is ignored and a new name is created
52
- # consisting of the project specified in the call to `CreateGroup`
53
- # and a unique `[GROUP_ID]` that is generated automatically.
54
- # @!attribute [rw] display_name
55
- # @return [String]
56
- # A user-assigned name for this group, used only for display purposes.
57
- # @!attribute [rw] parent_name
58
- # @return [String]
59
- # The name of the group's parent, if it has one. The format is:
60
- #
61
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
62
- #
63
- # For groups with no parent, `parent_name` is the empty string, `""`.
64
- # @!attribute [rw] filter
65
- # @return [String]
66
- # The filter used to determine which monitored resources belong to this
67
- # group.
68
- # @!attribute [rw] is_cluster
69
- # @return [true, false]
70
- # If true, the members of this group are considered to be a cluster.
71
- # The system can perform additional analysis on groups that are clusters.
72
- class Group; end
73
- end
74
- end
75
- end
@@ -1,167 +0,0 @@
1
- # Copyright 2020 Google LLC
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # https://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
-
16
- module Google
17
- module Monitoring
18
- module V3
19
- # The `ListGroup` request.
20
- # @!attribute [rw] name
21
- # @return [String]
22
- # Required. The project whose groups are to be listed. The format is:
23
- #
24
- # projects/[PROJECT_ID_OR_NUMBER]
25
- # @!attribute [rw] children_of_group
26
- # @return [String]
27
- # A group name. The format is:
28
- #
29
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
30
- #
31
- # Returns groups whose `parent_name` field contains the group
32
- # name. If no groups have this parent, the results are empty.
33
- # @!attribute [rw] ancestors_of_group
34
- # @return [String]
35
- # A group name. The format is:
36
- #
37
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
38
- #
39
- # Returns groups that are ancestors of the specified group.
40
- # The groups are returned in order, starting with the immediate parent and
41
- # ending with the most distant ancestor. If the specified group has no
42
- # immediate parent, the results are empty.
43
- # @!attribute [rw] descendants_of_group
44
- # @return [String]
45
- # A group name. The format is:
46
- #
47
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
48
- #
49
- # Returns the descendants of the specified group. This is a superset of
50
- # the results returned by the `children_of_group` filter, and includes
51
- # children-of-children, and so forth.
52
- # @!attribute [rw] page_size
53
- # @return [Integer]
54
- # A positive number that is the maximum number of results to return.
55
- # @!attribute [rw] page_token
56
- # @return [String]
57
- # If this field is not empty then it must contain the `next_page_token` value
58
- # returned by a previous call to this method. Using this field causes the
59
- # method to return additional results from the previous method call.
60
- class ListGroupsRequest; end
61
-
62
- # The `ListGroups` response.
63
- # @!attribute [rw] group
64
- # @return [Array<Google::Monitoring::V3::Group>]
65
- # The groups that match the specified filters.
66
- # @!attribute [rw] next_page_token
67
- # @return [String]
68
- # If there are more results than have been returned, then this field is set
69
- # to a non-empty value. To see the additional results,
70
- # use that value as `page_token` in the next call to this method.
71
- class ListGroupsResponse; end
72
-
73
- # The `GetGroup` request.
74
- # @!attribute [rw] name
75
- # @return [String]
76
- # Required. The group to retrieve. The format is:
77
- #
78
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
79
- class GetGroupRequest; end
80
-
81
- # The `CreateGroup` request.
82
- # @!attribute [rw] name
83
- # @return [String]
84
- # Required. The project in which to create the group. The format is:
85
- #
86
- # projects/[PROJECT_ID_OR_NUMBER]
87
- # @!attribute [rw] group
88
- # @return [Google::Monitoring::V3::Group]
89
- # Required. A group definition. It is an error to define the `name` field because
90
- # the system assigns the name.
91
- # @!attribute [rw] validate_only
92
- # @return [true, false]
93
- # If true, validate this request but do not create the group.
94
- class CreateGroupRequest; end
95
-
96
- # The `UpdateGroup` request.
97
- # @!attribute [rw] group
98
- # @return [Google::Monitoring::V3::Group]
99
- # Required. The new definition of the group. All fields of the existing group,
100
- # excepting `name`, are replaced with the corresponding fields of this group.
101
- # @!attribute [rw] validate_only
102
- # @return [true, false]
103
- # If true, validate this request but do not update the existing group.
104
- class UpdateGroupRequest; end
105
-
106
- # The `DeleteGroup` request. The default behavior is to be able to delete a
107
- # single group without any descendants.
108
- # @!attribute [rw] name
109
- # @return [String]
110
- # Required. The group to delete. The format is:
111
- #
112
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
113
- # @!attribute [rw] recursive
114
- # @return [true, false]
115
- # If this field is true, then the request means to delete a group with all
116
- # its descendants. Otherwise, the request means to delete a group only when
117
- # it has no descendants. The default value is false.
118
- class DeleteGroupRequest; end
119
-
120
- # The `ListGroupMembers` request.
121
- # @!attribute [rw] name
122
- # @return [String]
123
- # Required. The group whose members are listed. The format is:
124
- #
125
- # projects/[PROJECT_ID_OR_NUMBER]/groups/[GROUP_ID]
126
- # @!attribute [rw] page_size
127
- # @return [Integer]
128
- # A positive number that is the maximum number of results to return.
129
- # @!attribute [rw] page_token
130
- # @return [String]
131
- # If this field is not empty then it must contain the `next_page_token` value
132
- # returned by a previous call to this method. Using this field causes the
133
- # method to return additional results from the previous method call.
134
- # @!attribute [rw] filter
135
- # @return [String]
136
- # An optional [list
137
- # filter](https://cloud.google.com/monitoring/api/learn_more#filtering)
138
- # describing the members to be returned. The filter may reference the type,
139
- # labels, and metadata of monitored resources that comprise the group. For
140
- # example, to return only resources representing Compute Engine VM instances,
141
- # use this filter:
142
- #
143
- # `resource.type = "gce_instance"`
144
- # @!attribute [rw] interval
145
- # @return [Google::Monitoring::V3::TimeInterval]
146
- # An optional time interval for which results should be returned. Only
147
- # members that were part of the group during the specified interval are
148
- # included in the response. If no interval is provided then the group
149
- # membership over the last minute is returned.
150
- class ListGroupMembersRequest; end
151
-
152
- # The `ListGroupMembers` response.
153
- # @!attribute [rw] members
154
- # @return [Array<Google::Api::MonitoredResource>]
155
- # A set of monitored resources in the group.
156
- # @!attribute [rw] next_page_token
157
- # @return [String]
158
- # If there are more results than have been returned, then this field is
159
- # set to a non-empty value. To see the additional results, use that value as
160
- # `page_token` in the next call to this method.
161
- # @!attribute [rw] total_size
162
- # @return [Integer]
163
- # The total number of elements matching this request.
164
- class ListGroupMembersResponse; end
165
- end
166
- end
167
- end
@@ -1,85 +0,0 @@
1
- # Copyright 2020 Google LLC
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # https://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
-
16
- module Google
17
- module Monitoring
18
- module V3
19
- # A single data point in a time series.
20
- # @!attribute [rw] interval
21
- # @return [Google::Monitoring::V3::TimeInterval]
22
- # The time interval to which the data point applies. For `GAUGE` metrics,
23
- # the start time is optional, but if it is supplied, it must equal the
24
- # end time. For `DELTA` metrics, the start
25
- # and end time should specify a non-zero interval, with subsequent points
26
- # specifying contiguous and non-overlapping intervals. For `CUMULATIVE`
27
- # metrics, the start and end time should specify a non-zero interval, with
28
- # subsequent points specifying the same start time and increasing end times,
29
- # until an event resets the cumulative value to zero and sets a new start
30
- # time for the following points.
31
- # @!attribute [rw] value
32
- # @return [Google::Monitoring::V3::TypedValue]
33
- # The value of the data point.
34
- class Point; end
35
-
36
- # A collection of data points that describes the time-varying values
37
- # of a metric. A time series is identified by a combination of a
38
- # fully-specified monitored resource and a fully-specified metric.
39
- # This type is used for both listing and creating time series.
40
- # @!attribute [rw] metric
41
- # @return [Google::Api::Metric]
42
- # The associated metric. A fully-specified metric used to identify the time
43
- # series.
44
- # @!attribute [rw] resource
45
- # @return [Google::Api::MonitoredResource]
46
- # The associated monitored resource. Custom metrics can use only certain
47
- # monitored resource types in their time series data.
48
- # @!attribute [rw] metadata
49
- # @return [Google::Api::MonitoredResourceMetadata]
50
- # Output only. The associated monitored resource metadata. When reading a
51
- # a timeseries, this field will include metadata labels that are explicitly
52
- # named in the reduction. When creating a timeseries, this field is ignored.
53
- # @!attribute [rw] metric_kind
54
- # @return [Google::Api::MetricDescriptor::MetricKind]
55
- # The metric kind of the time series. When listing time series, this metric
56
- # kind might be different from the metric kind of the associated metric if
57
- # this time series is an alignment or reduction of other time series.
58
- #
59
- # When creating a time series, this field is optional. If present, it must be
60
- # the same as the metric kind of the associated metric. If the associated
61
- # metric's descriptor must be auto-created, then this field specifies the
62
- # metric kind of the new descriptor and must be either `GAUGE` (the default)
63
- # or `CUMULATIVE`.
64
- # @!attribute [rw] value_type
65
- # @return [Google::Api::MetricDescriptor::ValueType]
66
- # The value type of the time series. When listing time series, this value
67
- # type might be different from the value type of the associated metric if
68
- # this time series is an alignment or reduction of other time series.
69
- #
70
- # When creating a time series, this field is optional. If present, it must be
71
- # the same as the type of the data in the `points` field.
72
- # @!attribute [rw] points
73
- # @return [Array<Google::Monitoring::V3::Point>]
74
- # The data points of this time series. When listing time series, points are
75
- # returned in reverse time order.
76
- #
77
- # When creating a time series, this field must contain exactly one point and
78
- # the point's type must be the same as the value type of the associated
79
- # metric. If the associated metric's descriptor must be auto-created, then
80
- # the value type of the descriptor is determined by the point's type, which
81
- # must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`.
82
- class TimeSeries; end
83
- end
84
- end
85
- end
@@ -1,230 +0,0 @@
1
- # Copyright 2020 Google LLC
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # https://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
-
16
- module Google
17
- module Monitoring
18
- module V3
19
- # The `ListMonitoredResourceDescriptors` request.
20
- # @!attribute [rw] name
21
- # @return [String]
22
- # Required. The project on which to execute the request. The format is:
23
- #
24
- # projects/[PROJECT_ID_OR_NUMBER]
25
- # @!attribute [rw] filter
26
- # @return [String]
27
- # An optional [filter](https://cloud.google.com/monitoring/api/v3/filters)
28
- # describing the descriptors to be returned. The filter can reference the
29
- # descriptor's type and labels. For example, the following filter returns
30
- # only Google Compute Engine descriptors that have an `id` label:
31
- #
32
- # resource.type = starts_with("gce_") AND resource.label:id
33
- # @!attribute [rw] page_size
34
- # @return [Integer]
35
- # A positive number that is the maximum number of results to return.
36
- # @!attribute [rw] page_token
37
- # @return [String]
38
- # If this field is not empty then it must contain the `nextPageToken` value
39
- # returned by a previous call to this method. Using this field causes the
40
- # method to return additional results from the previous method call.
41
- class ListMonitoredResourceDescriptorsRequest; end
42
-
43
- # The `ListMonitoredResourceDescriptors` response.
44
- # @!attribute [rw] resource_descriptors
45
- # @return [Array<Google::Api::MonitoredResourceDescriptor>]
46
- # The monitored resource descriptors that are available to this project
47
- # and that match `filter`, if present.
48
- # @!attribute [rw] next_page_token
49
- # @return [String]
50
- # If there are more results than have been returned, then this field is set
51
- # to a non-empty value. To see the additional results,
52
- # use that value as `page_token` in the next call to this method.
53
- class ListMonitoredResourceDescriptorsResponse; end
54
-
55
- # The `GetMonitoredResourceDescriptor` request.
56
- # @!attribute [rw] name
57
- # @return [String]
58
- # Required. The monitored resource descriptor to get. The format is:
59
- #
60
- # projects/[PROJECT_ID_OR_NUMBER]/monitoredResourceDescriptors/[RESOURCE_TYPE]
61
- #
62
- # The `[RESOURCE_TYPE]` is a predefined type, such as
63
- # `cloudsql_database`.
64
- class GetMonitoredResourceDescriptorRequest; end
65
-
66
- # The `ListMetricDescriptors` request.
67
- # @!attribute [rw] name
68
- # @return [String]
69
- # Required. The project on which to execute the request. The format is:
70
- #
71
- # projects/[PROJECT_ID_OR_NUMBER]
72
- # @!attribute [rw] filter
73
- # @return [String]
74
- # If this field is empty, all custom and
75
- # system-defined metric descriptors are returned.
76
- # Otherwise, the [filter](https://cloud.google.com/monitoring/api/v3/filters)
77
- # specifies which metric descriptors are to be
78
- # returned. For example, the following filter matches all
79
- # [custom metrics](https://cloud.google.com/monitoring/custom-metrics):
80
- #
81
- # metric.type = starts_with("custom.googleapis.com/")
82
- # @!attribute [rw] page_size
83
- # @return [Integer]
84
- # A positive number that is the maximum number of results to return.
85
- # @!attribute [rw] page_token
86
- # @return [String]
87
- # If this field is not empty then it must contain the `nextPageToken` value
88
- # returned by a previous call to this method. Using this field causes the
89
- # method to return additional results from the previous method call.
90
- class ListMetricDescriptorsRequest; end
91
-
92
- # The `ListMetricDescriptors` response.
93
- # @!attribute [rw] metric_descriptors
94
- # @return [Array<Google::Api::MetricDescriptor>]
95
- # The metric descriptors that are available to the project
96
- # and that match the value of `filter`, if present.
97
- # @!attribute [rw] next_page_token
98
- # @return [String]
99
- # If there are more results than have been returned, then this field is set
100
- # to a non-empty value. To see the additional results,
101
- # use that value as `page_token` in the next call to this method.
102
- class ListMetricDescriptorsResponse; end
103
-
104
- # The `GetMetricDescriptor` request.
105
- # @!attribute [rw] name
106
- # @return [String]
107
- # Required. The metric descriptor on which to execute the request. The format is:
108
- #
109
- # projects/[PROJECT_ID_OR_NUMBER]/metricDescriptors/[METRIC_ID]
110
- #
111
- # An example value of `[METRIC_ID]` is
112
- # `"compute.googleapis.com/instance/disk/read_bytes_count"`.
113
- class GetMetricDescriptorRequest; end
114
-
115
- # The `CreateMetricDescriptor` request.
116
- # @!attribute [rw] name
117
- # @return [String]
118
- # Required. The project on which to execute the request. The format is:
119
- #
120
- # projects/[PROJECT_ID_OR_NUMBER]
121
- # @!attribute [rw] metric_descriptor
122
- # @return [Google::Api::MetricDescriptor]
123
- # Required. The new [custom metric](https://cloud.google.com/monitoring/custom-metrics)
124
- # descriptor.
125
- class CreateMetricDescriptorRequest; end
126
-
127
- # The `DeleteMetricDescriptor` request.
128
- # @!attribute [rw] name
129
- # @return [String]
130
- # Required. The metric descriptor on which to execute the request. The format is:
131
- #
132
- # projects/[PROJECT_ID_OR_NUMBER]/metricDescriptors/[METRIC_ID]
133
- #
134
- # An example of `[METRIC_ID]` is:
135
- # `"custom.googleapis.com/my_test_metric"`.
136
- class DeleteMetricDescriptorRequest; end
137
-
138
- # The `ListTimeSeries` request.
139
- # @!attribute [rw] name
140
- # @return [String]
141
- # Required. The project on which to execute the request. The format is:
142
- #
143
- # projects/[PROJECT_ID_OR_NUMBER]
144
- # @!attribute [rw] filter
145
- # @return [String]
146
- # Required. A [monitoring filter](https://cloud.google.com/monitoring/api/v3/filters)
147
- # that specifies which time series should be returned. The filter must
148
- # specify a single metric type, and can additionally specify metric labels
149
- # and other information. For example:
150
- #
151
- # metric.type = "compute.googleapis.com/instance/cpu/usage_time" AND
152
- # metric.labels.instance_name = "my-instance-name"
153
- # @!attribute [rw] interval
154
- # @return [Google::Monitoring::V3::TimeInterval]
155
- # Required. The time interval for which results should be returned. Only time series
156
- # that contain data points in the specified interval are included
157
- # in the response.
158
- # @!attribute [rw] aggregation
159
- # @return [Google::Monitoring::V3::Aggregation]
160
- # Specifies the alignment of data points in individual time series as
161
- # well as how to combine the retrieved time series across specified labels.
162
- #
163
- # By default (if no `aggregation` is explicitly specified), the raw time
164
- # series data is returned.
165
- # @!attribute [rw] order_by
166
- # @return [String]
167
- # Unsupported: must be left blank. The points in each time series are
168
- # currently returned in reverse time order (most recent to oldest).
169
- # @!attribute [rw] view
170
- # @return [Google::Monitoring::V3::ListTimeSeriesRequest::TimeSeriesView]
171
- # Required. Specifies which information is returned about the time series.
172
- # @!attribute [rw] page_size
173
- # @return [Integer]
174
- # A positive number that is the maximum number of results to return. If
175
- # `page_size` is empty or more than 100,000 results, the effective
176
- # `page_size` is 100,000 results. If `view` is set to `FULL`, this is the
177
- # maximum number of `Points` returned. If `view` is set to `HEADERS`, this is
178
- # the maximum number of `TimeSeries` returned.
179
- # @!attribute [rw] page_token
180
- # @return [String]
181
- # If this field is not empty then it must contain the `nextPageToken` value
182
- # returned by a previous call to this method. Using this field causes the
183
- # method to return additional results from the previous method call.
184
- class ListTimeSeriesRequest
185
- # Controls which fields are returned by `ListTimeSeries`.
186
- module TimeSeriesView
187
- # Returns the identity of the metric(s), the time series,
188
- # and the time series data.
189
- FULL = 0
190
-
191
- # Returns the identity of the metric and the time series resource,
192
- # but not the time series data.
193
- HEADERS = 1
194
- end
195
- end
196
-
197
- # The `ListTimeSeries` response.
198
- # @!attribute [rw] time_series
199
- # @return [Array<Google::Monitoring::V3::TimeSeries>]
200
- # One or more time series that match the filter included in the request.
201
- # @!attribute [rw] next_page_token
202
- # @return [String]
203
- # If there are more results than have been returned, then this field is set
204
- # to a non-empty value. To see the additional results,
205
- # use that value as `page_token` in the next call to this method.
206
- # @!attribute [rw] execution_errors
207
- # @return [Array<Google::Rpc::Status>]
208
- # Query execution errors that may have caused the time series data returned
209
- # to be incomplete.
210
- class ListTimeSeriesResponse; end
211
-
212
- # The `CreateTimeSeries` request.
213
- # @!attribute [rw] name
214
- # @return [String]
215
- # Required. The project on which to execute the request. The format is:
216
- #
217
- # projects/[PROJECT_ID_OR_NUMBER]
218
- # @!attribute [rw] time_series
219
- # @return [Array<Google::Monitoring::V3::TimeSeries>]
220
- # Required. The new data to be added to a list of time series.
221
- # Adds at most one data point to each of several time series. The new data
222
- # point must be more recent than any other point in its time series. Each
223
- # `TimeSeries` value must fully specify a unique time series by supplying
224
- # all label values for the metric and the monitored resource.
225
- #
226
- # The maximum number of `TimeSeries` objects per `Create` request is 200.
227
- class CreateTimeSeriesRequest; end
228
- end
229
- end
230
- end