google-cloud-monitoring-v3 1.1.0 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,88 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2024 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Api
22
+ # Rich semantic information of an API field beyond basic typing.
23
+ # @!attribute [rw] format
24
+ # @return [::Google::Api::FieldInfo::Format]
25
+ # The standard format of a field value. This does not explicitly configure
26
+ # any API consumer, just documents the API's format for the field it is
27
+ # applied to.
28
+ # @!attribute [rw] referenced_types
29
+ # @return [::Array<::Google::Api::TypeReference>]
30
+ # The type(s) that the annotated, generic field may represent.
31
+ #
32
+ # Currently, this must only be used on fields of type `google.protobuf.Any`.
33
+ # Supporting other generic types may be considered in the future.
34
+ class FieldInfo
35
+ include ::Google::Protobuf::MessageExts
36
+ extend ::Google::Protobuf::MessageExts::ClassMethods
37
+
38
+ # The standard format of a field value. The supported formats are all backed
39
+ # by either an RFC defined by the IETF or a Google-defined AIP.
40
+ module Format
41
+ # Default, unspecified value.
42
+ FORMAT_UNSPECIFIED = 0
43
+
44
+ # Universally Unique Identifier, version 4, value as defined by
45
+ # https://datatracker.ietf.org/doc/html/rfc4122. The value may be
46
+ # normalized to entirely lowercase letters. For example, the value
47
+ # `F47AC10B-58CC-0372-8567-0E02B2C3D479` would be normalized to
48
+ # `f47ac10b-58cc-0372-8567-0e02b2c3d479`.
49
+ UUID4 = 1
50
+
51
+ # Internet Protocol v4 value as defined by [RFC
52
+ # 791](https://datatracker.ietf.org/doc/html/rfc791). The value may be
53
+ # condensed, with leading zeros in each octet stripped. For example,
54
+ # `001.022.233.040` would be condensed to `1.22.233.40`.
55
+ IPV4 = 2
56
+
57
+ # Internet Protocol v6 value as defined by [RFC
58
+ # 2460](https://datatracker.ietf.org/doc/html/rfc2460). The value may be
59
+ # normalized to entirely lowercase letters with zeros compressed, following
60
+ # [RFC 5952](https://datatracker.ietf.org/doc/html/rfc5952). For example,
61
+ # the value `2001:0DB8:0::0` would be normalized to `2001:db8::`.
62
+ IPV6 = 3
63
+
64
+ # An IP address in either v4 or v6 format as described by the individual
65
+ # values defined herein. See the comments on the IPV4 and IPV6 types for
66
+ # allowed normalizations of each.
67
+ IPV4_OR_IPV6 = 4
68
+ end
69
+ end
70
+
71
+ # A reference to a message type, for use in {::Google::Api::FieldInfo FieldInfo}.
72
+ # @!attribute [rw] type_name
73
+ # @return [::String]
74
+ # The name of the type that the annotated, generic field may represent.
75
+ # If the type is in the same protobuf package, the value can be the simple
76
+ # message name e.g., `"MyMessage"`. Otherwise, the value must be the
77
+ # fully-qualified message name e.g., `"google.library.v1.Book"`.
78
+ #
79
+ # If the type(s) are unknown to the service (e.g. the field accepts generic
80
+ # user input), use the wildcard `"*"` to denote this behavior.
81
+ #
82
+ # See [AIP-202](https://google.aip.dev/202#type-references) for more details.
83
+ class TypeReference
84
+ include ::Google::Protobuf::MessageExts
85
+ extend ::Google::Protobuf::MessageExts::ClassMethods
86
+ end
87
+ end
88
+ end
@@ -240,6 +240,9 @@ module Google
240
240
  # @!attribute [rw] condition_prometheus_query_language
241
241
  # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::PrometheusQueryLanguageCondition]
242
242
  # A condition that uses the Prometheus query language to define alerts.
243
+ # @!attribute [rw] condition_sql
244
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition]
245
+ # A condition that periodically evaluates a SQL query result.
243
246
  class Condition
244
247
  include ::Google::Protobuf::MessageExts
245
248
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -585,6 +588,17 @@ module Google
585
588
  # [valid Prometheus label
586
589
  # name](https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels).
587
590
  # This field may not exceed 2048 Unicode characters in length.
