All Products
Search
Document Center

ApsaraDB for OceanBase:DescribeSlowSQLHistoryList

Last Updated:Apr 29, 2024

You can call this operation to query the execution history of an SQL statement by SQL ID that is determined as a slow SQL statement during a specified period of time.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
TenantIdstringYes

The ID of the tenant.

t384tolsj****
StartTimestringYes

The start time of the time range for querying the execution history of the slow SQL statement.
The value must be UTC time in the format of YYYY-MM-DDThh:mm:ssZ.

2021-12-14T02:34:49Z
EndTimestringYes

The end time of the time range for querying the execution history of the slow SQL statement.
The value must be UTC time in the format of YYYY-MM-DDThh:mm:ssZ.

2021-12-14T08:34:49Z
SQLIdstringYes

The SQL ID, which uniquely identifies an SQL statement.

8D6E84735C0****1823D199E2CA1****
PageNumberintegerNo

The number of the page to return.

  • Start value: 1
  • Default value: 1
1
PageSizeintegerNo

The number of rows to return on each page.

  • Maximum value: 100
  • Default value: 10
10

Response parameters

ParameterTypeDescriptionExample
object

The return result of the request.

RequestIdstring

The request ID.

EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C
SlowSQLHistoryListobject

The execution history of the slow SQL statement.

Listobject []

The return result of the request.

SqlIdstring

SQLID.

8D6E84****0B8FB1823D199E2CA1****
SqlTypestring

The SQL type.

1
TenantNamestring

The name of the tenant.

pay_online
UserNamestring

The username.

tester
ClientIpstring

The IP address of the client.

1*2.***.1*3.***
DbNamestring

The name of the database.

testdb
Eventstring

The wait event.

mysql response wait client
NodeIpstring

The IP address of the node.

i-bp18qljorblo8es*****
AffectedRowsdouble

The number of rows affected.

0
BlockCacheHitdouble

The number of block cache hits.

14
BlockIndexCacheHitdouble

The number of block index cache hits.

4
BloomFilterCacheHitdouble

The number of Bloom filter cache hits.

0
Executionsdouble

The number of executions.

89403
FailTimesdouble

The number of failures.

0
RPCCountdouble

The number of RPCs.

0
RemotePlansdouble

The number of remote plans.

0
MissPlansdouble

The number of plan misses.

0
ReturnRowsdouble

The number of rows returned.

1
LogicalReaddouble

The number of logical reads.

19
RetryCountdouble

The number of retries.

0
RowCacheHitdouble

The number of row cache hits.

0
DiskReaddouble

The number of physical reads.

0
MemstoreReadRowCountdouble

The number of rows read from the memory.

527
SsstoreReadRowCountdouble

The number of rows read from the disk.

43086
ExecPerSeconddouble

The number of executions per second.

163.0
AppWaitTimedouble

The wait time of the client.

0.0
ElapsedTimedouble

The average response time.

76.382
ExecuteTimedouble

The internal execution time.

61.044
QueueTimedouble

The queuing time.

15.275
ConcurrencyWaitTimedouble

The wait time in concurrent execution.

0.0
CpuTimedouble

The average CPU time.

50.13
DecodeTimedouble

The time to wait for decoding.

0.0
NetWaitTimedouble

The wait time for network.

0.0
IOWaitTimedouble

The I/O wait time.

0.0
GetPlanTimedouble

Hard parsing time.

0.052
MaxElapsedTimedouble

The maximum response time.

260.044
TotalWaitTimedouble

The internal wait time.

10.966
ScheduleTimedouble

The scheduling duration.

0.0
MaxCpuTimedouble

The maximum CPU time.

257.967
EndTimeUTCStringstring

The end time.

2021-12-28T02:08:18Z
Countlong

The quantity.

1

Examples

Sample success responses

JSONformat

{
  "RequestId": "EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C",
  "SlowSQLHistoryList": {
    "List": [
      {
        "SqlId": "8D6E84****0B8FB1823D199E2CA1****",
        "SqlType": "1",
        "TenantName": "pay_online",
        "UserName": "tester",
        "ClientIp": "1*2.***.1*3.***",
        "DbName": "testdb",
        "Event": "mysql response wait client",
        "NodeIp": "i-bp18qljorblo8es*****",
        "AffectedRows": 0,
        "BlockCacheHit": 14,
        "BlockIndexCacheHit": 4,
        "BloomFilterCacheHit": 0,
        "Executions": 89403,
        "FailTimes": 0,
        "RPCCount": 0,
        "RemotePlans": 0,
        "MissPlans": 0,
        "ReturnRows": 1,
        "LogicalRead": 19,
        "RetryCount": 0,
        "RowCacheHit": 0,
        "DiskRead": 0,
        "MemstoreReadRowCount": 527,
        "SsstoreReadRowCount": 43086,
        "ExecPerSecond": 163,
        "AppWaitTime": 0,
        "ElapsedTime": 76.382,
        "ExecuteTime": 61.044,
        "QueueTime": 15.275,
        "ConcurrencyWaitTime": 0,
        "CpuTime": 50.13,
        "DecodeTime": 0,
        "NetWaitTime": 0,
        "IOWaitTime": 0,
        "GetPlanTime": 0.052,
        "MaxElapsedTime": 260.044,
        "TotalWaitTime": 10.966,
        "ScheduleTime": 0,
        "MaxCpuTime": 257.967,
        "EndTimeUTCString": "2021-12-28T02:08:18Z"
      }
    ],
    "Count": 1
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history