Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
140 changes: 76 additions & 64 deletions docs/generated/metrics/metrics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -518,6 +518,25 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.delete.started.count
exported_name: sql_delete_started_count
labeled_name: 'sql.started.count{query_type: delete}'
description: Number of SQL DELETE statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
how_to_use: This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.
- name: sql.delete.started.count.internal
exported_name: sql_delete_started_count_internal
labeled_name: 'sql.started.count{query_type: delete, query_internal: true}'
description: Number of SQL DELETE statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.distsql.contended_queries.count
exported_name: sql_distsql_contended_queries_count
description: Number of SQL queries that experienced contention
Expand Down Expand Up @@ -584,6 +603,25 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.insert.started.count
exported_name: sql_insert_started_count
labeled_name: 'sql.started.count{query_type: insert}'
description: Number of SQL INSERT statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
how_to_use: This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.
- name: sql.insert.started.count.internal
exported_name: sql_insert_started_count_internal
labeled_name: 'sql.started.count{query_type: insert, query_internal: true}'
description: Number of SQL INSERT statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.mem.root.current
exported_name: sql_mem_root_current
description: Current sql statement memory usage for root
Expand Down Expand Up @@ -780,6 +818,25 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.select.started.count
exported_name: sql_select_started_count
labeled_name: 'sql.started.count{query_type: select}'
description: Number of SQL SELECT statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
how_to_use: This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.
- name: sql.select.started.count.internal
exported_name: sql_select_started_count_internal
labeled_name: 'sql.started.count{query_type: select, query_internal: true}'
description: Number of SQL SELECT statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.service.latency
exported_name: sql_service_latency
description: Latency of SQL request execution
Expand Down Expand Up @@ -944,6 +1001,25 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.update.started.count
exported_name: sql_update_started_count
labeled_name: 'sql.started.count{query_type: update}'
description: Number of SQL UPDATE statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
how_to_use: This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.
- name: sql.update.started.count.internal
exported_name: sql_update_started_count_internal
labeled_name: 'sql.started.count{query_type: update, query_internal: true}'
description: Number of SQL UPDATE statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: txn.restarts.serializable
exported_name: txn_restarts_serializable
description: Number of restarts due to a forwarded commit timestamp and isolation=SERIALIZABLE
Expand Down Expand Up @@ -7701,22 +7777,6 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.delete.started.count
exported_name: sql_delete_started_count
description: Number of SQL DELETE statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.delete.started.count.internal
exported_name: sql_delete_started_count_internal
description: Number of SQL DELETE statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.disk.distsql.current
exported_name: sql_disk_distsql_current
description: Current sql statement disk usage for distsql
Expand Down Expand Up @@ -8141,22 +8201,6 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.insert.started.count
exported_name: sql_insert_started_count
description: Number of SQL INSERT statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.insert.started.count.internal
exported_name: sql_insert_started_count_internal
description: Number of SQL INSERT statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.insights.anomaly_detection.evictions
exported_name: sql_insights_anomaly_detection_evictions
description: Evictions of fingerprint latency summaries due to memory pressure
Expand Down Expand Up @@ -8821,22 +8865,6 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NONE
- name: sql.select.started.count
exported_name: sql_select_started_count
description: Number of SQL SELECT statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.select.started.count.internal
exported_name: sql_select_started_count_internal
description: Number of SQL SELECT statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.service.latency.consistent
exported_name: sql_service_latency_consistent
description: Latency of SQL request execution of non-historical queries
Expand Down Expand Up @@ -9277,22 +9305,6 @@ layers:
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.update.started.count
exported_name: sql_update_started_count
description: Number of SQL UPDATE statements started
y_axis_label: SQL Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.update.started.count.internal
exported_name: sql_update_started_count_internal
description: Number of SQL UPDATE statements started (internal queries)
y_axis_label: SQL Internal Statements
type: COUNTER
unit: COUNT
aggregation: AVG
derivative: NON_NEGATIVE_DERIVATIVE
- name: sql.vecindex.pending_splits_merges
exported_name: sql_vecindex_pending_splits_merges
description: Total number of vector index splits and merges waiting to be processed
Expand Down
48 changes: 32 additions & 16 deletions pkg/sql/exec_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -1016,28 +1016,44 @@ var (
Unit: metric.Unit_COUNT,
}
MetaSelectStarted = metric.Metadata{
Name: "sql.select.started.count",
Help: "Number of SQL SELECT statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
Name: "sql.select.started.count",
Help: "Number of SQL SELECT statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
LabeledName: "sql.started.count",
StaticLabels: metric.MakeLabelPairs(metric.LabelQueryType, "select"),
Category: metric.Metadata_SQL,
HowToUse: "This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.",
}
MetaUpdateStarted = metric.Metadata{
Name: "sql.update.started.count",
Help: "Number of SQL UPDATE statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
Name: "sql.update.started.count",
Help: "Number of SQL UPDATE statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
LabeledName: "sql.started.count",
StaticLabels: metric.MakeLabelPairs(metric.LabelQueryType, "update"),
Category: metric.Metadata_SQL,
HowToUse: "This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.",
}
MetaInsertStarted = metric.Metadata{
Name: "sql.insert.started.count",
Help: "Number of SQL INSERT statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
Name: "sql.insert.started.count",
Help: "Number of SQL INSERT statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
LabeledName: "sql.started.count",
StaticLabels: metric.MakeLabelPairs(metric.LabelQueryType, "insert"),
Category: metric.Metadata_SQL,
HowToUse: "This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.",
}
MetaDeleteStarted = metric.Metadata{
Name: "sql.delete.started.count",
Help: "Number of SQL DELETE statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
Name: "sql.delete.started.count",
Help: "Number of SQL DELETE statements started",
Measurement: "SQL Statements",
Unit: metric.Unit_COUNT,
LabeledName: "sql.started.count",
StaticLabels: metric.MakeLabelPairs(metric.LabelQueryType, "delete"),
Category: metric.Metadata_SQL,
HowToUse: "This high-level metric reflects workload volume. Monitor this metric to identify abnormal application behavior or patterns over time. If abnormal patterns emerge, apply the metric's time range to the SQL Activity pages to investigate interesting outliers or patterns. For example, on the Transactions page and the Statements page, sort on the Execution Count column. To find problematic sessions, on the Sessions page, sort on the Transaction Count column. Find the sessions with high transaction counts and trace back to a user or application.",
}
MetaCRUDStarted = metric.Metadata{
Name: "sql.crud_query.started.count",
Expand Down