591
+ # @!attribute [rw] disable_metric_validation
592
+ # @return [::Boolean]
593
+ # Optional. Whether to disable metric existence validation for this
594
+ # condition.
595
+ #
596
+ # This allows alerting policies to be defined on metrics that do not yet
597
+ # exist, improving advanced customer workflows such as configuring
598
+ # alerting policies using Terraform.
599
+ #
600
+ # Users with the `monitoring.alertPolicyViewer` role are able to see the
601
+ # name of the non-existent metric in the alerting policy condition.
588
602
  class PrometheusQueryLanguageCondition
589
603
  include ::Google::Protobuf::MessageExts
590
604
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -599,6 +613,113 @@ module Google
599
613
  end
600
614
  end
601
615
 
616
+ # A condition that allows alerting policies to be defined using GoogleSQL.
617
+ # SQL conditions examine a sliding window of logs using GoogleSQL.
618
+ # Alert policies with SQL conditions may incur additional billing.
619
+ # @!attribute [rw] query
620
+ # @return [::String]
621
+ # Required. The Log Analytics SQL query to run, as a string. The query
622
+ # must conform to the required shape. Specifically, the query must not
623
+ # try to filter the input by time. A filter will automatically be
624
+ # applied to filter the input so that the query receives all rows
625
+ # received since the last time the query was run.
626
+ #
627
+ # For example, the following query extracts all log entries containing an
628
+ # HTTP request:
629
+ #
630
+ # SELECT
631
+ # timestamp, log_name, severity, http_request, resource, labels
632
+ # FROM
633
+ # my-project.global._Default._AllLogs
634
+ # WHERE
635
+ # http_request IS NOT NULL
636
+ # @!attribute [rw] minutes
637
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition::Minutes]
638
+ # Schedule the query to execute every so many minutes.
639
+ # @!attribute [rw] hourly
640
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition::Hourly]
641
+ # Schedule the query to execute every so many hours.
642
+ # @!attribute [rw] daily
643
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition::Daily]
644
+ # Schedule the query to execute every so many days.
645
+ # @!attribute [rw] row_count_test
646
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition::RowCountTest]
647
+ # Test the row count against a threshold.
648
+ # @!attribute [rw] boolean_test
649
+ # @return [::Google::Cloud::Monitoring::V3::AlertPolicy::Condition::SqlCondition::BooleanTest]
650
+ # Test the boolean value in the indicated column.
651
+ class SqlCondition
652
+ include ::Google::Protobuf::MessageExts
653
+ extend ::Google::Protobuf::MessageExts::ClassMethods
654
+
655
+ # Used to schedule the query to run every so many minutes.
656
+ # @!attribute [rw] periodicity
657
+ # @return [::Integer]
658
+ # Required. Number of minutes between runs. The interval must be
659
+ # greater than or equal to 5 minutes and less than or equal to 1440
660
+ # minutes.
661
+ class Minutes
662
+ include ::Google::Protobuf::MessageExts
663
+ extend ::Google::Protobuf::MessageExts::ClassMethods
664
+ end
665
+
666
+ # Used to schedule the query to run every so many hours.
667
+ # @!attribute [rw] periodicity
668
+ # @return [::Integer]
669
+ # Required. The number of hours between runs. Must be greater than or
670
+ # equal to 1 hour and less than or equal to 48 hours.
671
+ # @!attribute [rw] minute_offset
672
+ # @return [::Integer]
673
+ # Optional. The number of minutes after the hour (in UTC) to run the
674
+ # query. Must be greater than or equal to 0 minutes and less than or
675
+ # equal to 59 minutes. If left unspecified, then an arbitrary offset
676
+ # is used.
677
+ class Hourly
678
+ include ::Google::Protobuf::MessageExts
679
+ extend ::Google::Protobuf::MessageExts::ClassMethods
680
+ end
681
+
682
+ # Used to schedule the query to run every so many days.
683
+ # @!attribute [rw] periodicity
684
+ # @return [::Integer]
685
+ # Required. The number of days between runs. Must be greater than or
686
+ # equal to 1 day and less than or equal to 31 days.
687
+ # @!attribute [rw] execution_time
688
+ # @return [::Google::Type::TimeOfDay]
689
+ # Optional. The time of day (in UTC) at which the query should run. If
690
+ # left unspecified, the server picks an arbitrary time of day and runs
691
+ # the query at the same time each day.
692
+ class Daily
693
+ include ::Google::Protobuf::MessageExts
694
+ extend ::Google::Protobuf::MessageExts::ClassMethods
695
+ end
696
+
697
+ # A test that checks if the number of rows in the result set
698
+ # violates some threshold.
699
+ # @!attribute [rw] comparison
700
+ # @return [::Google::Cloud::Monitoring::V3::ComparisonType]
701
+ # Required. The comparison to apply between the number of rows returned
702
+ # by the query and the threshold.
703
+ # @!attribute [rw] threshold
704
+ # @return [::Integer]
705
+ # Required. The value against which to compare the row count.
706
+ class RowCountTest
707
+ include ::Google::Protobuf::MessageExts
708
+ extend ::Google::Protobuf::MessageExts::ClassMethods
709
+ end
710
+
711
+ # A test that uses an alerting result in a boolean column produced by
712
+ # the SQL query.
713
+ # @!attribute [rw] column
714
+ # @return [::String]
715
+ # Required. The name of the column containing the boolean value. If the
716
+ # value in a row is NULL, that row is ignored.
717
+ class BooleanTest
718
+ include ::Google::Protobuf::MessageExts
719
+ extend ::Google::Protobuf::MessageExts::ClassMethods
720
+ end
721
+ end
722
+
602
723
  # A condition control that determines how metric-threshold conditions
