通过EMR Doctor获取任务分析信息。
接口说明
get one doctor analysis app
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
调试
授权信息
|
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
|
emr:GetDoctorApplication |
get |
*全部资源
|
无 | 无 |
请求参数
|
名称 |
类型 |
必填 |
描述 |
示例值 |
| RegionId |
string |
是 |
地域 ID。 |
cn-hangzhou |
| ClusterId |
string |
是 |
集群 ID。 |
c-b933c5aac8fe**** |
| AppId |
string |
是 |
任务提交到 YARN 的 ID。 |
application_1542620905989_**** |
| DateTime |
string |
是 |
其日期和时间信息以 ISO 8601 格式表示,例如:2023 年 1 月 1 日为 2023-01-01。 |
2023-01-01 |
返回参数
|
名称 |
类型 |
描述 |
示例值 |
|
object |
返回数据 |
||
| Data |
object |
任务详情。 |
|
| AppName |
string |
任务名称。 |
CREATE TABLE test...ranks=1 (Stage-1) |
| Ids |
array |
任务 IDs,多个 ID 间使用英文逗号(,)分隔。 |
null |
|
string |
YARN 的任务 ID。 |
application_1643475036865_****** |
|
| User |
string |
任务提交用户名。 |
DW |
| StartTime |
integer |
任务提交时间,Unix 时间戳,单位毫秒。 |
1677465658275 |
| EndTime |
integer |
任务结束时间,Unix 时间戳,单位毫秒。 |
1666213200000 |
| Queue |
string |
任务提交到 YARN 的队列。 |
DW |
| Type |
string |
计算引擎类型。 |
SPARK |
| QuerySql |
string |
任务提交的 SQL 语句,非 SQL 任务为空。 |
SELECT id, count(1) FROM test group by id; |
| Metrics |
object |
指标数据。 |
|
| VcoreUtilization |
object |
CPU 使用率,同 Linux Top 的%CPU 含义。 |
|
| Name |
string |
指标名称。 |
vcoreUtilization |
| Value |
number |
指标值。 |
32.1 |
| Unit |
string |
指标单位。 |
“” |
| Description |
string |
指标描述。 |
Ratio of used vcore to total available cores |
| MemUtilization |
object |
内存使用率。 |
|
| Name |
string |
指标名称。 |
memUtilization |
| Value |
number |
指标值。 |
0.82 |
| Unit |
string |
指标单位。 |
“” |
| Description |
string |
指标描述。 |
Ratio of used memory to total available memory |
| VcoreSeconds |
object |
CPU 使用量。 |
|
| Name |
string |
指标名称。 |
vcoreSeconds |
| Value |
integer |
指标值。 |
11123 |
| Unit |
string |
指标单位。 |
VCores * Sec |
| Description |
string |
指标描述。 |
Total vcore usage over time in seconds |
| MemSeconds |
object |
内存使用量。 |
|
| Name |
string |
指标名称。 |
memSeconds |
| Value |
integer |
指标值。 |
12312312 |
| Unit |
string |
指标单位。 |
MB * Sec |
| Description |
string |
指标描述。 |
Total memory usage over time in seconds |
| Analysis |
object |
任务分析。 |
|
| Score |
integer |
任务评分。 |
67 |
| Suggestion |
string |
任务运行建议。 |
##### 当前节点:container ##### 存在问题: 最大内存利用率为7.75%,利用率较低 尝试减小Tez Container内存,可通过hive.tez.container.size进行设置 |
| RequestId |
string |
请求 ID。 |
DD6B1B2A-5837-5237-ABE4-FF0C8944**** |
示例
正常返回示例
JSON格式
{
"Data": {
"AppName": "CREATE TABLE test...ranks=1 (Stage-1)",
"Ids": [
"application_1643475036865_******"
],
"User": "DW",
"StartTime": 1677465658275,
"EndTime": 1666213200000,
"Queue": "DW",
"Type": "SPARK",
"QuerySql": "SELECT id, count(1) FROM test group by id;",
"Metrics": {
"VcoreUtilization": {
"Name": "vcoreUtilization",
"Value": 32.1,
"Unit": "“”",
"Description": "Ratio of used vcore to total available cores"
},
"MemUtilization": {
"Name": "memUtilization",
"Value": 0.82,
"Unit": "“”",
"Description": "Ratio of used memory to total available memory"
},
"VcoreSeconds": {
"Name": "vcoreSeconds",
"Value": 11123,
"Unit": "VCores * Sec",
"Description": "Total vcore usage over time in seconds"
},
"MemSeconds": {
"Name": "memSeconds",
"Value": 12312312,
"Unit": "MB * Sec",
"Description": "Total memory usage over time in seconds"
}
},
"Analysis": {
"Score": 67,
"Suggestion": "##### 当前节点:container\n##### 存在问题:\n最大内存利用率为7.75%,利用率较低\n\n\n尝试减小Tez Container内存,可通过hive.tez.container.size进行设置\n\n"
}
},
"RequestId": "DD6B1B2A-5837-5237-ABE4-FF0C8944****"
}
错误码
|
HTTP status code |
错误码 |
错误信息 |
描述 |
|---|---|---|---|
| 400 | ConflictParameters | Parameters that must not be used together. %s | 多个参数间存在冲突。 |
| 400 | IncompleteSignature | The request signature is invalid. | API请求签名不合法。 |
| 400 | InvalidAction | The action %s requested is invalid. | 不合法的Action。 |
| 400 | InvalidParameter | The specified parameter %s is not valid. | 参数错误。 |
| 400 | InvalidParameterValue | The input parameter %s is invalid or out of range. | 参数值超出范围。 |
| 400 | MissingAction | The action %s requested is missing. | 缺少Action参数 |
| 400 | MissingParameter | The input parameter %s that is mandatory for processing this request is not supplied. | 参数缺失。 |
| 400 | NotAuthorized | You do not have permission to perform this action. %s | 没有权限。 |
| 400 | ThrottlingException | The request was denied due to request throttling. %s | 限流。 |
| 500 | InternalError | The request processing has failed due to some unknown error, exception or failure. | 内部错误。 |
| 404 | ResourceNotFound | The resource not found by %s. | 请求的资源未找到。 |
| 503 | ServiceFailure | The request has failed due to a temporary failure of %s service. | 依赖的阿里云其他服务不可用。 |
| 503 | ServiceUnavailable | The request has failed due to a temporary failure of the server. | 请求超时或者服务不可用。 |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。