Metrics

The following Spanner metrics are provided to Cloud Monitoring. For the best performance debugging results, use server-side metrics with client-side metrics.

The "metric type" strings in this table must be prefixed with spanner.googleapis.com/. That prefix has been omitted from the entries in the table. When querying a label, use the metric.labels. prefix; for example, metric.labels.LABEL="VALUE".

Metric type Launch stage(Resource hierarchy levels)
Display name
Kind, Type, Unit
Monitored resources
Description
Labels
api/api_request_count GA(project)
API requests
DELTAINT641
spanner_instance
Cloud Spanner API requests. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
status: Request call result, ok=success.
method: Cloud Spanner API method.
api/read_request_latencies_by_change_stream GA(project)
Read request latencies by change stream
DELTADISTRIBUTIONs
spanner_instance
Distribution of read request latencies by whether it is a change stream query. This includes latency of request processing in Cloud Spanner backends and API layer. It does not include network or reverse-proxy overhead between clients and servers. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
method: Cloud Spanner API method.
is_change_stream: (BOOL) TRUE if it is a change stream query.
api/read_request_latencies_by_serving_location BETA(project)
Read API request latencies by serving location
DELTADISTRIBUTIONs
spanner_instance
Distribution of read request latencies by serving location, whether it is a directed read query, and whether it is a change stream query. This includes latency of request processing in Cloud Spanner backends and API layer. It does not include network or reverse-proxy overhead between clients and servers. This is a superset of spanner.googleapis.com/api/read_request_latencies_by_change_stream. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
method: Cloud Spanner API method.
is_change_stream: (BOOL) TRUE if it is a change stream query.
is_directed_read: (BOOL) TRUE if it is a directed read query.
serving_location: The location of serving replicas.
api/received_bytes_count GA(project)
Bytes received by Cloud Spanner
DELTAINT64By
spanner_instance
Uncompressed request bytes received by Cloud Spanner. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
method: Cloud Spanner API method.
api/request_count GA(project)
API request rate
GAUGEDOUBLE1/s
spanner_instance
Rate of Cloud Spanner API requests. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
status: Request call result, ok=success.
method: Cloud Spanner API method.
api/request_latencies GA(project)
Request latencies
DELTADISTRIBUTIONs
spanner_instance
Distribution of server request latencies for a database. This includes latency of request processing in Cloud Spanner backends and API layer. It does not include network or reverse-proxy overhead between clients and servers. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
method: Cloud Spanner API method.
api/request_latencies_by_transaction_type GA(project)
Request latencies by transaction type
DELTADISTRIBUTIONs
spanner_instance
Distribution of server request latencies by transaction types. This includes latency of request processing in Cloud Spanner backends and API layer. It does not include network or reverse-proxy overhead between clients and servers. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
method: Cloud Spanner API method.
transaction_type: Transaction type ("READ_ONLY" or "READ_WRITE").
is_leader_involved: (BOOL) TRUE if the leader roundtrip call is issued.
api/sent_bytes_count GA(project)
Bytes sent by Cloud Spanner
DELTAINT64By
spanner_instance
Uncompressed response bytes sent by Cloud Spanner. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
method: Cloud Spanner API method.
graph_query_stat/total/bytes_returned_count GA(project)
Graph query bytes returned count
DELTAINT64By
spanner_instance
Number of data bytes that the graph queries returned, excluding transmission encoding overhead. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
graph_query_stat/total/execution_count GA(project)
Graph query execution count
DELTAINT641
spanner_instance
Number of times Cloud Spanner saw graph queries during the interval. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
graph_query_stat/total/failed_execution_count GA(project)
Graph query failures
DELTAINT641
spanner_instance
Number of times graph queries failed during the interval. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
status: failed status, one of [cancelled, timeout, error].
graph_query_stat/total/query_latencies GA(project)
Graph query latencies
DELTADISTRIBUTIONs
spanner_instance
Distribution of total length of time, in seconds, for graph query executions within the database. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
graph_query_stat/total/returned_rows_count GA(project)
Graph query rows returned count
DELTAINT641
spanner_instance
Number of rows that the graph queries returned. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
graph_query_stat/total/scanned_rows_count GA(project)
Graph query rows scanned count
DELTAINT641
spanner_instance
Number of rows that the graph queries scanned excluding deleted values. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
instance/autoscaling/high_priority_cpu_utilization_target GA(project)
Autoscaling high priority cpu utilization target
GAUGEDOUBLE10^2.%
spanner_instance
High priority CPU utilization target used for autoscaling. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/autoscaling/max_node_count GA(project)
Autoscaling max nodes
GAUGEINT641
spanner_instance
Maximum number of nodes autoscaler is allowed to allocate to the instance. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/autoscaling/max_processing_units GA(project)
Autoscaling max processing units
GAUGEINT641
spanner_instance
Maximum number of processing units autoscaler is allowed to allocate to the instance. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/autoscaling/min_node_count GA(project)
Autoscaling min nodes
GAUGEINT641
spanner_instance
Minimum number of nodes autoscaler is allowed to allocate to the instance. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/autoscaling/min_processing_units GA(project)
Autoscaling min processing units
GAUGEINT641
spanner_instance
Minimum number of processing units autoscaler is allowed to allocate to the instance. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/autoscaling/storage_utilization_target GA(project)
Autoscaling storage utilization target
GAUGEDOUBLE10^2.%
spanner_instance
Storage utilization target used for autoscaling. Sampled every 60 seconds. After sampling, data is not visible for up to 210 seconds.
instance/backup/used_bytes GA(project)
Backup storage used
GAUGEINT64By
spanner_instance
Backup storage used in bytes. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
backup: Target backup.
instance/cpu/smoothed_utilization GA(project)
Smoothed CPU utilization
GAUGEDOUBLE10^2.%
spanner_instance
24-hour smoothed utilization of provisioned CPU. Values are typically numbers between 0.0 and 1.0 (but might exceed 1.0), charts display the values as a percentage between 0% and 100% (or more). Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
instance/cpu/utilization GA(project)
CPU utilization
GAUGEDOUBLE10^2.%
spanner_instance
Percent utilization of provisioned CPU. Values are typically numbers between 0.0 and 1.0 (but might exceed 1.0), charts display the values as a percentage between 0% and 100% (or more). Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
instance/cpu/utilization_by_operation_type GA(project)
CPU utilization by operation type
GAUGEDOUBLE10^2.%
spanner_instance
Percent utilization of provisioned CPU, by operation type. Values are typically numbers between 0.0 and 1.0 (but might exceed 1.0), charts display the values as a percentage between 0% and 100% (or more). Currently, it does not include CPU utilization for system tasks. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
is_system: (BOOL) TRUE if the number is system CPU utilization.
priority: Task priority ("high" or "medium" or "low").
category: Operation type ("read_readonly", "beginorcommit" etc).
instance/cpu/utilization_by_priority GA(project)
CPU utilization by priority
GAUGEDOUBLE10^2.%
spanner_instance
Percent utilization of provisioned CPU, by priority. Values are typically numbers between 0.0 and 1.0 (but might exceed 1.0), charts display the values as a percentage between 0% and 100% (or more). Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
is_system: (BOOL) TRUE if the number is system CPU utilization.
priority: Task priority ("high", "medium", or "low").
instance/cross_region_replicated_bytes_count GA(project)
Cross region replicated bytes
DELTAINT64By
spanner_instance
Number of bytes replicated from preferred leader to replicas across regions. Sampled every 60 seconds. After sampling, data is not visible for up to 240 seconds.
database: Target database.
source_region: Preferred leader region.
destination_region: Cloud Spanner region the data is replicated to.
tag: Type of transaction contributing to replication.
instance/data_boost/processing_unit_second_count GA(project)
Processing unit second
DELTAINT641
spanner_instance
Total processing units used for DataBoost operations. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
credential_id: The IAM credential ID.
instance/dual_region_quorum_availability GA(project)
Dual Region Quorum Availability
GAUGEBOOL1
spanner_instance
Quorum availability signal for dual region instance configs. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
quorum_availability: Quorum availability level.
instance/leader_percentage_by_region GA(project)
Leader percentage by region
GAUGEDOUBLE10^2.%
spanner_instance
Percentage of leaders by cloud region. Values are typically numbers between 0.0 and 1.0, charts display the values as a percentage between 0% and 100%. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
region: Cloud region containing the leaders.
instance/node_count GA(project)
Nodes
GAUGEINT641
spanner_instance
Total number of nodes. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
instance/peak_split_cpu_usage_score GA(project)
Peak split cpu usage score
GAUGEDOUBLE1
spanner_instance
Maximum cpu usage score observed in a database across all splits. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
instance/placement_row_limit GA(project)
Placement row limit
GAUGEINT641
spanner_instance
Upper limit for placement rows. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
instance/placement_row_limit_per_processing_unit GA(project)
Placement row limit per processing unit
GAUGEDOUBLE1
spanner_instance
Upper limit for placement rows per processing unit. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
instance/placement_rows GA(project)
Placement row count by database
GAUGEINT641
spanner_instance
Number of placement rows in a database. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
instance/processing_units GA(project)
Processing units
GAUGEINT641
spanner_instance
Total number of processing units. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
instance/replica/cmek/total_keys BETA(project)
CMEK keys
GAUGEINT641
spanner_instance
Number of CMEK keys identified by database and key revocation status. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
is_key_revoked: (BOOL) True if the CloudKMS key is revoked.
instance/session_count GA(project)
Sessions
GAUGEINT641
spanner_instance
Number of sessions in use. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
instance/storage/limit_bytes GA(project)
Storage limit
GAUGEINT64By
spanner_instance
Storage limit for instance in bytes. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
storage_class: Storage type.
instance/storage/limit_bytes_per_processing_unit GA(project)
Storage limit per processing unit
GAUGEINT64By
spanner_instance
Storage limit per processing unit in bytes. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
storage_class: Storage type.
instance/storage/used_bytes GA(project)
Storage used
GAUGEINT64By
spanner_instance
Storage used in bytes. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
database: Target database.
storage_class: Storage type.
instance/storage/utilization GA(project)
Storage utilization
GAUGEDOUBLE10^2.%
spanner_instance
Storage used as a fraction of storage limit. Sampled every 60 seconds. After sampling, data is not visible for up to 180 seconds.
storage_class: Storage type.
lock_stat/total/lock_wait_time GA(project)
Lock wait time
DELTADOUBLEs
spanner_instance
Total lock wait time for lock conflicts recorded for the entire database. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_count GA(project)
Count of queries
DELTAINT641
spanner_instance
Count of queries by database name, status, query type, and used optimizer version. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
status: Request call result, ok=success.
query_type: Type of query.
optimizer_version: (INT64) Optimizer version used by the query.
query_stat/total/bytes_returned_count GA(project)
Bytes returned count
DELTAINT64By
spanner_instance
Number of data bytes that the queries returned, excluding transmission encoding overhead. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_stat/total/cpu_time GA(project)
Query cpu time
DELTADOUBLEs
spanner_instance
Number of seconds of CPU time Cloud Spanner spent on operations to execute the queries. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_stat/total/execution_count GA(project)
Query execution count
DELTAINT641
spanner_instance
Number of times Cloud Spanner saw queries during the interval. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_stat/total/failed_execution_count GA(project)
Query failures
DELTAINT641
spanner_instance
Number of times queries failed during the interval. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
status: failed status, one of [cancelled, timeout, error].
query_stat/total/query_latencies GA(project)
Query latencies
DELTADISTRIBUTIONs
spanner_instance
Distribution of total length of time, in seconds, for query executions within the database. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_stat/total/remote_service_calls_count GA(project)
Remote service calls count
DELTAINT641
spanner_instance
Count of remote service calls. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
service: Target remote service.
response_code: (INT64) HTTP response code received, such as 200 or 500.
query_stat/total/remote_service_calls_latencies GA(project)
Remote service calls latencies
DELTADISTRIBUTIONms
spanner_instance
Latency of remote service calls. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
service: Target remote service.
response_code: (INT64) HTTP response code received, such as 200 or 500.
query_stat/total/remote_service_network_bytes_sizes GA(project)
Remote service network bytes
DELTADISTRIBUTIONBy
spanner_instance
Network bytes exchanged with remote service. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
service: Target remote service.
direction: Direction of traffic: sent or received.
query_stat/total/remote_service_processed_rows_count GA(project)
Remote service rows count
DELTAINT641
spanner_instance
Count of rows processed by a remote service. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
service: Target remote service.
response_code: (INT64) HTTP response code received, such as 200 or 500.
query_stat/total/remote_service_processed_rows_latencies GA(project)
Remote service rows latencies
DELTADISTRIBUTIONms
spanner_instance
Latency of rows processed by a remote service. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
service: Target remote service.
response_code: (INT64) HTTP response code received, such as 200 or 500.
query_stat/total/returned_rows_count GA(project)
Rows returned count
DELTAINT641
spanner_instance
Number of rows that the queries returned. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
query_stat/total/scanned_rows_count GA(project)
Rows scanned count
DELTAINT641
spanner_instance
Number of rows that the queries scanned excluding deleted values. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/bytes_returned_count GA(project)
Bytes returned count
DELTAINT64By
spanner_instance
Total number of data bytes that the reads returned excluding transmission encoding overhead. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/client_wait_time GA(project)
Client wait time
DELTADOUBLEs
spanner_instance
Number of seconds spent waiting due to throttling. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/cpu_time GA(project)
Read cpu time
DELTADOUBLEs
spanner_instance
Number of seconds of CPU time Cloud Spanner spent execute the reads excluding prefetch CPU and other overhead. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/execution_count GA(project)
Read execution count
DELTAINT641
spanner_instance
Number of times Cloud Spanner executed the read shapesduring the interval. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/leader_refresh_delay GA(project)
Leader refresh delay
DELTADOUBLEs
spanner_instance
Number of seconds spent coordinating reads across instances in multi-regionconfigurations. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/locking_delays GA(project)
Locking delays
DELTADISTRIBUTIONs
spanner_instance
Distribution of total time in seconds spent waiting due to locking. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
read_stat/total/returned_rows_count GA(project)
Rows returned count
DELTAINT641
spanner_instance
Number of rows that the reads returned. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
row_deletion_policy/deleted_rows_count GA(project)
Rows deleted
DELTAINT641
spanner_instance
Count of rows deleted by the policy since the last sample. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
row_deletion_policy/processed_watermark_age GA(project)
Processed watermark age
GAUGEINT64s
spanner_instance
Time between now and the read timestamp of the last successful execution. An execution happens as the background task deletes eligible data in batches and is successful even when there are rows that cannot be deleted. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
row_deletion_policy/undeletable_rows GA(project)
Total number of undeletable rows
GAUGEINT641
spanner_instance
Number of rows in all tables in the database that can't be deleted. A row can't be deleted if, for example, it has so many child rows that a delete would exceed the transaction limit. Sampled every 60 seconds. After sampling, data is not visible for up to 120 seconds.
database: Target database.
transaction_stat/total/bytes_written_count GA(project)
Bytes written
DELTAINT64By
spanner_instance
Number of bytes written by transactions. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
transaction_stat/total/commit_attempt_count GA(project)
Transaction commit attempts
DELTAINT641
spanner_instance
Number of commit attempts for transactions. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
status: Commit status ("success", "abort", or "precondition_failure")
transaction_stat/total/commit_retry_count GA(project)
Transaction commit retries
DELTAINT641
spanner_instance
Number of commit attempts that are retries from previously aborted transaction attempts. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
transaction_stat/total/participants GA(project)
Transaction participants
DELTADISTRIBUTION1
spanner_instance
Distribution of total number of participants in each commit attempt. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.
transaction_stat/total/transaction_latencies GA(project)
Transaction latencies
DELTADISTRIBUTIONs
spanner_instance
Distribution of total seconds takenfrom the first operation of the transaction to commit or abort. Sampled every 60 seconds. After sampling, data is not visible for up to 150 seconds.
database: Target database.

Table generated at 2024-10-30 21:25:54 UTC.

What's next