Overview of Amazon RDS event notification - Amazon Aurora
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Overview of Amazon RDS event notification

Amazon RDS groups events into categories that you can subscribe to so that you can be notified when an event in that category occurs.

RDS resources eligible for event subscription

For Amazon Aurora, events occur at both the DB cluster and the DB instance level. You can subscribe to an event category for the following resources:

  • DB instance

  • DB cluster

  • DB cluster snapshot

  • DB parameter group

  • DB security group

  • RDS Proxy

  • Custom engine version

For example, if you subscribe to the backup category for a given DB instance, you're notified whenever a backup-related event occurs that affects the DB instance. If you subscribe to a configuration change category for a DB instance, you're notified when the DB instance is changed. You also receive notification when an event notification subscription changes.

You might want to create several different subscriptions. For example, you might create one subscription that receives all event notifications for all DB instances and another subscription that includes only critical events for a subset of the DB instances. For the second subscription, specify one or more DB instances in the filter.

Basic process for subscribing to Amazon RDS event notifications

The process for subscribing to Amazon RDS event notification is as follows:

  1. You create an Amazon RDS event notification subscription by using the Amazon RDS console, Amazon CLI, or API.

    Amazon RDS uses the ARN of an Amazon SNS topic to identify each subscription. The Amazon RDS console creates the ARN for you when you create the subscription. Create the ARN by using the Amazon SNS console, the Amazon CLI, or the Amazon SNS API.

  2. Amazon RDS sends an approval email or SMS message to the addresses you submitted with your subscription.

  3. You confirm your subscription by choosing the link in the notification you received.

  4. The Amazon RDS console updates the My Event Subscriptions section with the status of your subscription.

  5. Amazon RDS begins sending the notifications to the addresses that you provided when you created the subscription.

To learn about identity and access management when using Amazon SNS, see Identity and access management in Amazon SNS in the Amazon Simple Notification Service Developer Guide.

You can use Amazon Lambda to process event notifications from a DB instance. For more information, see Using Amazon Lambda with Amazon RDS in the Amazon Lambda Developer Guide.

Delivery of RDS event notifications

Amazon RDS sends notifications to the addresses that you provide when you create the subscription. The notification can include message attributes which provide structured metadata about the message. For more information about message attributes, see Amazon RDS event categories and event messages.

Event notifications might take up to five minutes to be delivered.

Important

Amazon RDS doesn't guarantee the order of events sent in an event stream. The event order is subject to change.

When Amazon SNS sends a notification to a subscribed HTTP or HTTPS endpoint, the POST message sent to the endpoint has a message body that contains a JSON document. For more information, see Amazon SNS message and JSON formats in the Amazon Simple Notification Service Developer Guide.

You can configure SNS to notify you with text messages. For more information, see Mobile text messaging (SMS) in the Amazon Simple Notification Service Developer Guide.

To turn off notifications without deleting a subscription, choose No for Enabled in the Amazon RDS console. Or you can set the Enabled parameter to false using the Amazon CLI or Amazon RDS API.

Billing for Amazon RDS event notifications

Billing for Amazon RDS event notification is through Amazon SNS. Amazon SNS fees apply when using event notification. For more information about Amazon SNS billing, see Amazon Simple Notification Service pricing.

Examples of Aurora events

The following examples illustrate different types of Aurora events in JSON format. For a tutorial that shows you how to capture and view events in JSON format, see Tutorial: Log DB instance state changes using Amazon EventBridge.

Example of a DB cluster event

The following is an example of a DB cluster event in JSON format. The event shows that the cluster named my-db-cluster was patched. The event ID is RDS-EVENT-0173.

{ "version": "0", "id": "844e2571-85d4-695f-b930-0153b71dcb42", "detail-type": "RDS DB Cluster Event", "source": "aws.rds", "account": "123456789012", "time": "2018-10-06T12:26:13Z", "region": "us-east-1", "resources": [ "arn:aws-cn:rds:us-east-1:123456789012:cluster:my-db-cluster" ], "detail": { "EventCategories": [ "notification" ], "SourceType": "CLUSTER", "SourceArn": "arn:aws-cn:rds:us-east-1:123456789012:cluster:my-db-cluster", "Date": "2018-10-06T12:26:13.882Z", "Message": "Database cluster has been patched", "SourceIdentifier": "my-db-cluster", "EventID": "RDS-EVENT-0173" } }

Example of a DB parameter group event

The following is an example of a DB parameter group event in JSON format. The event shows that the parameter time_zone was updated in parameter group my-db-param-group. The event ID is RDS-EVENT-0037.

{ "version": "0", "id": "844e2571-85d4-695f-b930-0153b71dcb42", "detail-type": "RDS DB Parameter Group Event", "source": "aws.rds", "account": "123456789012", "time": "2018-10-06T12:26:13Z", "region": "us-east-1", "resources": [ "arn:aws-cn:rds:us-east-1:123456789012:pg:my-db-param-group" ], "detail": { "EventCategories": [ "configuration change" ], "SourceType": "DB_PARAM", "SourceArn": "arn:aws-cn:rds:us-east-1:123456789012:pg:my-db-param-group", "Date": "2018-10-06T12:26:13.882Z", "Message": "Updated parameter time_zone to UTC with apply method immediate", "SourceIdentifier": "my-db-param-group", "EventID": "RDS-EVENT-0037" } }

Example of a DB cluster snapshot event

The following is an example of a DB cluster snapshot event in JSON format. The event shows the creation of the snapshot named my-db-cluster-snapshot. The event ID is RDS-EVENT-0074.

{ "version": "0", "id": "844e2571-85d4-695f-b930-0153b71dcb42", "detail-type": "RDS DB Cluster Snapshot Event", "source": "aws.rds", "account": "123456789012", "time": "2018-10-06T12:26:13Z", "region": "us-east-1", "resources": [ "arn:aws-cn:rds:us-east-1:123456789012:cluster-snapshot:rds:my-db-cluster-snapshot" ], "detail": { "EventCategories": [ "backup" ], "SourceType": "CLUSTER_SNAPSHOT", "SourceArn": "arn:aws-cn:rds:us-east-1:123456789012:cluster-snapshot:rds:my-db-cluster-snapshot", "Date": "2018-10-06T12:26:13.882Z", "SourceIdentifier": "my-db-cluster-snapshot", "Message": "Creating manual cluster snapshot", "EventID": "RDS-EVENT-0074" } }