lib/google/monitoring/v3/service_pb.rb in google-cloud-monitoring-v3-0.11.0 vs lib/google/monitoring/v3/service_pb.rb in google-cloud-monitoring-v3-0.12.0

- old
+ new

@@ -1,133 +1,40 @@ +# frozen_string_literal: true # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/monitoring/v3/service.proto require 'google/protobuf' require 'google/api/resource_pb' require 'google/protobuf/duration_pb' require 'google/type/calendar_period_pb' -Google::Protobuf::DescriptorPool.generated_pool.build do - add_file("google/monitoring/v3/service.proto", :syntax => :proto3) do - add_message "google.monitoring.v3.Service" do - optional :name, :string, 1 - optional :display_name, :string, 2 - optional :telemetry, :message, 13, "google.monitoring.v3.Service.Telemetry" - map :user_labels, :string, :string, 14 - oneof :identifier do - optional :custom, :message, 6, "google.monitoring.v3.Service.Custom" - optional :app_engine, :message, 7, "google.monitoring.v3.Service.AppEngine" - optional :cloud_endpoints, :message, 8, "google.monitoring.v3.Service.CloudEndpoints" - optional :cluster_istio, :message, 9, "google.monitoring.v3.Service.ClusterIstio" - optional :mesh_istio, :message, 10, "google.monitoring.v3.Service.MeshIstio" - optional :istio_canonical_service, :message, 11, "google.monitoring.v3.Service.IstioCanonicalService" - end + +descriptor_data = "\n\"google/monitoring/v3/service.proto\x12\x14google.monitoring.v3\x1a\x19google/api/resource.proto\x1a\x1egoogle/protobuf/duration.proto\x1a!google/type/calendar_period.proto\"\xc9\t\n\x07Service\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0c\x64isplay_name\x18\x02 \x01(\t\x12\x36\n\x06\x63ustom\x18\x06 \x01(\x0b\x32$.google.monitoring.v3.Service.CustomH\x00\x12=\n\napp_engine\x18\x07 \x01(\x0b\x32\'.google.monitoring.v3.Service.AppEngineH\x00\x12G\n\x0f\x63loud_endpoints\x18\x08 \x01(\x0b\x32,.google.monitoring.v3.Service.CloudEndpointsH\x00\x12\x43\n\rcluster_istio\x18\t \x01(\x0b\x32*.google.monitoring.v3.Service.ClusterIstioH\x00\x12=\n\nmesh_istio\x18\n \x01(\x0b\x32\'.google.monitoring.v3.Service.MeshIstioH\x00\x12V\n\x17istio_canonical_service\x18\x0b \x01(\x0b\x32\x33.google.monitoring.v3.Service.IstioCanonicalServiceH\x00\x12:\n\ttelemetry\x18\r \x01(\x0b\x32\'.google.monitoring.v3.Service.Telemetry\x12\x42\n\x0buser_labels\x18\x0e \x03(\x0b\x32-.google.monitoring.v3.Service.UserLabelsEntry\x1a\x08\n\x06\x43ustom\x1a\x1e\n\tAppEngine\x12\x11\n\tmodule_id\x18\x01 \x01(\t\x1a!\n\x0e\x43loudEndpoints\x12\x0f\n\x07service\x18\x01 \x01(\t\x1ag\n\x0c\x43lusterIstio\x12\x10\n\x08location\x18\x01 \x01(\t\x12\x14\n\x0c\x63luster_name\x18\x02 \x01(\t\x12\x19\n\x11service_namespace\x18\x03 \x01(\t\x12\x14\n\x0cservice_name\x18\x04 \x01(\t\x1aN\n\tMeshIstio\x12\x10\n\x08mesh_uid\x18\x01 \x01(\t\x12\x19\n\x11service_namespace\x18\x03 \x01(\t\x12\x14\n\x0cservice_name\x18\x04 \x01(\t\x1ai\n\x15IstioCanonicalService\x12\x10\n\x08mesh_uid\x18\x01 \x01(\t\x12#\n\x1b\x63\x61nonical_service_namespace\x18\x03 \x01(\t\x12\x19\n\x11\x63\x61nonical_service\x18\x04 \x01(\t\x1a\"\n\tTelemetry\x12\x15\n\rresource_name\x18\x01 \x01(\t\x1a\x31\n\x0fUserLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xa7\x01\xea\x41\xa3\x01\n!monitoring.googleapis.com/Service\x12%projects/{project}/services/{service}\x12/organizations/{organization}/services/{service}\x12#folders/{folder}/services/{service}\x12\x01*B\x0c\n\nidentifier\"\x96\x06\n\x15ServiceLevelObjective\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0c\x64isplay_name\x18\x0b \x01(\t\x12L\n\x17service_level_indicator\x18\x03 \x01(\x0b\x32+.google.monitoring.v3.ServiceLevelIndicator\x12\x0c\n\x04goal\x18\x04 \x01(\x01\x12\x33\n\x0erolling_period\x18\x05 \x01(\x0b\x32\x19.google.protobuf.DurationH\x00\x12\x36\n\x0f\x63\x61lendar_period\x18\x06 \x01(\x0e\x32\x1b.google.type.CalendarPeriodH\x00\x12P\n\x0buser_labels\x18\x0c \x03(\x0b\x32;.google.monitoring.v3.ServiceLevelObjective.UserLabelsEntry\x1a\x31\n\x0fUserLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"4\n\x04View\x12\x14\n\x10VIEW_UNSPECIFIED\x10\x00\x12\x08\n\x04\x46ULL\x10\x02\x12\x0c\n\x08\x45XPLICIT\x10\x01:\xca\x02\xea\x41\xc6\x02\n/monitoring.googleapis.com/ServiceLevelObjective\x12Vprojects/{project}/services/{service}/serviceLevelObjectives/{service_level_objective}\x12`organizations/{organization}/services/{service}/serviceLevelObjectives/{service_level_objective}\x12Tfolders/{folder}/services/{service}/serviceLevelObjectives/{service_level_objective}\x12\x01* \x01\x42\x08\n\x06period\"\xd4\x01\n\x15ServiceLevelIndicator\x12\x33\n\tbasic_sli\x18\x04 \x01(\x0b\x32\x1e.google.monitoring.v3.BasicSliH\x00\x12>\n\rrequest_based\x18\x01 \x01(\x0b\x32%.google.monitoring.v3.RequestBasedSliH\x00\x12>\n\rwindows_based\x18\x02 \x01(\x0b\x32%.google.monitoring.v3.WindowsBasedSliH\x00\x42\x06\n\x04type\"\xb6\x02\n\x08\x42\x61sicSli\x12\x0e\n\x06method\x18\x07 \x03(\t\x12\x10\n\x08location\x18\x08 \x03(\t\x12\x0f\n\x07version\x18\t \x03(\t\x12K\n\x0c\x61vailability\x18\x02 \x01(\x0b\x32\x33.google.monitoring.v3.BasicSli.AvailabilityCriteriaH\x00\x12\x41\n\x07latency\x18\x03 \x01(\x0b\x32..google.monitoring.v3.BasicSli.LatencyCriteriaH\x00\x1a\x16\n\x14\x41vailabilityCriteria\x1a?\n\x0fLatencyCriteria\x12,\n\tthreshold\x18\x03 \x01(\x0b\x32\x19.google.protobuf.DurationB\x0e\n\x0csli_criteria\"!\n\x05Range\x12\x0b\n\x03min\x18\x01 \x01(\x01\x12\x0b\n\x03max\x18\x02 \x01(\x01\"\xa1\x01\n\x0fRequestBasedSli\x12\x41\n\x10good_total_ratio\x18\x01 \x01(\x0b\x32%.google.monitoring.v3.TimeSeriesRatioH\x00\x12\x41\n\x10\x64istribution_cut\x18\x03 \x01(\x0b\x32%.google.monitoring.v3.DistributionCutH\x00\x42\x08\n\x06method\"h\n\x0fTimeSeriesRatio\x12\x1b\n\x13good_service_filter\x18\x04 \x01(\t\x12\x1a\n\x12\x62\x61\x64_service_filter\x18\x05 \x01(\t\x12\x1c\n\x14total_service_filter\x18\x06 \x01(\t\"Z\n\x0f\x44istributionCut\x12\x1b\n\x13\x64istribution_filter\x18\x04 \x01(\t\x12*\n\x05range\x18\x05 \x01(\x0b\x32\x1b.google.monitoring.v3.Range\"\x83\x05\n\x0fWindowsBasedSli\x12 \n\x16good_bad_metric_filter\x18\x05 \x01(\tH\x00\x12`\n\x1agood_total_ratio_threshold\x18\x02 \x01(\x0b\x32:.google.monitoring.v3.WindowsBasedSli.PerformanceThresholdH\x00\x12Q\n\x14metric_mean_in_range\x18\x06 \x01(\x0b\x32\x31.google.monitoring.v3.WindowsBasedSli.MetricRangeH\x00\x12P\n\x13metric_sum_in_range\x18\x07 \x01(\x0b\x32\x31.google.monitoring.v3.WindowsBasedSli.MetricRangeH\x00\x12\x30\n\rwindow_period\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x1a\xb0\x01\n\x14PerformanceThreshold\x12<\n\x0bperformance\x18\x01 \x01(\x0b\x32%.google.monitoring.v3.RequestBasedSliH\x00\x12?\n\x15\x62\x61sic_sli_performance\x18\x03 \x01(\x0b\x32\x1e.google.monitoring.v3.BasicSliH\x00\x12\x11\n\tthreshold\x18\x02 \x01(\x01\x42\x06\n\x04type\x1aN\n\x0bMetricRange\x12\x13\n\x0btime_series\x18\x01 \x01(\t\x12*\n\x05range\x18\x04 \x01(\x0b\x32\x1b.google.monitoring.v3.RangeB\x12\n\x10window_criterionB\xd1\x01\n\x18\x63om.google.monitoring.v3B\x16ServiceMonitoringProtoP\x01ZAcloud.google.com/go/monitoring/apiv3/v2/monitoringpb;monitoringpb\xaa\x02\x1aGoogle.Cloud.Monitoring.V3\xca\x02\x1aGoogle\\Cloud\\Monitoring\\V3\xea\x02\x1dGoogle::Cloud::Monitoring::V3b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError => e + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Duration", "google/protobuf/duration.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" end - add_message "google.monitoring.v3.Service.Custom" do - end - add_message "google.monitoring.v3.Service.AppEngine" do - optional :module_id, :string, 1 - end - add_message "google.monitoring.v3.Service.CloudEndpoints" do - optional :service, :string, 1 - end - add_message "google.monitoring.v3.Service.ClusterIstio" do - optional :location, :string, 1 - optional :cluster_name, :string, 2 - optional :service_namespace, :string, 3 - optional :service_name, :string, 4 - end - add_message "google.monitoring.v3.Service.MeshIstio" do - optional :mesh_uid, :string, 1 - optional :service_namespace, :string, 3 - optional :service_name, :string, 4 - end - add_message "google.monitoring.v3.Service.IstioCanonicalService" do - optional :mesh_uid, :string, 1 - optional :canonical_service_namespace, :string, 3 - optional :canonical_service, :string, 4 - end - add_message "google.monitoring.v3.Service.Telemetry" do - optional :resource_name, :string, 1 - end - add_message "google.monitoring.v3.ServiceLevelObjective" do - optional :name, :string, 1 - optional :display_name, :string, 11 - optional :service_level_indicator, :message, 3, "google.monitoring.v3.ServiceLevelIndicator" - optional :goal, :double, 4 - map :user_labels, :string, :string, 12 - oneof :period do - optional :rolling_period, :message, 5, "google.protobuf.Duration" - optional :calendar_period, :enum, 6, "google.type.CalendarPeriod" - end - end - add_enum "google.monitoring.v3.ServiceLevelObjective.View" do - value :VIEW_UNSPECIFIED, 0 - value :FULL, 2 - value :EXPLICIT, 1 - end - add_message "google.monitoring.v3.ServiceLevelIndicator" do - oneof :type do - optional :basic_sli, :message, 4, "google.monitoring.v3.BasicSli" - optional :request_based, :message, 1, "google.monitoring.v3.RequestBasedSli" - optional :windows_based, :message, 2, "google.monitoring.v3.WindowsBasedSli" - end - end - add_message "google.monitoring.v3.BasicSli" do - repeated :method, :string, 7 - repeated :location, :string, 8 - repeated :version, :string, 9 - oneof :sli_criteria do - optional :availability, :message, 2, "google.monitoring.v3.BasicSli.AvailabilityCriteria" - optional :latency, :message, 3, "google.monitoring.v3.BasicSli.LatencyCriteria" - end - end - add_message "google.monitoring.v3.BasicSli.AvailabilityCriteria" do - end - add_message "google.monitoring.v3.BasicSli.LatencyCriteria" do - optional :threshold, :message, 3, "google.protobuf.Duration" - end - add_message "google.monitoring.v3.Range" do - optional :min, :double, 1 - optional :max, :double, 2 - end - add_message "google.monitoring.v3.RequestBasedSli" do - oneof :method do - optional :good_total_ratio, :message, 1, "google.monitoring.v3.TimeSeriesRatio" - optional :distribution_cut, :message, 3, "google.monitoring.v3.DistributionCut" - end - end - add_message "google.monitoring.v3.TimeSeriesRatio" do - optional :good_service_filter, :string, 4 - optional :bad_service_filter, :string, 5 - optional :total_service_filter, :string, 6 - end - add_message "google.monitoring.v3.DistributionCut" do - optional :distribution_filter, :string, 4 - optional :range, :message, 5, "google.monitoring.v3.Range" - end - add_message "google.monitoring.v3.WindowsBasedSli" do - optional :window_period, :message, 4, "google.protobuf.Duration" - oneof :window_criterion do - optional :good_bad_metric_filter, :string, 5 - optional :good_total_ratio_threshold, :message, 2, "google.monitoring.v3.WindowsBasedSli.PerformanceThreshold" - optional :metric_mean_in_range, :message, 6, "google.monitoring.v3.WindowsBasedSli.MetricRange" - optional :metric_sum_in_range, :message, 7, "google.monitoring.v3.WindowsBasedSli.MetricRange" - end - end - add_message "google.monitoring.v3.WindowsBasedSli.PerformanceThreshold" do - optional :threshold, :double, 2 - oneof :type do - optional :performance, :message, 1, "google.monitoring.v3.RequestBasedSli" - optional :basic_sli_performance, :message, 3, "google.monitoring.v3.BasicSli" - end - end - add_message "google.monitoring.v3.WindowsBasedSli.MetricRange" do - optional :time_series, :string, 1 - optional :range, :message, 4, "google.monitoring.v3.Range" - end end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." end module Google module Cloud module Monitoring