diff --git a/go.mod b/go.mod index 92402b4580..3c13ee32aa 100644 --- a/go.mod +++ b/go.mod @@ -6,7 +6,7 @@ require ( cloud.google.com/go/auth v0.23.3 cloud.google.com/go/compute/metadata v0.9.1 cloud.google.com/go/logging v1.19.1 - cloud.google.com/go/monitoring v1.30.0 + cloud.google.com/go/monitoring v1.31.0 cloud.google.com/go/trace v1.16.0 github.com/GoogleContainerTools/kpt-functions-catalog/functions/go/set-namespace v0.4.1-0.20220713210718-d955e7d3a800 github.com/GoogleContainerTools/kpt-functions-sdk/go/fn v0.0.0-20220706221933-7181f451a663 diff --git a/go.sum b/go.sum index b726e523b0..3139e66fb1 100644 --- a/go.sum +++ b/go.sum @@ -17,8 +17,8 @@ cloud.google.com/go/logging v1.19.1 h1:7SsLhyTDBDrJw+Ll6Ns3I2mByqHXvJUc3rGjSlwiW cloud.google.com/go/logging v1.19.1/go.mod h1:2IkQ/d8jVJqV2qW8ZUGUiMjdZG1gkLD2JReGbZ8isqg= cloud.google.com/go/longrunning v1.2.0 h1:WjYH3YHBGCxGJP9M4dWGHBfXr/cFIjMkNgWcJj7/iMM= cloud.google.com/go/longrunning v1.2.0/go.mod h1:5KMQALFGOCtFoi2xSOA1u3H7WKlhmckgiyFw7+LGQp0= -cloud.google.com/go/monitoring v1.30.0 h1:r/d+JUbyKmJ8b07iznuKfzVzrIXTWxHQ3lBRm3x2LlY= -cloud.google.com/go/monitoring v1.30.0/go.mod h1:htlUR0QWVMrjFzZmN4LGnMAve9xB/eduwjmINxVZ8RM= +cloud.google.com/go/monitoring v1.31.0 h1:LCuAoYiq8snyL/eDAG/VC73uWFXeax8+YEfmoNGJUrY= +cloud.google.com/go/monitoring v1.31.0/go.mod h1:7uk2dIJIf7ra64dI1VuQ0ttoFqvtKjdzq46u6zNP1hU= cloud.google.com/go/storage v1.62.3 h1:SZq1t23NCI+e96dH77Dg3PEfsNNEjqO8zE5AnD8gVD0= cloud.google.com/go/storage v1.62.3/go.mod h1:cpYz/kRVZ+UQAF1uHeea10/9ewcRbxGoGNKsS9daSXA= cloud.google.com/go/trace v1.16.0 h1:GmQovzFc5F0CNfl0VLgL64aoTtu7xsM0YajW2GlG9+E= diff --git a/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary.go b/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary.go index 556cce7975..3aa6f108d5 100644 --- a/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary.go +++ b/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary.go @@ -17,12 +17,21 @@ package monitoring import ( + "iter" + monitoringpb "cloud.google.com/go/monitoring/apiv3/v2/monitoringpb" + gaxiter "github.com/googleapis/gax-go/v2/iterator" "google.golang.org/api/iterator" metricpb "google.golang.org/genproto/googleapis/api/metric" monitoredrespb "google.golang.org/genproto/googleapis/api/monitoredres" ) +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *AlertPolicyIterator) All() iter.Seq2[*monitoringpb.AlertPolicy, error] { + return gaxiter.RangeAdapter(it.Next) +} + // AlertPolicyIterator manages a stream of *monitoringpb.AlertPolicy. type AlertPolicyIterator struct { items []*monitoringpb.AlertPolicy @@ -70,6 +79,12 @@ func (it *AlertPolicyIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *GroupIterator) All() iter.Seq2[*monitoringpb.Group, error] { + return gaxiter.RangeAdapter(it.Next) +} + // GroupIterator manages a stream of *monitoringpb.Group. type GroupIterator struct { items []*monitoringpb.Group @@ -117,6 +132,12 @@ func (it *GroupIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *MetricDescriptorIterator) All() iter.Seq2[*metricpb.MetricDescriptor, error] { + return gaxiter.RangeAdapter(it.Next) +} + // MetricDescriptorIterator manages a stream of *metricpb.MetricDescriptor. type MetricDescriptorIterator struct { items []*metricpb.MetricDescriptor @@ -164,6 +185,12 @@ func (it *MetricDescriptorIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *MonitoredResourceDescriptorIterator) All() iter.Seq2[*monitoredrespb.MonitoredResourceDescriptor, error] { + return gaxiter.RangeAdapter(it.Next) +} + // MonitoredResourceDescriptorIterator manages a stream of *monitoredrespb.MonitoredResourceDescriptor. type MonitoredResourceDescriptorIterator struct { items []*monitoredrespb.MonitoredResourceDescriptor @@ -211,6 +238,12 @@ func (it *MonitoredResourceDescriptorIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *MonitoredResourceIterator) All() iter.Seq2[*monitoredrespb.MonitoredResource, error] { + return gaxiter.RangeAdapter(it.Next) +} + // MonitoredResourceIterator manages a stream of *monitoredrespb.MonitoredResource. type MonitoredResourceIterator struct { items []*monitoredrespb.MonitoredResource @@ -258,6 +291,12 @@ func (it *MonitoredResourceIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *NotificationChannelDescriptorIterator) All() iter.Seq2[*monitoringpb.NotificationChannelDescriptor, error] { + return gaxiter.RangeAdapter(it.Next) +} + // NotificationChannelDescriptorIterator manages a stream of *monitoringpb.NotificationChannelDescriptor. type NotificationChannelDescriptorIterator struct { items []*monitoringpb.NotificationChannelDescriptor @@ -305,6 +344,12 @@ func (it *NotificationChannelDescriptorIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *NotificationChannelIterator) All() iter.Seq2[*monitoringpb.NotificationChannel, error] { + return gaxiter.RangeAdapter(it.Next) +} + // NotificationChannelIterator manages a stream of *monitoringpb.NotificationChannel. type NotificationChannelIterator struct { items []*monitoringpb.NotificationChannel @@ -352,6 +397,12 @@ func (it *NotificationChannelIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *ServiceIterator) All() iter.Seq2[*monitoringpb.Service, error] { + return gaxiter.RangeAdapter(it.Next) +} + // ServiceIterator manages a stream of *monitoringpb.Service. type ServiceIterator struct { items []*monitoringpb.Service @@ -399,6 +450,12 @@ func (it *ServiceIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *ServiceLevelObjectiveIterator) All() iter.Seq2[*monitoringpb.ServiceLevelObjective, error] { + return gaxiter.RangeAdapter(it.Next) +} + // ServiceLevelObjectiveIterator manages a stream of *monitoringpb.ServiceLevelObjective. type ServiceLevelObjectiveIterator struct { items []*monitoringpb.ServiceLevelObjective @@ -446,6 +503,12 @@ func (it *ServiceLevelObjectiveIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *SnoozeIterator) All() iter.Seq2[*monitoringpb.Snooze, error] { + return gaxiter.RangeAdapter(it.Next) +} + // SnoozeIterator manages a stream of *monitoringpb.Snooze. type SnoozeIterator struct { items []*monitoringpb.Snooze @@ -493,6 +556,12 @@ func (it *SnoozeIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *TimeSeriesDataIterator) All() iter.Seq2[*monitoringpb.TimeSeriesData, error] { + return gaxiter.RangeAdapter(it.Next) +} + // TimeSeriesDataIterator manages a stream of *monitoringpb.TimeSeriesData. type TimeSeriesDataIterator struct { items []*monitoringpb.TimeSeriesData @@ -540,6 +609,12 @@ func (it *TimeSeriesDataIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *TimeSeriesIterator) All() iter.Seq2[*monitoringpb.TimeSeries, error] { + return gaxiter.RangeAdapter(it.Next) +} + // TimeSeriesIterator manages a stream of *monitoringpb.TimeSeries. type TimeSeriesIterator struct { items []*monitoringpb.TimeSeries @@ -587,6 +662,12 @@ func (it *TimeSeriesIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *UptimeCheckConfigIterator) All() iter.Seq2[*monitoringpb.UptimeCheckConfig, error] { + return gaxiter.RangeAdapter(it.Next) +} + // UptimeCheckConfigIterator manages a stream of *monitoringpb.UptimeCheckConfig. type UptimeCheckConfigIterator struct { items []*monitoringpb.UptimeCheckConfig @@ -634,6 +715,12 @@ func (it *UptimeCheckConfigIterator) takeBuf() interface{} { return b } +// All returns an iterator. If an error is returned by the iterator, the +// iterator will stop after that iteration. +func (it *UptimeCheckIpIterator) All() iter.Seq2[*monitoringpb.UptimeCheckIp, error] { + return gaxiter.RangeAdapter(it.Next) +} + // UptimeCheckIpIterator manages a stream of *monitoringpb.UptimeCheckIp. type UptimeCheckIpIterator struct { items []*monitoringpb.UptimeCheckIp diff --git a/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary_go123.go b/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary_go123.go deleted file mode 100644 index 4a028b9c93..0000000000 --- a/vendor/cloud.google.com/go/monitoring/apiv3/v2/auxiliary_go123.go +++ /dev/null @@ -1,112 +0,0 @@ -// Copyright 2026 Google LLC -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// https://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Code generated by protoc-gen-go_gapic. DO NOT EDIT. - -//go:build go1.23 - -package monitoring - -import ( - "iter" - - monitoringpb "cloud.google.com/go/monitoring/apiv3/v2/monitoringpb" - "github.com/googleapis/gax-go/v2/iterator" - metricpb "google.golang.org/genproto/googleapis/api/metric" - monitoredrespb "google.golang.org/genproto/googleapis/api/monitoredres" -) - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *AlertPolicyIterator) All() iter.Seq2[*monitoringpb.AlertPolicy, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *GroupIterator) All() iter.Seq2[*monitoringpb.Group, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *MetricDescriptorIterator) All() iter.Seq2[*metricpb.MetricDescriptor, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *MonitoredResourceDescriptorIterator) All() iter.Seq2[*monitoredrespb.MonitoredResourceDescriptor, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *MonitoredResourceIterator) All() iter.Seq2[*monitoredrespb.MonitoredResource, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *NotificationChannelDescriptorIterator) All() iter.Seq2[*monitoringpb.NotificationChannelDescriptor, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *NotificationChannelIterator) All() iter.Seq2[*monitoringpb.NotificationChannel, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *ServiceIterator) All() iter.Seq2[*monitoringpb.Service, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *ServiceLevelObjectiveIterator) All() iter.Seq2[*monitoringpb.ServiceLevelObjective, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *SnoozeIterator) All() iter.Seq2[*monitoringpb.Snooze, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *TimeSeriesDataIterator) All() iter.Seq2[*monitoringpb.TimeSeriesData, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *TimeSeriesIterator) All() iter.Seq2[*monitoringpb.TimeSeries, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *UptimeCheckConfigIterator) All() iter.Seq2[*monitoringpb.UptimeCheckConfig, error] { - return iterator.RangeAdapter(it.Next) -} - -// All returns an iterator. If an error is returned by the iterator, the -// iterator will stop after that iteration. -func (it *UptimeCheckIpIterator) All() iter.Seq2[*monitoringpb.UptimeCheckIp, error] { - return iterator.RangeAdapter(it.Next) -} diff --git a/vendor/cloud.google.com/go/monitoring/internal/version.go b/vendor/cloud.google.com/go/monitoring/internal/version.go index efd522bbae..941648cb66 100644 --- a/vendor/cloud.google.com/go/monitoring/internal/version.go +++ b/vendor/cloud.google.com/go/monitoring/internal/version.go @@ -17,4 +17,4 @@ package internal // Version is the current tagged release of the library. -const Version = "1.30.0" +const Version = "1.31.0" diff --git a/vendor/modules.txt b/vendor/modules.txt index a59e82da40..5c7f1f043f 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -48,8 +48,8 @@ cloud.google.com/go/longrunning cloud.google.com/go/longrunning/autogen cloud.google.com/go/longrunning/autogen/longrunningpb cloud.google.com/go/longrunning/internal -# cloud.google.com/go/monitoring v1.30.0 -## explicit; go 1.25.0 +# cloud.google.com/go/monitoring v1.31.0 +## explicit; go 1.26.0 cloud.google.com/go/monitoring/apiv3/v2 cloud.google.com/go/monitoring/apiv3/v2/monitoringpb cloud.google.com/go/monitoring/internal