tencent cloud

All product documents
TencentDB for Redis®
Creating Event Rule
Last updated: 2024-11-25 14:32:51
Creating Event Rule
Last updated: 2024-11-25 14:32:51

Overview

TencentDB for Redis® has been connected to TCOP to report cloud monitoring events. All events will be automatically delivered to the Event Bus in EventBridge.

TCOP events

Currently, the following TCOP events can be reported:
Event
Name
Event Type
Dimension
Recoverable
Description
Solution and Suggestion
Master/Replica switch
MasterSlaveSwitched
Status change
TencentDB for Redis® instance
No
A failover occurs in TencentDB for Redis®.
The failure will cause the TencentDB for Redis® service to become inaccessible and momentarily unavailable. Make sure that your business has an automatic reconnection mechanism for quick business recovery.
Service unavailability
ServiceNotAvailable
Errors
TencentDB for Redis® instance
Charged
The TencentDB for Redis® service is unavailable due to a failure.
We will recover the service as soon as possible and send a service recovery notification. If you have a disaster recovery instance, try switching your business to it.
Read-only replica failover
ReadonlyReplicaSwitched
Status change
TencentDB for Redis® instance
Charged
A failover occurs in the TencentDB for Redis® read-only replica.
We will recover the service as soon as possible and send a service recovery notification. If you have a disaster recovery instance, try switching your business to it. You can also add more read-only replicas.
Unavailable read-only replica
ReadonlyReplicaNotAvailable
Errors
TencentDB for Redis® instance
Charged
A failure occurs in the TencentDB for Redis® read-only replica.
We will recover the service as soon as possible and send a service recovery notification. If you have a disaster recovery instance, try switching your business to it. You can also add more read-only replicas.
Instance migration caused by server failure
ServerfailureInstanceMigration
Status change
TencentDB for Redis® instance
Charged
A server error occurs in TencentDB for Redis®.
The system detects that there is a hardware risk on the server and automatically performs a switch. The switch time is subject to the maintenance time. To change the time, do it promptly.
Proxy Failover
Proxy switchover
Exception event
Instance dimension
Yes
Proxy failover occurred in TencentDB for Redis®
Failover may cause disconnections and brief service unavailability. Ensure your application has an automatic reconnection mechanism to enable a quick recovery.
Instance Migration Triggered by Routine Maintenance of the Host Machine
Instance migrated due to risks on server
Exception event
Instance dimension
No
Instance migration triggered by routine maintenance of the host machine where the instance is deployed.
The migration process does not affect normal business access. However, there will be a brief second-level disconnection upon completion, accompanied by a primary/secondary switch alarm. Ensure your business has an automatic reconnection mechanism to facilitate rapid recovery.
Console operation events (delivered based on CloudAudit)
Console operations (CloudAudit)
Exception event
Instance dimension
No
Instance operations such as addition, deletion, or reconfiguration.
Perform a manual investigation to address any issues.
TencentCloud API Operation Events (delivered based on CloudAudit)
Cloud API actions (CloudAudit)
Exception event
Instance dimension
No
Instance operations such as addition, deletion, or reconfiguration.
Perform a manual investigation to address any issues.
Mini Program Operation Event (delivered based on CloudAudit)
Mini program operations (CloudAudit)
Exception event
Instance dimension
No
Instance operations such as addition, deletion, or reconfiguration.
Perform a manual investigation to address any issues.

Event target

An event rule can have multiple event targets. Before creating an event rule, plan the event target types first. Currently, EventBridge supports the following event targets.
Message Push Target (supported by rules only in the Tencent Cloud service event bus)

Billing Details

Tencent Cloud provides a pay-as-you-go purchasing option for EventBridge. For detailed information, see EventBridge > Pricing.
Type
Pay-as-you-go
Payment Method
Fees are charged hourly by the number of events actually delivered to the event bus.
Billing Unit
USD/million events
Use Cases
For applications with low or fluctuating message volumes, this approach effectively avoids resource waste.

Directions

