1// Copyright 2023 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.monitoring.dashboard.v1; 18 19import "google/api/field_behavior.proto"; 20import "google/monitoring/dashboard/v1/metrics.proto"; 21import "google/monitoring/dashboard/v1/table_display_options.proto"; 22import "google/protobuf/duration.proto"; 23 24option csharp_namespace = "Google.Cloud.Monitoring.Dashboard.V1"; 25option go_package = "cloud.google.com/go/monitoring/dashboard/apiv1/dashboardpb;dashboardpb"; 26option java_multiple_files = true; 27option java_outer_classname = "TableProto"; 28option java_package = "com.google.monitoring.dashboard.v1"; 29option php_namespace = "Google\\Cloud\\Monitoring\\Dashboard\\V1"; 30option ruby_package = "Google::Cloud::Monitoring::Dashboard::V1"; 31 32// A table that displays time series data. 33message TimeSeriesTable { 34 // Groups a time series query definition with table options. 35 message TableDataSet { 36 // Required. Fields for querying time series data from the 37 // Stackdriver metrics API. 38 TimeSeriesQuery time_series_query = 1 39 [(google.api.field_behavior) = REQUIRED]; 40 41 // Optional. A template string for naming `TimeSeries` in the resulting data 42 // set. This should be a string with interpolations of the form 43 // `${label_name}`, which will resolve to the label's value i.e. 44 // "${resource.labels.project_id}." 45 string table_template = 2 [(google.api.field_behavior) = OPTIONAL]; 46 47 // Optional. The lower bound on data point frequency for this data set, 48 // implemented by specifying the minimum alignment period to use in a time 49 // series query For example, if the data is published once every 10 minutes, 50 // the `min_alignment_period` should be at least 10 minutes. It would not 51 // make sense to fetch and align data at one minute intervals. 52 google.protobuf.Duration min_alignment_period = 3 53 [(google.api.field_behavior) = OPTIONAL]; 54 55 // Optional. Table display options for configuring how the table is 56 // rendered. 57 TableDisplayOptions table_display_options = 4 58 [(google.api.field_behavior) = OPTIONAL]; 59 } 60 61 // Enum for metric metric_visualization 62 enum MetricVisualization { 63 // Unspecified state 64 METRIC_VISUALIZATION_UNSPECIFIED = 0; 65 66 // Default text rendering 67 NUMBER = 1; 68 69 // Horizontal bar rendering 70 BAR = 2; 71 } 72 73 // The persistent settings for a table's columns. 74 message ColumnSettings { 75 // Required. The id of the column. 76 string column = 1 [(google.api.field_behavior) = REQUIRED]; 77 78 // Required. Whether the column should be visible on page load. 79 bool visible = 2 [(google.api.field_behavior) = REQUIRED]; 80 } 81 82 // Required. The data displayed in this table. 83 repeated TableDataSet data_sets = 1 [(google.api.field_behavior) = REQUIRED]; 84 85 // Optional. Store rendering strategy 86 MetricVisualization metric_visualization = 2 87 [(google.api.field_behavior) = OPTIONAL]; 88 89 // Optional. The list of the persistent column settings for the table. 90 repeated ColumnSettings column_settings = 4 91 [(google.api.field_behavior) = OPTIONAL]; 92} 93