google-cloud-monitoring-v3 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/monitoring/v3.rb +1 -0
- data/lib/google/cloud/monitoring/v3/alert_policy_service/client.rb +6 -5
- data/lib/google/cloud/monitoring/v3/alert_policy_service/paths.rb +25 -6
- data/lib/google/cloud/monitoring/v3/group_service/paths.rb +25 -6
- data/lib/google/cloud/monitoring/v3/metric_service/client.rb +8 -2
- data/lib/google/cloud/monitoring/v3/metric_service/paths.rb +33 -0
- data/lib/google/cloud/monitoring/v3/notification_channel_service/paths.rb +25 -6
- data/lib/google/cloud/monitoring/v3/query_service.rb +50 -0
- data/lib/google/cloud/monitoring/v3/query_service/client.rb +388 -0
- data/lib/google/cloud/monitoring/v3/query_service/credentials.rb +53 -0
- data/lib/google/cloud/monitoring/v3/service_monitoring_service/client.rb +10 -6
- data/lib/google/cloud/monitoring/v3/service_monitoring_service/paths.rb +33 -14
- data/lib/google/cloud/monitoring/v3/uptime_check_service/paths.rb +33 -14
- data/lib/google/cloud/monitoring/v3/version.rb +1 -1
- data/lib/google/monitoring/v3/alert_pb.rb +8 -0
- data/lib/google/monitoring/v3/alert_service_pb.rb +1 -0
- data/lib/google/monitoring/v3/alert_service_services_pb.rb +1 -1
- data/lib/google/monitoring/v3/metric_pb.rb +2 -0
- data/lib/google/monitoring/v3/metric_service_pb.rb +2 -0
- data/lib/google/monitoring/v3/notification_pb.rb +3 -0
- data/lib/google/monitoring/v3/notification_service_pb.rb +1 -0
- data/lib/google/monitoring/v3/query_service_pb.rb +23 -0
- data/lib/google/monitoring/v3/query_service_services_pb.rb +47 -0
- data/lib/google/monitoring/v3/service_pb.rb +7 -1
- data/proto_docs/google/monitoring/v3/alert.rb +47 -11
- data/proto_docs/google/monitoring/v3/alert_service.rb +9 -4
- data/proto_docs/google/monitoring/v3/common.rb +28 -19
- data/proto_docs/google/monitoring/v3/dropped_labels.rb +10 -9
- data/proto_docs/google/monitoring/v3/metric.rb +14 -3
- data/proto_docs/google/monitoring/v3/metric_service.rb +19 -3
- data/proto_docs/google/monitoring/v3/notification.rb +10 -1
- data/proto_docs/google/monitoring/v3/notification_service.rb +4 -0
- data/proto_docs/google/monitoring/v3/service.rb +33 -2
- data/proto_docs/google/monitoring/v3/service_service.rb +10 -6
- data/proto_docs/google/monitoring/v3/uptime.rb +24 -13
- metadata +9 -4
@@ -0,0 +1,53 @@
|
|
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
|
+
require "googleauth"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Cloud
|
23
|
+
module Monitoring
|
24
|
+
module V3
|
25
|
+
module QueryService
|
26
|
+
# Credentials for the QueryService API.
|
27
|
+
class Credentials < ::Google::Auth::Credentials
|
28
|
+
self.scope = [
|
29
|
+
"https://www.googleapis.com/auth/cloud-platform",
|
30
|
+
"https://www.googleapis.com/auth/monitoring",
|
31
|
+
"https://www.googleapis.com/auth/monitoring.read"
|
32
|
+
]
|
33
|
+
self.env_vars = [
|
34
|
+
"MONITORING_CREDENTIALS",
|
35
|
+
"MONITORING_KEYFILE",
|
36
|
+
"GOOGLE_CLOUD_CREDENTIALS",
|
37
|
+
"GOOGLE_CLOUD_KEYFILE",
|
38
|
+
"GCLOUD_KEYFILE",
|
39
|
+
"MONITORING_CREDENTIALS_JSON",
|
40
|
+
"MONITORING_KEYFILE_JSON",
|
41
|
+
"GOOGLE_CLOUD_CREDENTIALS_JSON",
|
42
|
+
"GOOGLE_CLOUD_KEYFILE_JSON",
|
43
|
+
"GCLOUD_KEYFILE_JSON"
|
44
|
+
]
|
45
|
+
self.paths = [
|
46
|
+
"~/.config/google_cloud/application_default_credentials.json"
|
47
|
+
]
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
@@ -380,16 +380,20 @@ module Google
|
|
380
380
|
#
|
381
381
|
# - `identifier_case`
|
382
382
|
# - `app_engine.module_id`
|
383
|
-
# - `cloud_endpoints.service`
|
384
|
-
# - `
|
385
|
-
# - `
|
386
|
-
# - `
|
387
|
-
# - `cluster_istio.
|
383
|
+
# - `cloud_endpoints.service` (reserved for future use)
|
384
|
+
# - `mesh_istio.mesh_uid`
|
385
|
+
# - `mesh_istio.service_namespace`
|
386
|
+
# - `mesh_istio.service_name`
|
387
|
+
# - `cluster_istio.location` (deprecated)
|
388
|
+
# - `cluster_istio.cluster_name` (deprecated)
|
389
|
+
# - `cluster_istio.service_namespace` (deprecated)
|
390
|
+
# - `cluster_istio.service_name` (deprecated)
|
388
391
|
#
|
389
392
|
# `identifier_case` refers to which option in the identifier oneof is
|
390
393
|
# populated. For example, the filter `identifier_case = "CUSTOM"` would match
|
391
394
|
# all services with a value for the `custom` field. Valid options are
|
392
|
-
# "CUSTOM", "APP_ENGINE", "
|
395
|
+
# "CUSTOM", "APP_ENGINE", "MESH_ISTIO", plus "CLUSTER_ISTIO" (deprecated)
|
396
|
+
# and "CLOUD_ENDPOINTS" (reserved for future use).
|
393
397
|
# @param page_size [::Integer]
|
394
398
|
# A non-negative number that is the maximum number of results to return.
|
395
399
|
# When 0, use default page size.
|
@@ -52,20 +52,6 @@ module Google
|
|
52
52
|
"organizations/#{organization}"
|
53
53
|
end
|
54
54
|
|
55
|
-
##
|
56
|
-
# Create a fully-qualified Project resource string.
|
57
|
-
#
|
58
|
-
# The resource will be in the following format:
|
59
|
-
#
|
60
|
-
# `projects/{project}`
|
61
|
-
#
|
62
|
-
# @param project [String]
|
63
|
-
#
|
64
|
-
# @return [::String]
|
65
|
-
def project_path project:
|
66
|
-
"projects/#{project}"
|
67
|
-
end
|
68
|
-
|
69
55
|
##
|
70
56
|
# Create a fully-qualified Service resource string.
|
71
57
|
#
|
@@ -176,6 +162,39 @@ module Google
|
|
176
162
|
resource.call(**args)
|
177
163
|
end
|
178
164
|
|
165
|
+
##
|
166
|
+
# Create a fully-qualified Workspace resource string.
|
167
|
+
#
|
168
|
+
# @overload workspace_path(project:)
|
169
|
+
# The resource will be in the following format:
|
170
|
+
#
|
171
|
+
# `projects/{project}`
|
172
|
+
#
|
173
|
+
# @param project [String]
|
174
|
+
#
|
175
|
+
# @overload workspace_path(workspace:)
|
176
|
+
# The resource will be in the following format:
|
177
|
+
#
|
178
|
+
# `workspaces/{workspace}`
|
179
|
+
#
|
180
|
+
# @param workspace [String]
|
181
|
+
#
|
182
|
+
# @return [::String]
|
183
|
+
def workspace_path **args
|
184
|
+
resources = {
|
185
|
+
"project" => (proc do |project:|
|
186
|
+
"projects/#{project}"
|
187
|
+
end),
|
188
|
+
"workspace" => (proc do |workspace:|
|
189
|
+
"workspaces/#{workspace}"
|
190
|
+
end)
|
191
|
+
}
|
192
|
+
|
193
|
+
resource = resources[args.keys.sort.join(":")]
|
194
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
195
|
+
resource.call(**args)
|
196
|
+
end
|
197
|
+
|
179
198
|
extend self
|
180
199
|
end
|
181
200
|
end
|
@@ -52,20 +52,6 @@ module Google
|
|
52
52
|
"organizations/#{organization}"
|
53
53
|
end
|
54
54
|
|
55
|
-
##
|
56
|
-
# Create a fully-qualified Project resource string.
|
57
|
-
#
|
58
|
-
# The resource will be in the following format:
|
59
|
-
#
|
60
|
-
# `projects/{project}`
|
61
|
-
#
|
62
|
-
# @param project [String]
|
63
|
-
#
|
64
|
-
# @return [::String]
|
65
|
-
def project_path project:
|
66
|
-
"projects/#{project}"
|
67
|
-
end
|
68
|
-
|
69
55
|
##
|
70
56
|
# Create a fully-qualified UptimeCheckConfig resource string.
|
71
57
|
#
|
@@ -118,6 +104,39 @@ module Google
|
|
118
104
|
resource.call(**args)
|
119
105
|
end
|
120
106
|
|
107
|
+
##
|
108
|
+
# Create a fully-qualified Workspace resource string.
|
109
|
+
#
|
110
|
+
# @overload workspace_path(project:)
|
111
|
+
# The resource will be in the following format:
|
112
|
+
#
|
113
|
+
# `projects/{project}`
|
114
|
+
#
|
115
|
+
# @param project [String]
|
116
|
+
#
|
117
|
+
# @overload workspace_path(workspace:)
|
118
|
+
# The resource will be in the following format:
|
119
|
+
#
|
120
|
+
# `workspaces/{workspace}`
|
121
|
+
#
|
122
|
+
# @param workspace [String]
|
123
|
+
#
|
124
|
+
# @return [::String]
|
125
|
+
def workspace_path **args
|
126
|
+
resources = {
|
127
|
+
"project" => (proc do |project:|
|
128
|
+
"projects/#{project}"
|
129
|
+
end),
|
130
|
+
"workspace" => (proc do |workspace:|
|
131
|
+
"workspaces/#{workspace}"
|
132
|
+
end)
|
133
|
+
}
|
134
|
+
|
135
|
+
resource = resources[args.keys.sort.join(":")]
|
136
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
137
|
+
resource.call(**args)
|
138
|
+
end
|
139
|
+
|
121
140
|
extend self
|
122
141
|
end
|
123
142
|
end
|
@@ -3,6 +3,7 @@
|
|
3
3
|
|
4
4
|
require 'google/protobuf'
|
5
5
|
|
6
|
+
require 'google/api/field_behavior_pb'
|
6
7
|
require 'google/api/resource_pb'
|
7
8
|
require 'google/monitoring/v3/common_pb'
|
8
9
|
require 'google/monitoring/v3/mutation_record_pb'
|
@@ -34,6 +35,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
34
35
|
oneof :condition do
|
35
36
|
optional :condition_threshold, :message, 1, "google.monitoring.v3.AlertPolicy.Condition.MetricThreshold"
|
36
37
|
optional :condition_absent, :message, 2, "google.monitoring.v3.AlertPolicy.Condition.MetricAbsence"
|
38
|
+
optional :condition_monitoring_query_language, :message, 19, "google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition"
|
37
39
|
end
|
38
40
|
end
|
39
41
|
add_message "google.monitoring.v3.AlertPolicy.Condition.Trigger" do
|
@@ -58,6 +60,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
58
60
|
optional :duration, :message, 2, "google.protobuf.Duration"
|
59
61
|
optional :trigger, :message, 3, "google.monitoring.v3.AlertPolicy.Condition.Trigger"
|
60
62
|
end
|
63
|
+
add_message "google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition" do
|
64
|
+
optional :query, :string, 1
|
65
|
+
optional :duration, :message, 2, "google.protobuf.Duration"
|
66
|
+
optional :trigger, :message, 3, "google.monitoring.v3.AlertPolicy.Condition.Trigger"
|
67
|
+
end
|
61
68
|
add_enum "google.monitoring.v3.AlertPolicy.ConditionCombinerType" do
|
62
69
|
value :COMBINE_UNSPECIFIED, 0
|
63
70
|
value :AND, 1
|
@@ -77,6 +84,7 @@ module Google
|
|
77
84
|
AlertPolicy::Condition::Trigger = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.Trigger").msgclass
|
78
85
|
AlertPolicy::Condition::MetricThreshold = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MetricThreshold").msgclass
|
79
86
|
AlertPolicy::Condition::MetricAbsence = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MetricAbsence").msgclass
|
87
|
+
AlertPolicy::Condition::MonitoringQueryLanguageCondition = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition").msgclass
|
80
88
|
AlertPolicy::ConditionCombinerType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.ConditionCombinerType").enummodule
|
81
89
|
end
|
82
90
|
end
|
@@ -29,6 +29,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
29
29
|
add_message "google.monitoring.v3.ListAlertPoliciesResponse" do
|
30
30
|
repeated :alert_policies, :message, 3, "google.monitoring.v3.AlertPolicy"
|
31
31
|
optional :next_page_token, :string, 2
|
32
|
+
optional :total_size, :int32, 4
|
32
33
|
end
|
33
34
|
add_message "google.monitoring.v3.UpdateAlertPolicyRequest" do
|
34
35
|
optional :update_mask, :message, 2, "google.protobuf.FieldMask"
|
@@ -41,7 +41,7 @@ module Google
|
|
41
41
|
self.unmarshal_class_method = :decode
|
42
42
|
self.service_name = 'google.monitoring.v3.AlertPolicyService'
|
43
43
|
|
44
|
-
# Lists the existing alerting policies for the
|
44
|
+
# Lists the existing alerting policies for the workspace.
|
45
45
|
rpc :ListAlertPolicies, ::Google::Cloud::Monitoring::V3::ListAlertPoliciesRequest, ::Google::Cloud::Monitoring::V3::ListAlertPoliciesResponse
|
46
46
|
# Gets a single alerting policy.
|
47
47
|
rpc :GetAlertPolicy, ::Google::Cloud::Monitoring::V3::GetAlertPolicyRequest, ::Google::Cloud::Monitoring::V3::AlertPolicy
|
@@ -22,6 +22,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
22
22
|
optional :metric_kind, :enum, 3, "google.api.MetricDescriptor.MetricKind"
|
23
23
|
optional :value_type, :enum, 4, "google.api.MetricDescriptor.ValueType"
|
24
24
|
repeated :points, :message, 5, "google.monitoring.v3.Point"
|
25
|
+
optional :unit, :string, 8
|
25
26
|
end
|
26
27
|
add_message "google.monitoring.v3.TimeSeriesDescriptor" do
|
27
28
|
repeated :label_descriptors, :message, 1, "google.api.LabelDescriptor"
|
@@ -31,6 +32,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
31
32
|
optional :key, :string, 1
|
32
33
|
optional :value_type, :enum, 2, "google.api.MetricDescriptor.ValueType"
|
33
34
|
optional :metric_kind, :enum, 3, "google.api.MetricDescriptor.MetricKind"
|
35
|
+
optional :unit, :string, 4
|
34
36
|
end
|
35
37
|
add_message "google.monitoring.v3.TimeSeriesData" do
|
36
38
|
repeated :label_values, :message, 1, "google.monitoring.v3.LabelValue"
|
@@ -55,6 +55,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
55
55
|
optional :filter, :string, 2
|
56
56
|
optional :interval, :message, 4, "google.monitoring.v3.TimeInterval"
|
57
57
|
optional :aggregation, :message, 5, "google.monitoring.v3.Aggregation"
|
58
|
+
optional :secondary_aggregation, :message, 11, "google.monitoring.v3.Aggregation"
|
58
59
|
optional :order_by, :string, 6
|
59
60
|
optional :view, :enum, 7, "google.monitoring.v3.ListTimeSeriesRequest.TimeSeriesView"
|
60
61
|
optional :page_size, :int32, 8
|
@@ -68,6 +69,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
68
69
|
repeated :time_series, :message, 1, "google.monitoring.v3.TimeSeries"
|
69
70
|
optional :next_page_token, :string, 2
|
70
71
|
repeated :execution_errors, :message, 3, "google.rpc.Status"
|
72
|
+
optional :unit, :string, 5
|
71
73
|
end
|
72
74
|
add_message "google.monitoring.v3.CreateTimeSeriesRequest" do
|
73
75
|
optional :name, :string, 3
|
@@ -7,6 +7,7 @@ require 'google/api/label_pb'
|
|
7
7
|
require 'google/api/launch_stage_pb'
|
8
8
|
require 'google/api/resource_pb'
|
9
9
|
require 'google/monitoring/v3/common_pb'
|
10
|
+
require 'google/monitoring/v3/mutation_record_pb'
|
10
11
|
require 'google/protobuf/wrappers_pb'
|
11
12
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
12
13
|
add_file("google/monitoring/v3/notification.proto", :syntax => :proto3) do
|
@@ -28,6 +29,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
28
29
|
map :user_labels, :string, :string, 8
|
29
30
|
optional :verification_status, :enum, 9, "google.monitoring.v3.NotificationChannel.VerificationStatus"
|
30
31
|
optional :enabled, :message, 11, "google.protobuf.BoolValue"
|
32
|
+
optional :creation_record, :message, 12, "google.monitoring.v3.MutationRecord"
|
33
|
+
repeated :mutation_records, :message, 13, "google.monitoring.v3.MutationRecord"
|
31
34
|
end
|
32
35
|
add_enum "google.monitoring.v3.NotificationChannel.VerificationStatus" do
|
33
36
|
value :VERIFICATION_STATUS_UNSPECIFIED, 0
|
@@ -40,6 +40,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
40
40
|
add_message "google.monitoring.v3.ListNotificationChannelsResponse" do
|
41
41
|
repeated :notification_channels, :message, 3, "google.monitoring.v3.NotificationChannel"
|
42
42
|
optional :next_page_token, :string, 2
|
43
|
+
optional :total_size, :int32, 4
|
43
44
|
end
|
44
45
|
add_message "google.monitoring.v3.GetNotificationChannelRequest" do
|
45
46
|
optional :name, :string, 3
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/monitoring/v3/query_service.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
require 'google/api/label_pb'
|
8
|
+
require 'google/monitoring/v3/metric_pb'
|
9
|
+
require 'google/monitoring/v3/metric_service_pb'
|
10
|
+
require 'google/api/client_pb'
|
11
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
12
|
+
add_file("google/monitoring/v3/query_service.proto", :syntax => :proto3) do
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
module Google
|
17
|
+
module Cloud
|
18
|
+
module Monitoring
|
19
|
+
module V3
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,47 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# Source: google/monitoring/v3/query_service.proto for package 'Google.Cloud.Monitoring.V3'
|
3
|
+
# Original file comments:
|
4
|
+
# Copyright 2021 Google LLC
|
5
|
+
#
|
6
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
7
|
+
# you may not use this file except in compliance with the License.
|
8
|
+
# You may obtain a copy of the License at
|
9
|
+
#
|
10
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
11
|
+
#
|
12
|
+
# Unless required by applicable law or agreed to in writing, software
|
13
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
+
# See the License for the specific language governing permissions and
|
16
|
+
# limitations under the License.
|
17
|
+
#
|
18
|
+
|
19
|
+
require 'grpc'
|
20
|
+
require 'google/monitoring/v3/query_service_pb'
|
21
|
+
|
22
|
+
module Google
|
23
|
+
module Cloud
|
24
|
+
module Monitoring
|
25
|
+
module V3
|
26
|
+
module QueryService
|
27
|
+
# The QueryService API is used to manage time series data in Stackdriver
|
28
|
+
# Monitoring. Time series data is a collection of data points that describes
|
29
|
+
# the time-varying values of a metric.
|
30
|
+
class Service
|
31
|
+
|
32
|
+
include GRPC::GenericService
|
33
|
+
|
34
|
+
self.marshal_class_method = :encode
|
35
|
+
self.unmarshal_class_method = :decode
|
36
|
+
self.service_name = 'google.monitoring.v3.QueryService'
|
37
|
+
|
38
|
+
# Queries time series using Monitoring Query Language. This method does not require a Workspace.
|
39
|
+
rpc :QueryTimeSeries, ::Google::Cloud::Monitoring::V3::QueryTimeSeriesRequest, ::Google::Cloud::Monitoring::V3::QueryTimeSeriesResponse
|
40
|
+
end
|
41
|
+
|
42
|
+
Stub = Service.rpc_stub_class
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
@@ -3,7 +3,6 @@
|
|
3
3
|
|
4
4
|
require 'google/protobuf'
|
5
5
|
|
6
|
-
require 'google/api/monitored_resource_pb'
|
7
6
|
require 'google/api/resource_pb'
|
8
7
|
require 'google/protobuf/duration_pb'
|
9
8
|
require 'google/protobuf/timestamp_pb'
|
@@ -20,6 +19,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
20
19
|
optional :cloud_endpoints, :message, 8, "google.monitoring.v3.Service.CloudEndpoints"
|
21
20
|
optional :cluster_istio, :message, 9, "google.monitoring.v3.Service.ClusterIstio"
|
22
21
|
optional :mesh_istio, :message, 10, "google.monitoring.v3.Service.MeshIstio"
|
22
|
+
optional :istio_canonical_service, :message, 11, "google.monitoring.v3.Service.IstioCanonicalService"
|
23
23
|
end
|
24
24
|
end
|
25
25
|
add_message "google.monitoring.v3.Service.Custom" do
|
@@ -41,6 +41,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
41
41
|
optional :service_namespace, :string, 3
|
42
42
|
optional :service_name, :string, 4
|
43
43
|
end
|
44
|
+
add_message "google.monitoring.v3.Service.IstioCanonicalService" do
|
45
|
+
optional :mesh_uid, :string, 1
|
46
|
+
optional :canonical_service_namespace, :string, 3
|
47
|
+
optional :canonical_service, :string, 4
|
48
|
+
end
|
44
49
|
add_message "google.monitoring.v3.Service.Telemetry" do
|
45
50
|
optional :resource_name, :string, 1
|
46
51
|
end
|
@@ -132,6 +137,7 @@ module Google
|
|
132
137
|
Service::CloudEndpoints = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Service.CloudEndpoints").msgclass
|
133
138
|
Service::ClusterIstio = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Service.ClusterIstio").msgclass
|
134
139
|
Service::MeshIstio = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Service.MeshIstio").msgclass
|
140
|
+
Service::IstioCanonicalService = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Service.IstioCanonicalService").msgclass
|
135
141
|
Service::Telemetry = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Service.Telemetry").msgclass
|
136
142
|
ServiceLevelObjective = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.ServiceLevelObjective").msgclass
|
137
143
|
ServiceLevelObjective::View = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.ServiceLevelObjective.View").enummodule
|
@@ -168,6 +168,10 @@ module Google
|
|
168
168
|
# @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::MetricAbsence]
|
169
169
|
# A condition that checks that a time series continues to
|
170
170
|
# receive new data points.
|
171
|
+
# @!attribute [rw] condition_monitoring_query_language
|
172
|
+
# @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::MonitoringQueryLanguageCondition]
|
173
|
+
# A condition that uses the Monitoring Query Language to define
|
174
|
+
# alerts.
|
171
175
|
class Condition
|
172
176
|
include ::Google::Protobuf::MessageExts
|
173
177
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -191,16 +195,16 @@ module Google
|
|
191
195
|
# against a threshold.
|
192
196
|
# @!attribute [rw] filter
|
193
197
|
# @return [::String]
|
194
|
-
# A [filter](https://cloud.google.com/monitoring/api/v3/filters) that
|
198
|
+
# Required. A [filter](https://cloud.google.com/monitoring/api/v3/filters) that
|
195
199
|
# identifies which time series should be compared with the threshold.
|
196
200
|
#
|
197
201
|
# The filter is similar to the one that is specified in the
|
198
202
|
# [`ListTimeSeries`
|
199
203
|
# request](https://cloud.google.com/monitoring/api/ref_v3/rest/v3/projects.timeSeries/list)
|
200
204
|
# (that call is useful to verify the time series that will be retrieved /
|
201
|
-
# processed)
|
202
|
-
#
|
203
|
-
# This field
|
205
|
+
# processed). The filter must specify the metric type and the resource
|
206
|
+
# type. Optionally, it can specify resource labels and metric labels.
|
207
|
+
# This field must not exceed 2048 Unicode characters in length.
|
204
208
|
# @!attribute [rw] aggregations
|
205
209
|
# @return [::Array<::Google::Cloud::Monitoring::V3::Aggregation>]
|
206
210
|
# Specifies the alignment of data points in individual time series as
|
@@ -280,16 +284,16 @@ module Google
|
|
280
284
|
# resource does not include any data in the specified `duration`.
|
281
285
|
# @!attribute [rw] filter
|
282
286
|
# @return [::String]
|
283
|
-
# A [filter](https://cloud.google.com/monitoring/api/v3/filters) that
|
287
|
+
# Required. A [filter](https://cloud.google.com/monitoring/api/v3/filters) that
|
284
288
|
# identifies which time series should be compared with the threshold.
|
285
289
|
#
|
286
290
|
# The filter is similar to the one that is specified in the
|
287
291
|
# [`ListTimeSeries`
|
288
292
|
# request](https://cloud.google.com/monitoring/api/ref_v3/rest/v3/projects.timeSeries/list)
|
289
293
|
# (that call is useful to verify the time series that will be retrieved /
|
290
|
-
# processed)
|
291
|
-
#
|
292
|
-
# This field
|
294
|
+
# processed). The filter must specify the metric type and the resource
|
295
|
+
# type. Optionally, it can specify resource labels and metric labels.
|
296
|
+
# This field must not exceed 2048 Unicode characters in length.
|
293
297
|
# @!attribute [rw] aggregations
|
294
298
|
# @return [::Array<::Google::Cloud::Monitoring::V3::Aggregation>]
|
295
299
|
# Specifies the alignment of data points in individual time series as
|
@@ -306,9 +310,10 @@ module Google
|
|
306
310
|
# @!attribute [rw] duration
|
307
311
|
# @return [::Google::Protobuf::Duration]
|
308
312
|
# The amount of time that a time series must fail to report new
|
309
|
-
# data to be considered failing.
|
310
|
-
# are a multiple of a
|
311
|
-
#
|
313
|
+
# data to be considered failing. The minimum value of this field
|
314
|
+
# is 120 seconds. Larger values that are a multiple of a
|
315
|
+
# minute--for example, 240 or 300 seconds--are supported.
|
316
|
+
# If an invalid value is given, an
|
312
317
|
# error will be returned. The `Duration.nanos` field is
|
313
318
|
# ignored.
|
314
319
|
# @!attribute [rw] trigger
|
@@ -321,6 +326,37 @@ module Google
|
|
321
326
|
include ::Google::Protobuf::MessageExts
|
322
327
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
323
328
|
end
|
329
|
+
|
330
|
+
# A condition type that allows alert policies to be defined using
|
331
|
+
# [Monitoring Query Language](https://cloud.google.com/monitoring/mql).
|
332
|
+
# @!attribute [rw] query
|
333
|
+
# @return [::String]
|
334
|
+
# [Monitoring Query Language](https://cloud.google.com/monitoring/mql)
|
335
|
+
# query that outputs a boolean stream.
|
336
|
+
# @!attribute [rw] duration
|
337
|
+
# @return [::Google::Protobuf::Duration]
|
338
|
+
# The amount of time that a time series must violate the
|
339
|
+
# threshold to be considered failing. Currently, only values
|
340
|
+
# that are a multiple of a minute--e.g., 0, 60, 120, or 300
|
341
|
+
# seconds--are supported. If an invalid value is given, an
|
342
|
+
# error will be returned. When choosing a duration, it is useful to
|
343
|
+
# keep in mind the frequency of the underlying time series data
|
344
|
+
# (which may also be affected by any alignments specified in the
|
345
|
+
# `aggregations` field); a good duration is long enough so that a single
|
346
|
+
# outlier does not generate spurious alerts, but short enough that
|
347
|
+
# unhealthy states are detected and alerted on quickly.
|
348
|
+
# @!attribute [rw] trigger
|
349
|
+
# @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::Trigger]
|
350
|
+
# The number/percent of time series for which the comparison must hold
|
351
|
+
# in order for the condition to trigger. If unspecified, then the
|
352
|
+
# condition will trigger if the comparison is true for any of the
|
353
|
+
# time series that have been identified by `filter` and `aggregations`,
|
354
|
+
# or by the ratio, if `denominator_filter` and `denominator_aggregations`
|
355
|
+
# are specified.
|
356
|
+
class MonitoringQueryLanguageCondition
|
357
|
+
include ::Google::Protobuf::MessageExts
|
358
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
359
|
+
end
|
324
360
|
end
|
325
361
|
|
326
362
|
# @!attribute [rw] key
|