1. Log in to the EventBridge console and select Event rule on the left sidebar.
2. At the top of the page on the right, select Guangzhou for Region and select default in the Event Bus drop-down list.
The Tencent Cloud service event bus collects monitoring and audit events generated by Tencent Cloud services in all regions. It is created in Guangzhou region by default and cannot be deleted.
Select Event Bus on the left sidebar. In the event bus list, click default, and you can see that the default event bus already contains TencentDB for Redis®. For detailed directions, see Tencent Cloud Service Event Source.
3. Click Create, and on the Create event rule navigation page under Rule pattern, configure the page parameters according to the explanations provided in the table below.



Interface Sections
Interface Parameter
Parameter Explanation
Basic information
Region
The region where the event rule is created.
Event Bus
Information about the event set to which the event rule belongs.
Rule name
Set the name of the event rule, which can include letters, Chinese characters, numbers, underscores, and hyphens. The name should start with a letter or Chinese character and end with a letter, number, or Chinese character, with a length of 2 to 60 characters.
Note:
Once created, the rule name cannot be modified.
Rule description
Provide a brief description of the event rule.
Tag
Select Enable and assign tag keys and values to the event.
Data Conversion
Select whether data transformation is required.
Event sample
Tencent Cloud service
From the dropdown list, select TencentDB for Redis® .
Select event sample
In the dropdown list, select the event type for which the rule is to be set. You can view the JSON format example of the event.
Event matching
Rule Pattern
Template: This mode allows selecting Tencent Cloud service and Event Type to define event matching rules.
1.1 In this section, select TencentDB for Redis® from the Tencent Cloud service dropdown.
1.2 In this section, select the specific event from the Event Type dropdown.
1.3 In the Subject to match dropdown, select the specific monitored instance.
1.4 In the Rule preview section on the right, the event rule will be generated in JSON syntax format by default.
1.5 Click Test match rule to perform a basic syntax check, or click Edit match rule to adjust it as needed.
Custom events: Manually write event matching rules.
4. (Optional) If Data Conversion is selected in the Basic information section of the Rule pattern, click Next to display the event transformation page, as shown below. Configure the data transformation format and fields according to the parameter explanations provided in the table. Click OK to start parsing the data. After parsing is complete, set the filter rules and data processing method. For detailed instructions, see Configure Data Transformation.
Note:
EventBridge provides simple data processing capabilities. After you pass in data and configuration items to EventBridge, EventBridge formats the data and distributes the structured data obtained after processing to downstream targets, creating a bridge between data sources and data processing systems.

Interface Parameter
Parameter Explanation
Rule pattern preview
Selecting Sample event allows you to use an event template for data transformation.
Selecting Manually input enables you to customize event fields in the input box below.
Tencent Cloud service
In the dropdown list, select TencentDB for Redis®.
Event template
Select a specific event from the dropdown. The corresponding JSON format event rule will be automatically generated based on the selected event.
Target
All events: Routes the entire event structure, including all fields, to the event target.
Specified events: EventBridge extracts specific parameters from the event using JSONPath configured fields in the CloudEvents, routing only the specified fields to the event target.
JSONPath
When the conversion target is set to Specified events, this parameter is displayed. Enter the event fields to be converted in the input box.
Parsing mode
1. Select the parsing mode, supporting JSON, delimiter, or regex extraction.
2. Click OK to generate the parsing results.
3. Click Test to view the test results.
5. Click Next to select the delivery target bound to the rule. You can deliver collected events to the specified target to process and consume them. In the figure below, Notification message is selected for Trigger method as an example.

6. To make the event rule take effect immediately, select Enable event rules now and click Complete.

Event Rule APIs

API
Description
Checks a rule
Creates an event rule
Deletes an event rule
Gets the details of an event rule
Gets the list of event rules
Updates an event rule

More operations

You can view, modify, or delete an event rule. For more information, see Managing Event Rule.

FAQs

For information about event rule concepts and billing-related FAQs, see Event Bus > FAQs.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

7x24 Phone Support
Hong Kong, China
+852 800 906 020 (Toll Free)
United States
+1 844 606 0804 (Toll Free)
United Kingdom
+44 808 196 4551 (Toll Free)
Canada
+1 888 605 7930 (Toll Free)
Australia
+61 1300 986 386 (Toll Free)
EdgeOne hotline
+852 300 80699
More local hotlines coming soon