NAME
Google::Monitoring::Dashboard::V1::Scorecard - Compiled Protocol Buffers messages for google/monitoring/dashboard/v1/scorecard.proto
SYNOPSIS
use Google::Monitoring::Dashboard::V1::Scorecard;
my $msg = Google::Monitoring::Dashboard::V1::Scorecard::Scorecard->new({
time_series_query => $time_series_query,
gauge_view => $gauge_view,
spark_chart_view => $spark_chart_view,
blank_view => $blank_view,
});
# Read or update a field
my $val = $msg->time_series_query();
# Binary wire-format roundtrip
my $bytes = $msg->serialize();
my $decoded = Google::Monitoring::Dashboard::V1::Scorecard::Scorecard->parse($bytes);
# Canonical ProtoJSON
my $json = $msg->to_json();
DESCRIPTION
Auto-generated Protobuf message classes compiled from google/monitoring/dashboard/v1/scorecard.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().
MESSAGES
Google::Monitoring::Dashboard::V1::Scorecard::Scorecard
A widget showing the latest value of a metric, and how this value relates to one or more thresholds.
Inherits from Protobuf::Message.
Accessors
$msg->time_series_query()/$msg->time_series_query($value)Type:
Message(Google::Monitoring::Dashboard::V1::Metrics::TimeSeriesQuery)Required. Fields for querying time series data from the Stackdriver metrics API.
$msg->gauge_view()/$msg->gauge_view($value)Type:
Message(Google::Monitoring::Dashboard::V1::Scorecard::Scorecard::GaugeView)Will cause the scorecard to show a gauge chart.
$msg->spark_chart_view()/$msg->spark_chart_view($value)Type:
Message(Google::Monitoring::Dashboard::V1::Scorecard::Scorecard::SparkChartView)Will cause the scorecard to show a spark chart.
$msg->blank_view()/$msg->blank_view($value)Type:
Message(Google::Protobuf::Empty::Empty)Will cause the `Scorecard` to show only the value, with no indicator to its value relative to its thresholds.
$msg->thresholds()/$msg->thresholds($value)Type:
Message(Google::Monitoring::Dashboard::V1::Metrics::Threshold)The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)
As an example, consider a scorecard with the following four thresholds:
``` { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } ```
Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.
SEE ALSO
Protobuf, Protobuf::Message, Google::Monitoring::Dashboard::V1::Scorecard::Types, https://protobuf.dev/
LICENSE AND COPYRIGHT
Copyright (C) 2026 Google LLC
This program is released under the Apache 2.0 license.