603
724
  # are evaluated when data stops arriving.
604
725
  # This control doesn't affect metric-absence policies.
@@ -93,7 +93,14 @@ module Google
93
93
  # @return [::String]
94
94
  # The units in which the metric value is reported. It is only applicable
95
95
  # if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
96
- # defines the representation of the stored metric values.
96
+ # defines the representation of the stored metric values. This field can only
97
+ # be changed through CreateTimeSeries when it is empty.
98
+ # @!attribute [rw] description
99
+ # @return [::String]
100
+ # Input only. A detailed description of the time series that will be
101
+ # associated with the
102
+ # {::Google::Api::MetricDescriptor google.api.MetricDescriptor} for the metric.
103
+ # Once set, this field cannot be changed through CreateTimeSeries.
97
104
  class TimeSeries
98
105
  include ::Google::Protobuf::MessageExts
99
106
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -89,7 +89,7 @@ module Google
89
89
  # projects/[PROJECT_ID_OR_NUMBER]
90
90
  # @!attribute [rw] filter
91
91
  # @return [::String]
92
- # If this field is empty, all custom and
92
+ # Optional. If this field is empty, all custom and
93
93
  # system-defined metric descriptors are returned.
94
94
  # Otherwise, the [filter](https://cloud.google.com/monitoring/api/v3/filters)
95
95
  # specifies which metric descriptors are to be
@@ -99,14 +99,15 @@ module Google
99
99
  # metric.type = starts_with("custom.googleapis.com/")
100
100
  # @!attribute [rw] page_size
101
101
  # @return [::Integer]
102
- # A positive number that is the maximum number of results to return. The
103
- # default and maximum value is 10,000. If a page_size <= 0 or > 10,000 is
104
- # submitted, will instead return a maximum of 10,000 results.
102
+ # Optional. A positive number that is the maximum number of results to
103
+ # return. The default and maximum value is 10,000. If a page_size <= 0 or >
104
+ # 10,000 is submitted, will instead return a maximum of 10,000 results.
105
105
  # @!attribute [rw] page_token
106
106
  # @return [::String]
107
- # If this field is not empty then it must contain the `nextPageToken` value
108
- # returned by a previous call to this method. Using this field causes the
109
- # method to return additional results from the previous method call.
107
+ # Optional. If this field is not empty then it must contain the
108
+ # `nextPageToken` value returned by a previous call to this method. Using
109
+ # this field causes the method to return additional results from the previous
110
+ # method call.
110
111
  class ListMetricDescriptorsRequest
111
112
  include ::Google::Protobuf::MessageExts
112
113
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -334,7 +335,10 @@ module Google
334
335
  end
335
336
  end
336
337
 
337
- # The `QueryTimeSeries` request.
338
+ # The `QueryTimeSeries` request. For information about the status of
339
+ # Monitoring Query Language (MQL), see the [MQL deprecation
340
+ # notice](https://cloud.google.com/stackdriver/docs/deprecations/mql).
341
+ # @deprecated This message is deprecated and may be removed in the next major version update.
338
342
  # @!attribute [rw] name
339
343
  # @return [::String]
340
344
  # Required. The
