本文為您介紹API Gateway - 監控服務關聯角色(AliyunServiceRoleForApiGatewayMonitoring)的應用情境以及如何刪除API Gateway - 監控服務關聯角色。
背景資訊
API Gateway - 監控服務關聯角色(AliyunServiceRoleForApiGatewayMonitoring)是為了方便使用者對同一分組上的所有API應用相同的警示配置時,而提供的RAM角色。更多關於服務關聯角色的資訊請參見服務關聯角色。
應用情境
API Gateway通過服務關聯角色功能擷取使用者CloudMonitor資源存取權限,可以把API分組和CloudMonitor的應用分組建立起對應關係,使得指定API分組上的API會自動成為對應的CloudMonitor應用分組下的執行個體,從而批量管理同一分組下的API警示。
AliyunServiceRoleForApiGatewayMonitoring介紹
角色名稱:AliyunServiceRoleForApiGatewayMonitoring 角色權限原則:AliyunServiceRolePolicyForApiGatewayMonitoring 許可權說明:
{
"Version": "1",
"Statement": [
{
"Effect": "Allow",
"Action": [
"cms:CreateMonitorGroup",
"cms:CreateMonitorGroupInstances",
"cms:DescribeMonitorGroups",
"cms:DeleteMonitorGroup",
"cms:DeleteMonitorGroupInstances"
],
"Resource": "acs:cms:*:*:*"
}
]
}刪除服務關聯角色
如果您需要刪除AliyunServiceRoleForApiGatewayMonitoring(服務關聯角色),需要先刪除依賴這個服務關聯角色的CloudMonitor下的應用分組。操作步驟如下:
進入CloudMonitor控制台。
點擊左側菜單
應用分組。找到並刪除名稱為APIGATEWAY_${region}_$(groupId)的應用分組,region 表示CloudMonitor應用分組所對應的API分組所在的地區,groupId表示API分組ID。如:
APIGATEWAY_ap-southeast-1_d17e78c9d436436c89a7e8c42a329a4d進入RAM控制台,點擊左側菜單
RAM 角色管理,找到角色AliyunServiceRoleForApiGatewayMonitoring刪除。