This topic describes monitoring metrics related to wait events within an OceanBase Database tenant. OceanBase Cloud Platform (OCP) provides the following seven metrics to collect statistics on the number of wait events that occur per second within a tenant: all, internal_wait, sync_rpc_wait, row_lock_wait, io_wait, latch_wait, and other_wait. Each metric defines the number of a specific type of wait events that occur per second within a tenant. You can specify a statistical period to query statistics about the wait events in a single zone or on a single OBServer of an OceanBase Database tenant.
all
Definition
The total number of wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| all | wait_event_count | count |
Calculation expression
sum(rate(ob_waitevent_wait_total{@LABELS}[@INTERVAL])) by (@GBLABELS)
internal_wait
Definition
The number of internal wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| internal_wait | system_event_internal_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="INTERNAL",@LABELS}[@INTERVAL])) by (@GBLABELS)
sync_rpc_wait
Definition
The number of synchronous remote procedure call (RPC) wait events that occur per second within a tenant in the specified statistical period.
A synchronous RPC wait event refers to a wait event that starts when an RPC request is sent and ends when the response to the request is returned.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| sync_rpc_wait | system_event_sync_rpc_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="SYNC_RPC",@LABELS}[@INTERVAL])) by (@GBLABELS)
row_lock_wait
Definition
The number of lock wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| row_lock_wait | system_event_row_lock_wait_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="ROW_LOCK_WAIT",@LABELS}[@INTERVAL])) by (@GBLABELS)
io_wait
Definition
The number of I/O wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| io_wait | system_event_io_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="IO",@LABELS}[@INTERVAL])) by (@GBLABELS)
latch_wait
Definition
The number of latch wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| latch_wait | system_event_latch_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="LATCH",@LABELS}[@INTERVAL])) by (@GBLABELS)
other_wait
Definition
The number of other wait events that occur per second within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| other_wait | system_event_other_total_waits | count |
Calculation expression
sum(rate(ob_system_event_total_waits{event_group="OTHER",@LABELS}[@INTERVAL])) by (@GBLABELS)