说明
- 本博客每周五更新一次。
- 偶然知道 yarn 支持rest操作,惊喜中自觉知识狭隘,补充记录下。
分享
资料
操作
- 查看指定队列的所有任务:
GET http://<rm http address:port>/ws/v1/cluster/apps?queue=对列名
- 查看指定任务的详细信息:
GET http://<rm http address:port>/ws/v1/cluster/apps/application_id
- 查询集群调度器详情(包含队列信息):
GET http://<rm http address:port>/ws/v1/cluster/scheduler
- 查询集群指标:
GET http://<rm http address:port>/ws/v1/cluster/metrics
- 查看任务状态:
GET http://<rm http address:port>/ws/v1/cluster/apps/application_id/state
# curl实例
curl 'http://<rm http address:port>/ws/v1/cluster/apps/application_id/state'
PUT http://<rm http address:port>/ws/v1/cluster/apps/application_id/state
#curl实例
curl -v -X PUT -d '{"state": "KILLED"}''http://<rm http address:port>/ws/v1/cluster/apps/application_id'
总结
- 知识学习无穷无尽,怀着心跳不息,学习不止信念,只求今天的自己比昨天更优秀。