Queries the diagnostic information about Spark SQL queries.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- For mandatory resource types, indicate with a prefix of * .
- If the permissions cannot be granted at the resource level,
All Resourcesis used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
| Operation | Access level | Resource type | Condition key | Associated operation |
|---|---|---|---|---|
| adb:DescribeSparkSQLDiagnosisList | get | *DBClusterLakeVersion acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId} |
| none |
Request parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| DBClusterId | string | Yes | The cluster ID. Note
You can call the DescribeDBClusters operation to query the information about all AnalyticDB for MySQL Data Lakehouse Edition clusters within a region, including cluster IDs.
| amv-2zez35ww415xjwk5 |
| RegionId | string | Yes | The region ID. Note
You can call the DescribeRegions operation to query the most recent region list.
| cn-hangzhou |
| StatementId | long | No | The unique ID of the code block in the Spark job. | 123 |
| PageNumber | integer | No | The page number. | 1 |
| PageSize | integer | No | The number of entries per page. | 30 |
| Order | string | No | The order by which to sort query results. Specify the parameter value in the JSON format. Example:
Note
| [{\"Field\":\"QueryStartTime\",\"Type\":\"Desc\"}] |
| MinStartTime | string | No | The earliest start time. | 2024-11-28 22:00:00 |
| MaxStartTime | string | No | The latest start time. | 2024-11-28 23:00:00 |
Response parameters
Examples
Sample success responses
JSONformat
{
"TotalCount": 1343,
"RequestId": "A91C9D07-7462-5F35-BB47-83629CE6CCAC",
"PageNumber": 1,
"PageSize": 30,
"SQLDiagnosisList": [
{
"State": "COMPLETED",
"SQL": "select * from device where name = '105506012112790031'",
"AppId": "s202404291020bjd448ad40002122",
"StatementId": 1,
"InnerQueryId": 1,
"StartTime": "2024-11-20 09:09:00",
"ElapsedTime": 100,
"MaxExclusiveTime": 90,
"PeakMemory": 1024,
"ScanRowCount": 100
}
],
"AccessDeniedDetail": {}
}Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist. Make sure that the DBClusterId value is valid. |
For a list of error codes, visit the Service error codes.
