google-cloud-monitoring-v3 0.4.0 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +8 -8
- data/README.md +1 -1
- data/lib/google/cloud/monitoring/v3/alert_policy_service/client.rb +52 -56
- data/lib/google/cloud/monitoring/v3/alert_policy_service/paths.rb +14 -0
- data/lib/google/cloud/monitoring/v3/group_service/client.rb +58 -66
- data/lib/google/cloud/monitoring/v3/group_service/paths.rb +14 -0
- data/lib/google/cloud/monitoring/v3/metric_service/client.rb +72 -77
- data/lib/google/cloud/monitoring/v3/notification_channel_service/client.rb +75 -79
- data/lib/google/cloud/monitoring/v3/notification_channel_service/paths.rb +14 -0
- data/lib/google/cloud/monitoring/v3/query_service/client.rb +35 -39
- data/lib/google/cloud/monitoring/v3/service_monitoring_service/client.rb +70 -73
- data/lib/google/cloud/monitoring/v3/service_monitoring_service/paths.rb +14 -0
- data/lib/google/cloud/monitoring/v3/uptime_check_service/client.rb +56 -61
- data/lib/google/cloud/monitoring/v3/uptime_check_service/paths.rb +14 -0
- data/lib/google/cloud/monitoring/v3/version.rb +1 -1
- data/lib/google/monitoring/v3/alert_pb.rb +15 -0
- data/lib/google/monitoring/v3/common_pb.rb +0 -6
- data/lib/google/monitoring/v3/notification_pb.rb +0 -2
- data/lib/google/monitoring/v3/service_pb.rb +2 -0
- data/lib/google/monitoring/v3/uptime_service_pb.rb +1 -0
- data/proto_docs/google/api/distribution.rb +2 -2
- data/proto_docs/google/api/field_behavior.rb +7 -1
- data/proto_docs/google/api/launch_stage.rb +7 -1
- data/proto_docs/google/api/metric.rb +109 -36
- data/proto_docs/google/api/monitored_resource.rb +7 -6
- data/proto_docs/google/longrunning/operations.rb +164 -0
- data/proto_docs/google/monitoring/v3/alert.rb +66 -1
- data/proto_docs/google/monitoring/v3/alert_service.rb +4 -2
- data/proto_docs/google/monitoring/v3/common.rb +1 -13
- data/proto_docs/google/monitoring/v3/group_service.rb +4 -2
- data/proto_docs/google/monitoring/v3/metric.rb +3 -1
- data/proto_docs/google/monitoring/v3/metric_service.rb +13 -8
- data/proto_docs/google/monitoring/v3/notification.rb +0 -4
- data/proto_docs/google/monitoring/v3/notification_service.rb +8 -4
- data/proto_docs/google/monitoring/v3/service.rb +38 -6
- data/proto_docs/google/monitoring/v3/service_service.rb +4 -2
- data/proto_docs/google/monitoring/v3/span_context.rb +2 -2
- data/proto_docs/google/monitoring/v3/uptime.rb +5 -2
- data/proto_docs/google/monitoring/v3/uptime_service.rb +4 -2
- metadata +14 -7
@@ -48,13 +48,12 @@ module Google
|
|
48
48
|
# See {::Google::Cloud::Monitoring::V3::UptimeCheckService::Client::Configuration}
|
49
49
|
# for a description of the configuration fields.
|
50
50
|
#
|
51
|
-
#
|
51
|
+
# @example
|
52
52
|
#
|
53
|
-
#
|
54
|
-
#
|
55
|
-
#
|
56
|
-
#
|
57
|
-
# end
|
53
|
+
# # Modify the configuration for all UptimeCheckService clients
|
54
|
+
# ::Google::Cloud::Monitoring::V3::UptimeCheckService::Client.configure do |config|
|
55
|
+
# config.timeout = 10.0
|
56
|
+
# end
|
58
57
|
#
|
59
58
|
# @yield [config] Configure the Client client.
|
60
59
|
# @yieldparam config [Client::Configuration]
|
@@ -74,18 +73,12 @@ module Google
|
|
74
73
|
|
75
74
|
default_config.rpcs.list_uptime_check_configs.timeout = 30.0
|
76
75
|
default_config.rpcs.list_uptime_check_configs.retry_policy = {
|
77
|
-
initial_delay: 0.1,
|
78
|
-
max_delay: 30.0,
|
79
|
-
multiplier: 1.3,
|
80
|
-
retry_codes: [4, 14]
|
76
|
+
initial_delay: 0.1, max_delay: 30.0, multiplier: 1.3, retry_codes: [14]
|
81
77
|
}
|
82
78
|
|
83
79
|
default_config.rpcs.get_uptime_check_config.timeout = 30.0
|
84
80
|
default_config.rpcs.get_uptime_check_config.retry_policy = {
|
85
|
-
initial_delay: 0.1,
|
86
|
-
max_delay: 30.0,
|
87
|
-
multiplier: 1.3,
|
88
|
-
retry_codes: [4, 14]
|
81
|
+
initial_delay: 0.1, max_delay: 30.0, multiplier: 1.3, retry_codes: [14]
|
89
82
|
}
|
90
83
|
|
91
84
|
default_config.rpcs.create_uptime_check_config.timeout = 30.0
|
@@ -94,18 +87,12 @@ module Google
|
|
94
87
|
|
95
88
|
default_config.rpcs.delete_uptime_check_config.timeout = 30.0
|
96
89
|
default_config.rpcs.delete_uptime_check_config.retry_policy = {
|
97
|
-
initial_delay: 0.1,
|
98
|
-
max_delay: 30.0,
|
99
|
-
multiplier: 1.3,
|
100
|
-
retry_codes: [4, 14]
|
90
|
+
initial_delay: 0.1, max_delay: 30.0, multiplier: 1.3, retry_codes: [14]
|
101
91
|
}
|
102
92
|
|
103
93
|
default_config.rpcs.list_uptime_check_ips.timeout = 30.0
|
104
94
|
default_config.rpcs.list_uptime_check_ips.retry_policy = {
|
105
|
-
initial_delay: 0.1,
|
106
|
-
max_delay: 30.0,
|
107
|
-
multiplier: 1.3,
|
108
|
-
retry_codes: [4, 14]
|
95
|
+
initial_delay: 0.1, max_delay: 30.0, multiplier: 1.3, retry_codes: [14]
|
109
96
|
}
|
110
97
|
|
111
98
|
default_config
|
@@ -137,19 +124,15 @@ module Google
|
|
137
124
|
##
|
138
125
|
# Create a new UptimeCheckService client object.
|
139
126
|
#
|
140
|
-
#
|
141
|
-
#
|
142
|
-
# To create a new UptimeCheckService client with the default
|
143
|
-
# configuration:
|
127
|
+
# @example
|
144
128
|
#
|
145
|
-
#
|
129
|
+
# # Create a client using the default configuration
|
130
|
+
# client = ::Google::Cloud::Monitoring::V3::UptimeCheckService::Client.new
|
146
131
|
#
|
147
|
-
#
|
148
|
-
#
|
149
|
-
#
|
150
|
-
#
|
151
|
-
# config.timeout = 10.0
|
152
|
-
# end
|
132
|
+
# # Create a client using a custom configuration
|
133
|
+
# client = ::Google::Cloud::Monitoring::V3::UptimeCheckService::Client.new do |config|
|
134
|
+
# config.timeout = 10.0
|
135
|
+
# end
|
153
136
|
#
|
154
137
|
# @yield [config] Configure the UptimeCheckService client.
|
155
138
|
# @yieldparam config [Client::Configuration]
|
@@ -169,14 +152,13 @@ module Google
|
|
169
152
|
|
170
153
|
# Create credentials
|
171
154
|
credentials = @config.credentials
|
172
|
-
# Use self-signed JWT if the
|
155
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
173
156
|
# but only if the default endpoint does not have a region prefix.
|
174
|
-
enable_self_signed_jwt = @config.
|
175
|
-
@config.endpoint == Client.configure.endpoint &&
|
157
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
176
158
|
!@config.endpoint.split(".").first.include?("-")
|
177
159
|
credentials ||= Credentials.default scope: @config.scope,
|
178
160
|
enable_self_signed_jwt: enable_self_signed_jwt
|
179
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
161
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
180
162
|
credentials = Credentials.new credentials, scope: @config.scope
|
181
163
|
end
|
182
164
|
@quota_project_id = @config.quota_project
|
@@ -213,7 +195,8 @@ module Google
|
|
213
195
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
214
196
|
#
|
215
197
|
# @param parent [::String]
|
216
|
-
# Required. The project
|
198
|
+
# Required. The [project](https://cloud.google.com/monitoring/api/v3#project_name)
|
199
|
+
# whose Uptime check configurations are listed. The format is:
|
217
200
|
#
|
218
201
|
# projects/[PROJECT_ID_OR_NUMBER]
|
219
202
|
# @param page_size [::Integer]
|
@@ -260,7 +243,9 @@ module Google
|
|
260
243
|
options.apply_defaults timeout: @config.rpcs.list_uptime_check_configs.timeout,
|
261
244
|
metadata: metadata,
|
262
245
|
retry_policy: @config.rpcs.list_uptime_check_configs.retry_policy
|
263
|
-
|
246
|
+
|
247
|
+
options.apply_defaults timeout: @config.timeout,
|
248
|
+
metadata: @config.metadata,
|
264
249
|
retry_policy: @config.retry_policy
|
265
250
|
|
266
251
|
@uptime_check_service_stub.call_rpc :list_uptime_check_configs, request, options: options do |response, operation|
|
@@ -329,7 +314,9 @@ module Google
|
|
329
314
|
options.apply_defaults timeout: @config.rpcs.get_uptime_check_config.timeout,
|
330
315
|
metadata: metadata,
|
331
316
|
retry_policy: @config.rpcs.get_uptime_check_config.retry_policy
|
332
|
-
|
317
|
+
|
318
|
+
options.apply_defaults timeout: @config.timeout,
|
319
|
+
metadata: @config.metadata,
|
333
320
|
retry_policy: @config.retry_policy
|
334
321
|
|
335
322
|
@uptime_check_service_stub.call_rpc :get_uptime_check_config, request, options: options do |response, operation|
|
@@ -359,7 +346,8 @@ module Google
|
|
359
346
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
360
347
|
#
|
361
348
|
# @param parent [::String]
|
362
|
-
# Required. The project in
|
349
|
+
# Required. The [project](https://cloud.google.com/monitoring/api/v3#project_name) in
|
350
|
+
# which to create the Uptime check. The format is:
|
363
351
|
#
|
364
352
|
# projects/[PROJECT_ID_OR_NUMBER]
|
365
353
|
# @param uptime_check_config [::Google::Cloud::Monitoring::V3::UptimeCheckConfig, ::Hash]
|
@@ -399,7 +387,9 @@ module Google
|
|
399
387
|
options.apply_defaults timeout: @config.rpcs.create_uptime_check_config.timeout,
|
400
388
|
metadata: metadata,
|
401
389
|
retry_policy: @config.rpcs.create_uptime_check_config.retry_policy
|
402
|
-
|
390
|
+
|
391
|
+
options.apply_defaults timeout: @config.timeout,
|
392
|
+
metadata: @config.metadata,
|
403
393
|
retry_policy: @config.retry_policy
|
404
394
|
|
405
395
|
@uptime_check_service_stub.call_rpc :create_uptime_check_config, request, options: options do |response, operation|
|
@@ -483,7 +473,9 @@ module Google
|
|
483
473
|
options.apply_defaults timeout: @config.rpcs.update_uptime_check_config.timeout,
|
484
474
|
metadata: metadata,
|
485
475
|
retry_policy: @config.rpcs.update_uptime_check_config.retry_policy
|
486
|
-
|
476
|
+
|
477
|
+
options.apply_defaults timeout: @config.timeout,
|
478
|
+
metadata: @config.metadata,
|
487
479
|
retry_policy: @config.retry_policy
|
488
480
|
|
489
481
|
@uptime_check_service_stub.call_rpc :update_uptime_check_config, request, options: options do |response, operation|
|
@@ -553,7 +545,9 @@ module Google
|
|
553
545
|
options.apply_defaults timeout: @config.rpcs.delete_uptime_check_config.timeout,
|
554
546
|
metadata: metadata,
|
555
547
|
retry_policy: @config.rpcs.delete_uptime_check_config.retry_policy
|
556
|
-
|
548
|
+
|
549
|
+
options.apply_defaults timeout: @config.timeout,
|
550
|
+
metadata: @config.metadata,
|
557
551
|
retry_policy: @config.retry_policy
|
558
552
|
|
559
553
|
@uptime_check_service_stub.call_rpc :delete_uptime_check_config, request, options: options do |response, operation|
|
@@ -622,7 +616,9 @@ module Google
|
|
622
616
|
options.apply_defaults timeout: @config.rpcs.list_uptime_check_ips.timeout,
|
623
617
|
metadata: metadata,
|
624
618
|
retry_policy: @config.rpcs.list_uptime_check_ips.retry_policy
|
625
|
-
|
619
|
+
|
620
|
+
options.apply_defaults timeout: @config.timeout,
|
621
|
+
metadata: @config.metadata,
|
626
622
|
retry_policy: @config.retry_policy
|
627
623
|
|
628
624
|
@uptime_check_service_stub.call_rpc :list_uptime_check_ips, request, options: options do |response, operation|
|
@@ -647,22 +643,21 @@ module Google
|
|
647
643
|
# Configuration can be applied globally to all clients, or to a single client
|
648
644
|
# on construction.
|
649
645
|
#
|
650
|
-
#
|
651
|
-
#
|
652
|
-
#
|
653
|
-
# to 20 seconds,
|
654
|
-
#
|
655
|
-
#
|
656
|
-
#
|
657
|
-
#
|
658
|
-
#
|
659
|
-
#
|
660
|
-
#
|
661
|
-
#
|
662
|
-
#
|
663
|
-
#
|
664
|
-
#
|
665
|
-
# end
|
646
|
+
# @example
|
647
|
+
#
|
648
|
+
# # Modify the global config, setting the timeout for
|
649
|
+
# # list_uptime_check_configs to 20 seconds,
|
650
|
+
# # and all remaining timeouts to 10 seconds.
|
651
|
+
# ::Google::Cloud::Monitoring::V3::UptimeCheckService::Client.configure do |config|
|
652
|
+
# config.timeout = 10.0
|
653
|
+
# config.rpcs.list_uptime_check_configs.timeout = 20.0
|
654
|
+
# end
|
655
|
+
#
|
656
|
+
# # Apply the above configuration only to a new client.
|
657
|
+
# client = ::Google::Cloud::Monitoring::V3::UptimeCheckService::Client.new do |config|
|
658
|
+
# config.timeout = 10.0
|
659
|
+
# config.rpcs.list_uptime_check_configs.timeout = 20.0
|
660
|
+
# end
|
666
661
|
#
|
667
662
|
# @!attribute [rw] endpoint
|
668
663
|
# The hostname or hostname:port of the service endpoint.
|
@@ -52,6 +52,20 @@ 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
|
+
|
55
69
|
##
|
56
70
|
# Create a fully-qualified UptimeCheckConfig resource string.
|
57
71
|
#
|
@@ -24,6 +24,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
24
24
|
repeated :notification_channels, :string, 14
|
25
25
|
optional :creation_record, :message, 10, "google.monitoring.v3.MutationRecord"
|
26
26
|
optional :mutation_record, :message, 11, "google.monitoring.v3.MutationRecord"
|
27
|
+
optional :alert_strategy, :message, 21, "google.monitoring.v3.AlertPolicy.AlertStrategy"
|
27
28
|
end
|
28
29
|
add_message "google.monitoring.v3.AlertPolicy.Documentation" do
|
29
30
|
optional :content, :string, 1
|
@@ -35,6 +36,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
35
36
|
oneof :condition do
|
36
37
|
optional :condition_threshold, :message, 1, "google.monitoring.v3.AlertPolicy.Condition.MetricThreshold"
|
37
38
|
optional :condition_absent, :message, 2, "google.monitoring.v3.AlertPolicy.Condition.MetricAbsence"
|
39
|
+
optional :condition_matched_log, :message, 20, "google.monitoring.v3.AlertPolicy.Condition.LogMatch"
|
38
40
|
optional :condition_monitoring_query_language, :message, 19, "google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition"
|
39
41
|
end
|
40
42
|
end
|
@@ -60,11 +62,21 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
60
62
|
optional :duration, :message, 2, "google.protobuf.Duration"
|
61
63
|
optional :trigger, :message, 3, "google.monitoring.v3.AlertPolicy.Condition.Trigger"
|
62
64
|
end
|
65
|
+
add_message "google.monitoring.v3.AlertPolicy.Condition.LogMatch" do
|
66
|
+
optional :filter, :string, 1
|
67
|
+
map :label_extractors, :string, :string, 2
|
68
|
+
end
|
63
69
|
add_message "google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition" do
|
64
70
|
optional :query, :string, 1
|
65
71
|
optional :duration, :message, 2, "google.protobuf.Duration"
|
66
72
|
optional :trigger, :message, 3, "google.monitoring.v3.AlertPolicy.Condition.Trigger"
|
67
73
|
end
|
74
|
+
add_message "google.monitoring.v3.AlertPolicy.AlertStrategy" do
|
75
|
+
optional :notification_rate_limit, :message, 1, "google.monitoring.v3.AlertPolicy.AlertStrategy.NotificationRateLimit"
|
76
|
+
end
|
77
|
+
add_message "google.monitoring.v3.AlertPolicy.AlertStrategy.NotificationRateLimit" do
|
78
|
+
optional :period, :message, 1, "google.protobuf.Duration"
|
79
|
+
end
|
68
80
|
add_enum "google.monitoring.v3.AlertPolicy.ConditionCombinerType" do
|
69
81
|
value :COMBINE_UNSPECIFIED, 0
|
70
82
|
value :AND, 1
|
@@ -84,7 +96,10 @@ module Google
|
|
84
96
|
AlertPolicy::Condition::Trigger = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.Trigger").msgclass
|
85
97
|
AlertPolicy::Condition::MetricThreshold = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MetricThreshold").msgclass
|
86
98
|
AlertPolicy::Condition::MetricAbsence = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MetricAbsence").msgclass
|
99
|
+
AlertPolicy::Condition::LogMatch = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.LogMatch").msgclass
|
87
100
|
AlertPolicy::Condition::MonitoringQueryLanguageCondition = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.Condition.MonitoringQueryLanguageCondition").msgclass
|
101
|
+
AlertPolicy::AlertStrategy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.AlertStrategy").msgclass
|
102
|
+
AlertPolicy::AlertStrategy::NotificationRateLimit = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.AlertStrategy.NotificationRateLimit").msgclass
|
88
103
|
AlertPolicy::ConditionCombinerType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.AlertPolicy.ConditionCombinerType").enummodule
|
89
104
|
end
|
90
105
|
end
|
@@ -73,11 +73,6 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
73
73
|
value :COMPARISON_EQ, 5
|
74
74
|
value :COMPARISON_NE, 6
|
75
75
|
end
|
76
|
-
add_enum "google.monitoring.v3.ServiceTier" do
|
77
|
-
value :SERVICE_TIER_UNSPECIFIED, 0
|
78
|
-
value :SERVICE_TIER_BASIC, 1
|
79
|
-
value :SERVICE_TIER_PREMIUM, 2
|
80
|
-
end
|
81
76
|
end
|
82
77
|
end
|
83
78
|
|
@@ -91,7 +86,6 @@ module Google
|
|
91
86
|
Aggregation::Aligner = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Aggregation.Aligner").enummodule
|
92
87
|
Aggregation::Reducer = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.Aggregation.Reducer").enummodule
|
93
88
|
ComparisonType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.ComparisonType").enummodule
|
94
|
-
ServiceTier = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.monitoring.v3.ServiceTier").enummodule
|
95
89
|
end
|
96
90
|
end
|
97
91
|
end
|
@@ -6,7 +6,6 @@ require 'google/protobuf'
|
|
6
6
|
require 'google/api/label_pb'
|
7
7
|
require 'google/api/launch_stage_pb'
|
8
8
|
require 'google/api/resource_pb'
|
9
|
-
require 'google/monitoring/v3/common_pb'
|
10
9
|
require 'google/monitoring/v3/mutation_record_pb'
|
11
10
|
require 'google/protobuf/wrappers_pb'
|
12
11
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
@@ -17,7 +16,6 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
17
16
|
optional :display_name, :string, 2
|
18
17
|
optional :description, :string, 3
|
19
18
|
repeated :labels, :message, 4, "google.api.LabelDescriptor"
|
20
|
-
repeated :supported_tiers, :enum, 5, "google.monitoring.v3.ServiceTier"
|
21
19
|
optional :launch_stage, :enum, 7, "google.api.LaunchStage"
|
22
20
|
end
|
23
21
|
add_message "google.monitoring.v3.NotificationChannel" do
|
@@ -13,6 +13,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
13
13
|
optional :name, :string, 1
|
14
14
|
optional :display_name, :string, 2
|
15
15
|
optional :telemetry, :message, 13, "google.monitoring.v3.Service.Telemetry"
|
16
|
+
map :user_labels, :string, :string, 14
|
16
17
|
oneof :identifier do
|
17
18
|
optional :custom, :message, 6, "google.monitoring.v3.Service.Custom"
|
18
19
|
optional :app_engine, :message, 7, "google.monitoring.v3.Service.AppEngine"
|
@@ -54,6 +55,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
54
55
|
optional :display_name, :string, 11
|
55
56
|
optional :service_level_indicator, :message, 3, "google.monitoring.v3.ServiceLevelIndicator"
|
56
57
|
optional :goal, :double, 4
|
58
|
+
map :user_labels, :string, :string, 12
|
57
59
|
oneof :period do
|
58
60
|
optional :rolling_period, :message, 5, "google.protobuf.Duration"
|
59
61
|
optional :calendar_period, :enum, 6, "google.type.CalendarPeriod"
|
@@ -7,6 +7,7 @@ require 'google/api/annotations_pb'
|
|
7
7
|
require 'google/api/client_pb'
|
8
8
|
require 'google/api/field_behavior_pb'
|
9
9
|
require 'google/api/resource_pb'
|
10
|
+
require 'google/longrunning/operations_pb'
|
10
11
|
require 'google/monitoring/v3/uptime_pb'
|
11
12
|
require 'google/protobuf/duration_pb'
|
12
13
|
require 'google/protobuf/empty_pb'
|
@@ -49,7 +49,7 @@ module Google
|
|
49
49
|
#
|
50
50
|
# Sum[i=1..n]((x_i - mean)^2)
|
51
51
|
#
|
52
|
-
# Knuth, "The Art of Computer Programming", Vol. 2, page
|
52
|
+
# Knuth, "The Art of Computer Programming", Vol. 2, page 232, 3rd edition
|
53
53
|
# describes Welford's method for accumulating this sum in one pass.
|
54
54
|
#
|
55
55
|
# If `count` is zero then this field must be zero.
|
@@ -207,7 +207,7 @@ module Google
|
|
207
207
|
# @return [::Array<::Google::Protobuf::Any>]
|
208
208
|
# Contextual information about the example value. Examples are:
|
209
209
|
#
|
210
|
-
# Trace
|
210
|
+
# Trace: type.googleapis.com/google.monitoring.v3.SpanContext
|
211
211
|
#
|
212
212
|
# Literal string: type.googleapis.com/google.protobuf.StringValue
|
213
213
|
#
|
@@ -57,9 +57,15 @@ module Google
|
|
57
57
|
|
58
58
|
# Denotes that a (repeated) field is an unordered list.
|
59
59
|
# This indicates that the service may provide the elements of the list
|
60
|
-
# in any arbitrary
|
60
|
+
# in any arbitrary order, rather than the order the user originally
|
61
61
|
# provided. Additionally, the list's order may or may not be stable.
|
62
62
|
UNORDERED_LIST = 6
|
63
|
+
|
64
|
+
# Denotes that this field returns a non-empty default value if not set.
|
65
|
+
# This indicates that if the user provides the empty value in a request,
|
66
|
+
# a non-empty value will be returned. The user will not be aware of what
|
67
|
+
# non-empty value to expect.
|
68
|
+
NON_EMPTY_DEFAULT = 7
|
63
69
|
end
|
64
70
|
end
|
65
71
|
end
|
@@ -25,6 +25,12 @@ module Google
|
|
25
25
|
# Do not use this default value.
|
26
26
|
LAUNCH_STAGE_UNSPECIFIED = 0
|
27
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
|
+
|
28
34
|
# Early Access features are limited to a closed group of testers. To use
|
29
35
|
# these features, you must sign up in advance and sign a Trusted Tester
|
30
36
|
# agreement (which includes confidentiality provisions). These features may
|
@@ -36,7 +42,7 @@ module Google
|
|
36
42
|
# for widespread use. By Alpha, all significant design issues are resolved
|
37
43
|
# and we are in the process of verifying functionality. Alpha customers
|
38
44
|
# need to apply for access, agree to applicable terms, and have their
|
39
|
-
# projects
|
45
|
+
# projects allowlisted. Alpha releases don’t have to be feature complete,
|
40
46
|
# no SLAs are provided, and there are no technical support obligations, but
|
41
47
|
# they will be far enough along that customers can actually use them in
|
42
48
|
# test environments or for limited-use tests -- just like they would in
|
@@ -28,11 +28,12 @@ module Google
|
|
28
28
|
# @!attribute [rw] type
|
29
29
|
# @return [::String]
|
30
30
|
# The metric type, including its DNS name prefix. The type is not
|
31
|
-
# URL-encoded.
|
32
|
-
# `custom.googleapis.com`.
|
33
|
-
# grouping. For example:
|
31
|
+
# URL-encoded. All user-defined metric types have the DNS name
|
32
|
+
# `custom.googleapis.com` or `external.googleapis.com`. Metric types should
|
33
|
+
# use a natural hierarchical grouping. For example:
|
34
34
|
#
|
35
35
|
# "custom.googleapis.com/invoice/paid/amount"
|
36
|
+
# "external.googleapis.com/prometheus/up"
|
36
37
|
# "appengine.googleapis.com/http/server/response_latencies"
|
37
38
|
# @!attribute [rw] labels
|
38
39
|
# @return [::Array<::Google::Api::LabelDescriptor>]
|
@@ -52,10 +53,28 @@ module Google
|
|
52
53
|
# Some combinations of `metric_kind` and `value_type` might not be supported.
|
53
54
|
# @!attribute [rw] unit
|
54
55
|
# @return [::String]
|
55
|
-
# The
|
56
|
-
# if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The
|
57
|
-
#
|
58
|
-
#
|
56
|
+
# The units in which the metric value is reported. It is only applicable
|
57
|
+
# if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
|
58
|
+
# defines the representation of the stored metric values.
|
59
|
+
#
|
60
|
+
# Different systems might scale the values to be more easily displayed (so a
|
61
|
+
# value of `0.02kBy` _might_ be displayed as `20By`, and a value of
|
62
|
+
# `3523kBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is
|
63
|
+
# `kBy`, then the value of the metric is always in thousands of bytes, no
|
64
|
+
# matter how it might be displayed.
|
65
|
+
#
|
66
|
+
# If you want a custom metric to record the exact number of CPU-seconds used
|
67
|
+
# by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is
|
68
|
+
# `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005
|
69
|
+
# CPU-seconds, then the value is written as `12005`.
|
70
|
+
#
|
71
|
+
# Alternatively, if you want a custom metric to record data in a more
|
72
|
+
# granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is
|
73
|
+
# `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`),
|
74
|
+
# or use `Kis{CPU}` and write `11.723` (which is `12005/1024`).
|
75
|
+
#
|
76
|
+
# The supported units are a subset of [The Unified Code for Units of
|
77
|
+
# Measure](https://unitsofmeasure.org/ucum.html) standard:
|
59
78
|
#
|
60
79
|
# **Basic units (UNIT)**
|
61
80
|
#
|
@@ -65,36 +84,44 @@ module Google
|
|
65
84
|
# * `min` minute
|
66
85
|
# * `h` hour
|
67
86
|
# * `d` day
|
87
|
+
# * `1` dimensionless
|
68
88
|
#
|
69
89
|
# **Prefixes (PREFIX)**
|
70
90
|
#
|
71
|
-
# * `k` kilo (10
|
72
|
-
# * `M` mega (10
|
73
|
-
# * `G` giga (10
|
74
|
-
# * `T` tera (10
|
75
|
-
# * `P` peta (10
|
76
|
-
# * `E` exa (10
|
77
|
-
# * `Z` zetta (10
|
78
|
-
# * `Y` yotta (10
|
79
|
-
#
|
80
|
-
# * `
|
81
|
-
# * `
|
82
|
-
# * `
|
83
|
-
# * `
|
84
|
-
# * `
|
85
|
-
# * `
|
86
|
-
# * `
|
87
|
-
# * `
|
88
|
-
#
|
89
|
-
# * `
|
90
|
-
# * `
|
91
|
+
# * `k` kilo (10^3)
|
92
|
+
# * `M` mega (10^6)
|
93
|
+
# * `G` giga (10^9)
|
94
|
+
# * `T` tera (10^12)
|
95
|
+
# * `P` peta (10^15)
|
96
|
+
# * `E` exa (10^18)
|
97
|
+
# * `Z` zetta (10^21)
|
98
|
+
# * `Y` yotta (10^24)
|
99
|
+
#
|
100
|
+
# * `m` milli (10^-3)
|
101
|
+
# * `u` micro (10^-6)
|
102
|
+
# * `n` nano (10^-9)
|
103
|
+
# * `p` pico (10^-12)
|
104
|
+
# * `f` femto (10^-15)
|
105
|
+
# * `a` atto (10^-18)
|
106
|
+
# * `z` zepto (10^-21)
|
107
|
+
# * `y` yocto (10^-24)
|
108
|
+
#
|
109
|
+
# * `Ki` kibi (2^10)
|
110
|
+
# * `Mi` mebi (2^20)
|
111
|
+
# * `Gi` gibi (2^30)
|
112
|
+
# * `Ti` tebi (2^40)
|
113
|
+
# * `Pi` pebi (2^50)
|
91
114
|
#
|
92
115
|
# **Grammar**
|
93
116
|
#
|
94
117
|
# The grammar also includes these connectors:
|
95
118
|
#
|
96
|
-
# * `/` division (as an infix operator
|
97
|
-
#
|
119
|
+
# * `/` division or ratio (as an infix operator). For examples,
|
120
|
+
# `kBy/{email}` or `MiBy/10ms` (although you should almost never
|
121
|
+
# have `/s` in a metric `unit`; rates should always be computed at
|
122
|
+
# query time from the underlying cumulative or delta value).
|
123
|
+
# * `.` multiplication or composition (as an infix operator). For
|
124
|
+
# examples, `GBy.d` or `k{watt}.h`.
|
98
125
|
#
|
99
126
|
# The grammar for a unit is as follows:
|
100
127
|
#
|
@@ -109,14 +136,25 @@ module Google
|
|
109
136
|
#
|
110
137
|
# Notes:
|
111
138
|
#
|
112
|
-
# * `Annotation` is just a comment if it follows a `UNIT
|
113
|
-
#
|
114
|
-
# `{
|
139
|
+
# * `Annotation` is just a comment if it follows a `UNIT`. If the annotation
|
140
|
+
# is used alone, then the unit is equivalent to `1`. For examples,
|
141
|
+
# `{request}/s == 1/s`, `By{transmitted}/s == By/s`.
|
115
142
|
# * `NAME` is a sequence of non-blank printable ASCII characters not
|
116
|
-
# containing
|
117
|
-
# * `1` represents
|
118
|
-
#
|
119
|
-
#
|
143
|
+
# containing `{` or `}`.
|
144
|
+
# * `1` represents a unitary [dimensionless
|
145
|
+
# unit](https://en.wikipedia.org/wiki/Dimensionless_quantity) of 1, such
|
146
|
+
# as in `1/s`. It is typically used when none of the basic units are
|
147
|
+
# appropriate. For example, "new users per day" can be represented as
|
148
|
+
# `1/d` or `{new-users}/d` (and a metric value `5` would mean "5 new
|
149
|
+
# users). Alternatively, "thousands of page views per day" would be
|
150
|
+
# represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric
|
151
|
+
# value of `5.3` would mean "5300 page views per day").
|
152
|
+
# * `%` represents dimensionless value of 1/100, and annotates values giving
|
153
|
+
# a percentage (so the metric values are typically in the range of 0..100,
|
154
|
+
# and a metric value `3` means "3 percent").
|
155
|
+
# * `10^2.%` indicates a metric contains a ratio, typically in the range
|
156
|
+
# 0..1, that will be multiplied by 100 and displayed as a percentage
|
157
|
+
# (so a metric value `0.03` means "3 percent").
|
120
158
|
# @!attribute [rw] description
|
121
159
|
# @return [::String]
|
122
160
|
# A detailed description of the metric, which can be used in documentation.
|
@@ -126,11 +164,46 @@ module Google
|
|
126
164
|
# Use sentence case without an ending period, for example "Request count".
|
127
165
|
# This field is optional but it is recommended to be set for any metrics
|
128
166
|
# associated with user-visible concepts, such as Quota.
|
167
|
+
# @!attribute [rw] metadata
|
168
|
+
# @return [::Google::Api::MetricDescriptor::MetricDescriptorMetadata]
|
169
|
+
# Optional. Metadata which can be used to guide usage of the metric.
|
170
|
+
# @!attribute [rw] launch_stage
|
171
|
+
# @return [::Google::Api::LaunchStage]
|
172
|
+
# Optional. The launch stage of the metric definition.
|
173
|
+
# @!attribute [rw] monitored_resource_types
|
174
|
+
# @return [::Array<::String>]
|
175
|
+
# Read-only. If present, then a [time
|
176
|
+
# series][google.monitoring.v3.TimeSeries], which is identified partially by
|
177
|
+
# a metric type and a {::Google::Api::MonitoredResourceDescriptor MonitoredResourceDescriptor}, that is associated
|
178
|
+
# with this metric type can only be associated with one of the monitored
|
179
|
+
# resource types listed here.
|
129
180
|
class MetricDescriptor
|
130
181
|
include ::Google::Protobuf::MessageExts
|
131
182
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
132
183
|
|
184
|
+
# Additional annotations that can be used to guide the usage of a metric.
|
185
|
+
# @!attribute [rw] launch_stage
|
186
|
+
# @return [::Google::Api::LaunchStage]
|
187
|
+
# Deprecated. Must use the {::Google::Api::MetricDescriptor#launch_stage MetricDescriptor.launch_stage} instead.
|
188
|
+
# @!attribute [rw] sample_period
|
189
|
+
# @return [::Google::Protobuf::Duration]
|
190
|
+
# The sampling period of metric data points. For metrics which are written
|
191
|
+
# periodically, consecutive data points are stored at this time interval,
|
192
|
+
# excluding data loss due to errors. Metrics with a higher granularity have
|
193
|
+
# a smaller sampling period.
|
194
|
+
# @!attribute [rw] ingest_delay
|
195
|
+
# @return [::Google::Protobuf::Duration]
|
196
|
+
# The delay of data points caused by ingestion. Data points older than this
|
197
|
+
# age are guaranteed to be ingested and available to be read, excluding
|
198
|
+
# data loss due to errors.
|
199
|
+
class MetricDescriptorMetadata
|
200
|
+
include ::Google::Protobuf::MessageExts
|
201
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
202
|
+
end
|
203
|
+
|
133
204
|
# The kind of measurement. It describes how the data is reported.
|
205
|
+
# For information on setting the start time and end time based on
|
206
|
+
# the MetricKind, see {::Google::Cloud::Monitoring::V3::TimeInterval TimeInterval}.
|
134
207
|
module MetricKind
|
135
208
|
# Do not use this default value.
|
136
209
|
METRIC_KIND_UNSPECIFIED = 0
|