tencent cloud

Creating Event Rule
Last updated:2026-03-19 14:54:35
Creating Event Rule
Last updated: 2026-03-19 14:54:35

Overview

Tencent Cloud Distributed Cache has been integrated into TCOP, supporting the reporting of TCOP events. All TCOP events will be automatically delivered to Tencent Cloud Event Bus (EventBridge)'s Cloud Service Event Set.

TCOP events

Currently, the following TCOP events can be reported:
Chinese Event Name
Event English Name
Event Type
Dependent Dimension
Presence or absence of restoration concept
Event Description
Handling Methods and Recommendations
Master/Replica switch
MasterSlaveSwitched
Status change
Instance Dimension
No
Database failover occurred.
A failure will cause the connection to the Distributed Cache service to be interrupted and temporarily unavailable. Please check whether the business has an automatic reconnection mechanism to ensure rapid restoration.
Service unavailability
ServiceNotAvailable
Exception event
Instance dimension
Yes
Database failure causes unavailability.
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
Instance Dimension
Yes
Database read-only replica failover occurred.
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
Exception event
Instance dimension
Yes
Database read-only replica 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. You can also add more read-only replicas.
Instance migration caused by server failure
ServerfailureInstanceMigration
Status change
Instance Dimension
Yes
Database server failure occurs.
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.
A failure will cause the connection to the Distributed Cache service to be interrupted and temporarily unavailable. Please check whether the business has an automatic reconnection mechanism to ensure rapid restoration.
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
CNY / million events
Application Scenario
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.
In the left sidebar, select Event Bus. In the event bus list, click default to view the default default event bus, which already includes Tencent Cloud Distributed Cache. For details, see Official Tencent Cloud Service Event Sources.
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
Parameter
Parameter Description
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
In the dropdown list, select TencentDB for Redis.
Select event sample
Select a specific event from the dropdown. The corresponding JSON format event rule will be automatically generated based on the selected 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 you select Data Transformation in the Basic Information section of the Event Model, click Next to display the Creating a Data Transformation page under Event Transformation, as shown below. Configure the format and fields for data transformation according to the parameter descriptions in the following table, then click Confirm to initiate data parsing. After data parsing completes, configure filter rules and data processing methods. For specific operations, see Configuring Data Transformation.
Note:
EventBridge provides a simple data processing feature. By inputting data and configuration items, it can format the data, then return the processed structured data and distribute it to downstream targets, bridging the gap between data sources and data processing systems.

Parameter
Description
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
Feature 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