@@ -360,7 +364,10 @@ module Google
360
364
  extend ::Google::Protobuf::MessageExts::ClassMethods
361
365
  end
362
366
 
363
- # The `QueryTimeSeries` response.
367
+ # The `QueryTimeSeries` response. For information about the status of
368
+ # Monitoring Query Language (MQL), see the [MQL deprecation
369
+ # notice](https://cloud.google.com/stackdriver/docs/deprecations/mql).
370
+ # @deprecated This message is deprecated and may be removed in the next major version update.
364
371
  # @!attribute [rw] time_series_descriptor
365
372
  # @return [::Google::Cloud::Monitoring::V3::TimeSeriesDescriptor]
366
373
  # The descriptor for the time series data.
@@ -351,7 +351,7 @@ module Google
351
351
  # @!attribute [rw] goal
352
352
  # @return [::Float]
353
353
  # The fraction of service that must be good in order for this objective to be
354
- # met. `0 < goal <= 0.999`.
354
+ # met. `0 < goal <= 0.9999`.
355
355
  # @!attribute [rw] rolling_period
356
356
  # @return [::Google::Protobuf::Duration]
357
357
  # A rolling time period, semantically "in the past `<rolling_period>`".
@@ -379,10 +379,11 @@ module Google
379
379
  end
380
380
  end
381
381
 
382
- # Contains information needed for generating an
382
+ # Contains information needed for generating either an
383
383
  # [OpenID Connect
384
- # token](https://developers.google.com/identity/protocols/OpenIDConnect).
385
- # The OIDC token will be generated for the Monitoring service agent service
384
+ # token](https://developers.google.com/identity/protocols/OpenIDConnect) or
385
+ # [OAuth token](https://developers.google.com/identity/protocols/oauth2).
386
+ # The token will be generated for the Monitoring service agent service
386
387
  # account.
387
388
  # @!attribute [rw] type
388
389
  # @return [::Google::Cloud::Monitoring::V3::UptimeCheckConfig::HttpCheck::ServiceAgentAuthentication::ServiceAgentAuthenticationType]
@@ -0,0 +1,45 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2024 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Type
22
+ # Represents a time of day. The date and time zone are either not significant
23
+ # or are specified elsewhere. An API may choose to allow leap seconds. Related
24
+ # types are [google.type.Date][google.type.Date] and
25
+ # `google.protobuf.Timestamp`.
26
+ # @!attribute [rw] hours
27
+ # @return [::Integer]
28
+ # Hours of day in 24 hour format. Should be from 0 to 23. An API may choose
29
+ # to allow the value "24:00:00" for scenarios like business closing time.
30
+ # @!attribute [rw] minutes
31
+ # @return [::Integer]
32
+ # Minutes of hour of day. Must be from 0 to 59.
33
+ # @!attribute [rw] seconds
34
+ # @return [::Integer]
35
+ # Seconds of minutes of the time. Must normally be from 0 to 59. An API may
36
+ # allow the value 60 if it allows leap-seconds.
37
+ # @!attribute [rw] nanos
38
+ # @return [::Integer]
39
+ # Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.
40
+ class TimeOfDay
41
+ include ::Google::Protobuf::MessageExts
42
+ extend ::Google::Protobuf::MessageExts::ClassMethods
43
+ end
44
+ end
45
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-monitoring-v3
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-05 00:00:00.000000000 Z
11
+ date: 2025-01-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common
@@ -16,7 +16,7 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 0.21.1
19
+ version: 0.24.0
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 2.a
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
- version: 0.21.1
29
+ version: 0.24.0
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 2.a
@@ -123,6 +123,7 @@ files:
123
123
  - proto_docs/google/api/client.rb
124
124
  - proto_docs/google/api/distribution.rb
125
125
  - proto_docs/google/api/field_behavior.rb
126
+ - proto_docs/google/api/field_info.rb
126
127
  - proto_docs/google/api/label.rb
127
128
  - proto_docs/google/api/launch_stage.rb
128
129
  - proto_docs/google/api/metric.rb
@@ -155,6 +156,7 @@ files:
155
156
  - proto_docs/google/protobuf/wrappers.rb
156
157
  - proto_docs/google/rpc/status.rb
157
158
  - proto_docs/google/type/calendar_period.rb
159
+ - proto_docs/google/type/timeofday.rb
158
160
  homepage: https://github.com/googleapis/google-cloud-ruby
159
161
  licenses:
160
162
  - Apache-2.0