Resource Orchestration Service (ROS) supports event notifications about resource changes.
Background information
The event monitoring feature of CloudMonitor serves as a centralized platform that enables you to query system events generated for different Alibaba Cloud services and view event statistics. This allows you to monitor your Alibaba Cloud services. Event monitoring can send alert notifications when exceptions occur on your Alibaba Cloud services. You can also use event monitoring to automate exception handling. CloudMonitor is integrated into ROS. When the status of a stack changes, ROS sends an event notification to CloudMonitor. Then, CloudMonitor queries details about the event and sends alerts.
For more information about system events, see the following topics:
Notifications about stack states
Notifications about ROS stacks in the following states can be sent:
- CREATE_FAILED
- CREATE_COMPLETE
- UPDATE_FAILED
- UPDATE_COMPLETE
- DELETE_FAILED
- DELETE_COMPLETE
- ROLLBACK_FAILED
- ROLLBACK_COMPLETE
- CREATE_ROLLBACK_FAILED
- CREATE_ROLLBACK_COMPLETE
Notification format
CREATE_COMPLETE is used in the following example to show the format of event notifications for ROS:
{
"Status": "Normal",
"InstanceName": "",
"ResourceId": "acs:ros:cn-hangzhou:175458090349****:stack/a797d0e1-c067-472a-ba86-2f0cdcbb****",
"Content": {
"callerId": "22905089471272****",
"requestId": "4D693712-0868-51DD-A736-4067AD7C0119",
"stackId": "a797d0e1-c067-472a-ba86-2f0cdcbb****",
"stackName": "diagnostic-dr-7a7c8fdc57e94f79****",
"status": "CREATE_COMPLETE",
"statusReason": "Stack CREATE completed successfully"
},
"Product": "ros",
"Level": "INFO",
"Time": 1663815166000,
"RegionId": "cn-hangzhou",
"Name": "Stack:StatusChange",
"GroupId": "0"
}
Parameters
The following table describes the parameters that are contained in event notifications.
Parameter | Description | Example |
---|
Parameter | Description | Example |
---|---|---|
Status | The state of the event. | Normal |
Time | The time when the event occurred. The time is displayed in UTC+8. | 20200616T220114.058+0800 |
Level | The level of the event. | INFO |
Name | The name of the event. | Stack:StatusChange |
Product | The name of the Alibaba Cloud service. The value of this parameter is ROS. | ROS |
RegionId | The region ID of the event. | cn-hangzhou |
ResourceId | The Alibaba Cloud Resource Name (ARN) of the resource. | acs:ros:cn-hangzhou:151266687691****:stack/37811dc0-9c3a-4112-ba1e-b1988106**** |
InstanceName | The name of the instance. | None |
GroupId | The ID of the event group. | 0 |
content | The details of the event. The details contain one or more parameters. | None |
Parameter | Description | Example |
---|
Parameter | Description | Example |
---|---|---|
stackId | The ID of the stack. | 37811dc0-9c3a-4112-ba1e-b1988106**** |
stackName | The name of the stack. | stack_2020-06-18stack |
status | The state of the stack. | CREATE_COMPLETE |
statusReason | The reason why the stack is in its current state. | Stack CREATE completed successfully |
callerId | The ID of the account that is used to perform the operation on the stack. If you use an Alibaba Cloud account to perform the operation, the value is the ID of the Alibaba Cloud account. If you use a RAM user to perform the operation, the value is the ID of the RAM user. | 29154787464691**** |
requestId | The ID of the request. | 939F2DC4-BA3E-4539-BB95-03A300D52467 |