title: Overview

text:
There are times when you need to migrate data from one Redis Cloud database to another.

Here are two common ways to do this.

Each approach is suitable for different situations and the steps can vary according to your needs.

title: Transfer via import

text:
The most common way to transfer data to a new database is to import a copy of the data into it.

Here's how it works:

1.  [Select an export storage destination]() and verify that it's ready for use and has sufficient space.

1.  [Export]() the data from the original database to the storage location.

1.  [Import]() the exported data into the target database, the one hosted by the new subscription.

The migrated data reflects the state of the data at the time it was originally exported.

If you have apps or other connections actively using the source database, consider scheduling downtime for the migration to avoid loss.

This approach also lets you transfer data between databases hosted by different services.

title: Sync using Active-Passive

text:
If your target database is hosted on Redis Cloud Pro, you can use Active-Passive to sync the source database to the target database.  The source database can be hosted on Redis Cloud Pro or Redis Cloud Essentials.

The source database remains active while the data migrates.

The following sections describe Active-Passive syncing processes.

title: General Active-Passive syncing process

text:
To migrate data using Active-Passive syncing, specify the target database as an Active-Passive replica of the source database:

1.  Get the source database's public endpoint from the **General** section of the database's **Configuration** tab.
2.  Activate the target database as an Active-Passive replica for the source.
3.  Stop all writes to the source database and wait for the data to sync.
4.  Turn off Active-Passive for the target database.
5.  Switch apps and other connections to the target database.

Before you use Active-Passive, be aware of the following limitations:

- An error will appear when syncing the two databases if the source and target databases are hosted on different Redis Cloud accounts. [Contact support](https://redis.io/support/) if you want to migrate a database between accounts using Active-Passive.

- As long as Active-Passive is enabled, data in the target database will not expire and will not be evicted regardless of the set [data eviction policy](). **Do not write to the target database while Active-Passive is enabled.** We recommend that you turn off Active-Passive after the databases are synced.

- Turning on Active-Passive will flush the target database. Make sure that your target database has no important data before you turn on Active-Passive.

title: Detailed Active-Passive syncing process {#sync-using-active-passive}

text:
Follow these detailed steps to migrate data using Active-Passive syncing:

1.  Select **Databases** from the [Redis Cloud console](https://cloud.redis.io/) menu and select the target database in the list.

1.  From the **Configuration** tab of the target database, select **Edit**.

1.  In the **Durability** section, enable **Active-Passive Redis** and then select **Add Source**.

1. This will open the **Add Active-Passive Redis** screen. Select where the source database is located.

    - Select **Current account** if the source database is located in this Redis Cloud account.

        Select the source database from the **Source database** list. You can type in the database's name to find it.

    - If the source database is hosted externally, select **External**.

        1.  In the **Enter the source URI** field, type `redis://` and then paste in the public endpoint details.

        1. Select if the source database requires Transport Layer Security (TLS).

            - If the source database requires TLS, select **TLS** and enter the public server certificate in the **Server Certificate** field.

            - If the source database requires client authentication, select **Mutual TLS**.

                1. Enter the public server certificate in the **Server Certificate** field.

                1. Select **Download** to download the client certificate.

                1. Configure the source database to accept the client certificate.

1. Select **Save Active-Passive** to save your Active-Passive settings.

    For an external database, we'll verify the endpoint at this step. If the endpoint can't be verified, make sure that you've copied the details directly from the source database and that the value you entered starts with `redis://`.

1.  Select **Save Database** to begin updating the database.

    Initially, the database status is __Pending__, which means the update task is still running.

    The sync process doesn't begin until the database becomes `Active`.

    When data has fully migrated to the target database, database status reports `Synced`.

Active-Passive sync lets you migrate data while apps and other connections are using the source database.  Once the data is migrated, you should migrate active connections to the target database.

Do not write to the target database until turning off Active-Passive. Writing to the target database of an Active-Passive setup can cause data consistency issues and replication failures. See [Active-Passive replication considerations]() for more information.

title: Active-Passive memory requirements

text:
Active-Passive sync requires more memory than data import.  On average, you need an extra 25% memory on top of other requirements, though specific requirements depend on the data types and other factors.

To illustrate, suppose you want to migrate a 1 GB source database without replication to a target database with replication enabled.  Here, the target database memory limit should be at least 2.5 GB to avoid data loss.

Once the databases are synced, you can disable Active-Passive for the target database.  Before doing so, however, verify that apps and other connections have switched to the target database; otherwise, you may lose data.


title: Monitor database performance

page_type: content

title: Overview

role: overview

text: Redis Cloud provides a variety of metrics to help you monitor database performance.  You can view graphs of performance data at any time and receive emails when performance crosses defined thresholds.

title: View database metrics

role: content

text:
The **Metrics** tab of the **View Database** screen provides a series of graphs showing performance data for your database.

Performance data provides insight into how your database is being used and how well it is performing.

The interval scrollbar controls the time period displayed in the graphs.

title: Promote metric graphs

text:
The **Metrics** screen shows two primary graphs and a collection of smaller ones.  You can promote any smaller graph to a primary position.

When you use the mouse to point to a smaller graph, three things appear:

- A promotion icon pointing left
- A promotion icon pointing right
- A summary panel showing the minimum, average, maximum, and most recent values displayed in the graph.

Use the promotion icons to promote the smaller graph to one of the primary positions. The left icon promotes the smaller graph to the left position and the right icon promotes the smaller graph to the right position.

title: Metric definitions

text:
Several metric graphs are available:

| **Metric** | **Description** |
|------------|-----------------|
| [Ops/sec]() | The number of overall operations per sec for all Redis commands |
| [Reads/sec]() | The number of read operations per second |
| [Writes/sec]() | The number of write operations per second |
| [Other cmds/sec]() | The number of other Redis commands per second |
| [Latency]() | Latency per operation, in milliseconds |
| [Reads latency]() | Latency per read operation, in milliseconds |
| [Writes latency]() | Latency per write operation, in milliseconds |
| [Other latency]() | Latency of other commands, in milliseconds |
| [Used memory]() | Amount of memory used by the database |
| [Total keys]() | Total number of keys in the database |
| [Connections]() | Total number of connections to the endpoint |
| [Evicted objects/sec]() | Number of objects evicted from the database per second. |
| [Expired objects/sec]() | Number of expired objects per second. An expired object is an object with expired TTL that was deleted from the database. |
| [Hit ratio]() | Percent of operations on existing keys out of the total number database operations |
| Network Ingress bytes/sec | Amount of traffic in bytes per second entering the database network |
| Network Egress bytes/sec | Amount of traffic in bytes per second exiting the database network |

For more detailed analysis, consider using [Redis Insight]() or [Prometheus and Grafana]().

title: Configure alerts {#configure-metric-alerts}

role: configuration

text:
Depending on your subscription plan, you can enable alerts for several metrics for a given database.

To do so, go to the **Configuration** tab of the database and then locate the **Alerts** section.

| Setting name | Description | Default Value | Accepted Range |
|---|---|---|---|
| **Dataset size has reached** | Sends an alert when the dataset size reaches or exceeds the defined percentage of the memory limit. (_Pro only_) | 80% | 1-100% |
| **Total size of datasets under this plan reached** | Sends an alert when the total size of all datasets in the plan reaches or exceeds the defined percentage of the plan limit. (_Essentials only_) | 80% | 1-100% |
| **Throughput is higher than** | Sends an alert when throughput is over the defined limit in operations per second (ops/sec). (_Paid Essentials or Pro only_) | 1000 ops/sec | 1-10000000 ops/sec |
| **Throughput is lower than** | Sends an alert when throughput is under the defined limit in operations per second (ops/sec). (_Paid Essentials or Pro only_) | 10 ops/sec | 1-10000000 ops/sec |
| **Latency is higher than** | Sends an alert when the latency is over the defined limit in milliseconds (msec). (_Paid Essentials or Pro only_) | 10 msec | 1-10000 msec |
| **Number of connections** | Sends an alert when the number of connections exceeds the defined percentage of the plan limit.  (_Essentials only_) | 80% | 1-100% |
| **Replica Of - database unable to sync with source** | Sends an alert when the target database cannot sync with the source database after the defined number of seconds. (_Pro only_) | 1 second | 0-1 seconds |
| **Replica Of - sync lag is higher than** | Sends an alert if lag between the source and target databases exceeds the defined number of seconds. (_Pro only_) | 600 seconds | 1-86400 seconds |

Alert settings are specific to each database. Make sure you've configured alerts for all desired databases.

title: Change alert recipients

text:
Any member of the account team can receive alert emails.

To update alert settings for one or more team members, select **Access Management** from the Redis Cloud console menu and then select the **Team** tab. For details, see [Access management]().

If you subscribe to Redis Cloud through a Platform-as-a-Service (PaaS) provider (such as Heroku), you will need to review your provider's documentation for help managing your team.

title: Continue learning with Redis University


title: Define data pipeline

summary: Define the source connection and data pipeline.

title: Overview

text:
After you have [prepared your source database]() and connection information, you can set up your new pipeline. To do this:

1. [Define the source connection](#define-source-connection) by entering all required source database information.
2. [Define the data pipeline](#define-data-pipeline) by selecting the data that you want to sync from your source database to the target database.

title: Define source connection

text:
1. In the [Redis Cloud console](https://cloud.redis.io/), go to your target database and select the **Data Pipeline** tab.
1. Select **Define source database**.

1. Enter a **Pipeline name**.

1. A **Deployment CIDR** is automatically generated for you. If, for any reason, a CIDR is not generated, enter a valid CIDR that does not conflict with your applications or other databases.
1. In the **Source database connectivity** section, enter the **PrivateLink service name** of the [PrivateLink connected to your source database]().

1. Enter your database details. This depends on your database type, and includes:
    - **Port**: The database's port
    - **Database**: Your database's name, or the root database *(PostgreSQL, Oracle only)*, or a comma-separated list of one or more databases you want to connect to *(SQL Server only)*
    - **Database Server ID**: Unique ID for the replication client. Enter a number that is not used by any existing replication clients *(mySQL and mariaDB only)*
    - **PDB**: Name of the Oracle pluggable database *(Oracle only)*
1. Enter the ARN of your [database credentials secret]() in the **Source database secrets ARN** field.
1. If your database requires TLS, select **Use TLS**. Enter the ARN of your [CA certificate secret]() in the **CA Cert Secret ARN** field.

1. If your database requires mTLS, select **Use mTLS**. Enter the ARN of your [Client certificate secret]() in the **Client Certificate Secret ARN** field and the ARN of your [Client key secret]() in the **Client Key Secret ARN** field.

1. If your database requires mTLS with a client key passphrase, enter the ARN of your [Client key passphrase secret]() in the **Please add a secret ARN for the password to use with the secret store** field.
1. Select **Advanced properties** to configure additional optional properties for your pipeline.

    You can add any [Debezium source property](https://debezium.io/documentation/reference/stable/connectors/) for your source database type in the **Collector source properties** section and any [Redis server Debezium sink property](https://debezium.io/documentation/reference/stable/operations/debezium-server.html#_redis_stream) in the **Collector sink properties** section.
1. Select **Start pipeline setup**.

1. Redis Cloud will attempt to connect to PrivateLink. If your PrivateLink does not allow automatic acceptance of incoming connections, accept the incoming connection on AWS PrivateLink to proceed. See [Accept or Reject PrivateLink connection requests](https://docs.aws.amazon.com/vpc/latest/privatelink/configure-endpoint-service.html#accept-reject-connection-requests).

    If Redis Cloud can't find your PrivateLink connection, make sure that the PrivateLink service name is correct and that Redis Cloud is listed as an Allowed Principal for your VPC. See [Set up connectivity]() for more info.

At this point, Redis Cloud will provision the pipeline infrastructure that will allow you to define your data pipeline.

Pipelines are provisioned in the background. You aren't allowed to make changes to your data pipeline or to your database during provisioning. This process will take about an hour, so you can close the window and come back later.

When your pipeline is provisioned, select **Complete setup**. You will then [define your data pipeline](#define-data-pipeline).

title: Define data pipeline

text: After your pipeline is provisioned, you will be able to define your pipeline. You will select the database schemas, tables, and columns that you want to import and synchronize with your primary database.

title: Configure a new pipeline

text:
1. In the [Redis Cloud console](https://cloud.redis.io/), go to your target database and select the **Data Pipeline** tab. If your pipeline is already provisioned, select **Complete setup** to go to the **Data modeling** section.

1. Select the Schema and Tables you want to migrate to the target database from the list.

    Select **Manage Columns** to choose which columns you want to import.

    You can select any number of columns from a table.

    If any tables are missing a unique constraint, a warning will appear in the **Data modeling** section. Select **Manage columns** to select the columns that define a unique constraint for those tables.

    Select **Save** to save your column changes and go back to schema selection.

    Select **Add schema** to add more database schemas.

    Select **Delete** to delete a schema. You must have at least one schema to continue.

    After you've selected the schemas and tables you want to sync, select **Continue**.

1. Select the Redis data type to write keys to the target. You can choose **Hash key** or **JSON key** if the target database supports JSON.

    You can also supply one or more [transformation job files]() that specify how you want to transform the captured data before writing it to the target. Select **Upload jobs** to upload your job files.

    When you upload job files, Redis Cloud will validate the job files to check for errors.

    Select **Continue**.

1. In the **Advanced properties** section, you can add any processor properties to control how the data is processed. See the [RDI configuration file reference]() for all available processor properties.

    Select **Continue**.

1. Review the tables you selected in the **Review and deploy** section. If everything looks correct, select **Confirm & Deploy** to start ingesting data from your source database.

At this point, the data pipeline will ingest data from the source database to your target Redis database. This process will take time, especially if you have a lot of records in your source database.

After this initial sync is complete, the data pipeline enters the *change streaming* phase, where changes are captured as they happen. Changes in the source database are added to the target within a few seconds of capture.

You can view the status of your data pipeline in the **Data pipeline** tab of your database. See [View and edit data pipeline]() to learn more.


title: Data Integration

summary: Use Redis Data Integration with Redis Cloud.

summary: Learn how to create a data pipeline between a PostgreSQL source database created with Terraform and a Redis Cloud target database.

title: RDI on Redis Cloud quick start

summary: Prepare your source database, network setup, and database credentials for Data integration.

title: Prepare source database

title: Define data pipeline

summary: Observe and change your data pipeline.

title: View and edit data pipeline

summary: Set up RDS Proxy for Redis Data Integration (not recommended).

title: RDS Proxy setup for RDI

title: Overview

text:
Redis Cloud now supports [Redis Data Integration (RDI)](), a fast and simple way to bring your data into Redis from other types of primary databases.

A relational database usually handles queries much more slowly than a Redis database. If your application uses a relational database and makes many more reads than writes (which is the typical case) then you can improve performance by using Redis as a cache to handle the read queries quickly. Redis Cloud uses [ingest]() to help you offload all read queries from the application database to Redis automatically.

Using a data pipeline lets you have a cache that is always ready for queries. RDI Data pipelines ensure that any changes made to your primary database are captured in your Redis cache within a few seconds, preventing cache misses and stale data within the cache.

RDI helps Redis customers sync Redis Cloud with live data from their primary databases to:
- Meet the required speed and scale of read queries and provide an excellent and predictable user experience.
- Save resources and time when building pipelines and coding data transformations.
- Reduce the total cost of ownership by saving money on expensive database read replicas.

Using RDI with Redis Cloud simplifies managing your data integration pipeline. No need to worry about hardware or underlying infrastructure, as Redis Cloud manages that for you. Creating the data flow from source to target is much easier, and there are validations in place to reduce errors.

title: Is RDI a good fit for my architecture?

text:
RDI is designed to support apps that must use a disk-based database as the system of record
but must also be fast and scalable. This is a common requirement for mobile and web
apps with a rapidly-growing number of users; the performance of the main database is fine at first
but it will soon struggle to handle the increasing demand without a cache.

Use the information in the sections below to determine whether RDI is a good fit for your architecture. See also the
[decision tree for using RDI]()
which presents the considerations in a straightforward question-and-answer format.

[code example]

title: Data pipeline architecture

text:
An RDI data pipeline sits between your source database and your target Redis database. Initially, the pipeline reads all of the data and imports it into the target database during the *initial sync* phase. After this initial sync is complete, the data pipeline enters the *streaming* phase, where changes are captured as they happen. Changes in the source database are added to the target within a few seconds of capture. The data pipeline translates relational database rows to Redis hashes or JSON documents.

For more info on how RDI works, see [RDI Architecture]().

title: Pipeline security

text:
Data pipelines are set up to ensure a high level of data security. Source database credentials and TLS secrets are stored in AWS secret manager and shared using the Kubernetes CSI driver for secrets. See [Share source database credentials]() to learn how to share your source database credentials and TLS certificates with Redis Cloud.

Connections to the source database use Java Database Connectivity (JDBC) through [AWS PrivateLink](https://aws.amazon.com/privatelink/), ensuring that the data pipeline is only exposed to the specific database endpoint. See [Set up connectivity]() to learn how to connect your PrivateLink to the Redis Cloud VPC.

RDI encrypts all network connections with TLS. The pipeline will process data from the source database in-memory and write it to the target database using a TLS connection. There are no external connections to your data pipeline except from Redis Cloud management services.

title: Prerequisites

text:
Before you can create a data pipeline, you must have:

- A [Redis Cloud Pro database]() hosted on Amazon Web Services (AWS). This will be the target database.
- One supported source database, hosted on an AWS EC2 instance, AWS RDS, or AWS Aurora:

| Database | Versions | AWS RDS  Versions |
|:---|:---|:---|
| Oracle | 19c, 21c | 19c, 21c |
| MariaDB | 10.5, 11.4.3 | 10.4 to 10.11, 11.4.3 |
| MySQL | 5.7, 8.0.x, 8.2 | 8.0.x |
| PostgreSQL | 10, 11, 12, 13, 14, 15, 16 | 11, 12, 13, 14, 15, 16 |
| AWS Aurora PostgreSQL | 15 | 15 |
| SQL Server | 2017, 2019, 2022 | 2016, 2017, 2019, 2022 |

Please be aware of the following limitations:

- The target database must be a Redis Cloud Pro database hosted on Amazon Web Services (AWS). Redis Cloud Essentials databases and databases hosted on Google Cloud do not support Data Integration.
- The target database must use [high availability](). It can use either single-zone or multi-zone high availability.
- The target database can use TLS, but can not use mutual TLS.
- The target database cannot be in the same subscription as another database that has a data pipeline.
- Source databases must also be hosted on AWS.
- You must use a [custom encryption key on AWS](https://docs.aws.amazon.com/kms/latest/developerguide/create-keys.html) to create the instance hosting the database.
- One source database can only be synced to one target database.
- You must be able to set up AWS PrivateLink to connect your source database to your target database. RDI only works with AWS PrivateLink and not VPC Peering or other private connectivity options.
- Mutual TLS is not supported for AWS RDS and AWS Aurora source databases.

title: Get started

text:
To get started fast with RDI on Redis Cloud, see the [RDI Cloud quick start]() to create a data pipeline between a PostgreSQL source database and a Redis Cloud target database.

To create a new data pipeline, you need to:

1. [Prepare your source database]() and any associated credentials.
2. [Define the source connection and data pipeline]() by selecting which tables to sync.

Once your data pipeline is defined, you can [view and edit]() it.


title: RDI on Redis Cloud quick start

title: Overview

text:
The [`rdi-cloud-automation` GitHub repository](https://github.com/redis/rdi-cloud-automation) contains a Terraform script that quickly sets up a PostgreSQL source database on an EC2 instance and all required permissions and network setup to connect it to a Redis Cloud target database.

This guide is for demonstration purposes only. It is not recommended for production use.

title: Prerequisites

text:
To follow this guide, you need to:

1. Create a [Redis Cloud Pro database]() hosted on Amazon Web Services (AWS).

    Turn on Multi-AZ replication and [manually select the availability zones]() when creating the database.

1. Install the [AWS CLI](https://aws.amazon.com/cli/) and set up [credentials for the CLI](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html).

1. Install [Terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli).

title: Create a data pipeline

text:
1. On the [Redis Cloud console](https://cloud.redis.io/), go to your target database and select the **Data Pipeline** tab.
1. Select **Create pipeline**.

1. Select **PostgreSQL** as the source database type.

1. Under **Source database credentials and certificates**, save the provided ARN. This will be the `redis_secrets_arn` you will need later.

1. Under **Setup connectivity**, save the provided ARN. This will be the `redis_privatelink_arn` you will need later.

title: Create the source database and network resources

text:
1. Clone or download the [`rdi-cloud-automation` GitHub repository](https://github.com/redis/rdi-cloud-automation).

1. In a terminal window, go to the `examples/aws-ec2-privatelink` directory.

1. Run `terraform init` to initialize the Terraform working directory.

1. Open the `example.tfvars` file and edit the following variables:

    - `region`: The AWS region where your Redis Cloud database is deployed.
    - `azs`: The availability zone IDs where your Redis Cloud database is deployed.
    - `port`: The port number for the new PostgreSQL source database.
    - `name`: A prefix for all of the created AWS resources.
    - `redis_secrets_arn`: The source database credentials and certificates ARN from the Redis Cloud console.
    - `redis_privatelink_arn`: The PrivateLink ARN from the Redis Cloud console.

1. To view the configuration, run:

    [code example]

1. To create the AWS resources, run:

    [code example]

    This example creates the following resources on your AWS account:

    - An AWS KMS key with the required permissions for RDI
    - A VPC with a public and private subnet and all necessary route tables
    - An EC2 instance running a PostgreSQL database with a security group that allows access from Redis Cloud
    - An AWS Secrets Manager secret for the PostgreSQL database credentials
    - A Network Load Balancer (NLB), a listener, and target group to route traffic to the EC2 instance with AWS PrivateLink
    - An AWS PrivateLink endpoint service for the PostgreSQL database

Creating the AWS resources will take some time. After the resources are created, you'll be able to view them in the AWS management console.

Save the following outputs:

- `database`: The name of the PostgreSQL database.
- `port`: The port number for the PostgreSQL database.
- `secret_arn`: The ARN of the AWS Secrets Manager secret for the PostgreSQL database credentials.
- `vpc_endpoint_service_name`: The name of the AWS PrivateLink endpoint service for the PostgreSQL database.

If you lose any outputs, run `terraform output` to view them again.

title: Define source connection

text:
1. Return to the [Redis Cloud console](https://cloud.redis.io/). Go to your target database and select the **Data Pipeline** tab.
1. Select **Define source database**.

1. Enter a **Pipeline name**.

1. A **Deployment CIDR** is automatically generated for you. If, for any reason, a CIDR is not generated, enter a valid CIDR that does not conflict with your applications or other databases.
1. Enter the terraform outputs in the following fields:
    - **PrivateLink service name**: `vpc_endpoint_service_name`
    - **Database**: `database`
    - **Port**: `port`
    - **Source database secrets ARN**: `secret_arn`
1. Select **Start pipeline setup**.

At this point, Redis Cloud will provision the pipeline infrastructure that will allow you to define your data pipeline.

Pipelines are provisioned in the background. You aren't allowed to make changes to your data pipeline or to your database during provisioning. This process will take about an hour, so you can close the window and come back later.

When your pipeline is provisioned, select **Complete setup**.

title: Define data pipeline

text:
After your pipeline is provisioned, you will be able to define your pipeline. You will select the database schemas, tables, and columns that you want to import and synchronize with your primary database.

See [Define data pipeline]() for detailed steps on defining your data pipeline.

After you define your data pipeline, it will ingest data from the source database to your target Redis database. This process will take time, especially if you have a lot of records in your source database.

After this initial sync is complete, the data pipeline enters the *change streaming* phase, where changes are captured as they happen. Changes in the source database are added to the target within a few seconds of capture. You can see this by connecting to your source database and making changes to the data, and then connecting to your target Redis database and verifying that the changes are reflected there.

You can view the status of your data pipeline in the **Data pipeline** tab of your database. See [View and edit data pipeline]() to learn more.

title: Delete sample resources

text:
Make sure to [delete your data pipeline]() before deleting the sample resources.

To delete the sample resources created by Terraform, run:

[code example]

code: terraform plan -var-file=example.tfvars

section_id: delete-sample-resources


title: RDS Proxy setup for RDI

title: Overview

text:
We do not recommend using RDS Proxy for RDI connections. The [Lambda function approach]() provides better failover handling and is the recommended solution for production environments.

Additionally, RDS Proxy does not work with RDS PostgreSQL and Aurora PostgreSQL because it does not support PostgreSQL logical replication.

Only use RDS Proxy if you have specific requirements that necessitate it.

title: Overview

text:
RDS Proxy is a fully managed, highly available database proxy for Amazon RDS. While it can be used with RDI, we recommend the Lambda function approach instead for the following reasons:

- **PostgreSQL incompatibility**: RDS Proxy does not support PostgreSQL logical replication, which is required for CDC (Change Data Capture).
- **Added complexity**: RDS Proxy adds an additional layer between RDI and your database.
- **Lambda provides better failover**: The Lambda function approach handles failover scenarios more efficiently.

If you still need to use RDS Proxy, follow the instructions below.

title: Prerequisites

text:
Before setting up RDS Proxy, ensure you have:

- An RDS or Aurora database (MySQL or SQL Server only)
- AWS Secrets Manager secret containing your database credentials
- AWS KMS encryption key for the secret
- Appropriate IAM permissions

title: Create RDS Proxy

text:
Follow the AWS documentation to create an RDS Proxy:

- [Creating an RDS Proxy](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-proxy-setup.html) (AWS documentation)
- [How RDS Proxy works](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-proxy.howitworks.html) (AWS documentation)
- [RDS Proxy TLS/SSL](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-proxy.howitworks.html#rds-proxy-security.tls) (AWS documentation)

title: IAM permissions

text:
The Proxy's IAM role must have the following permissions to access the database using the credentials secret and encryption key:

- `secretsmanager:GetSecretValue`
- `secretsmanager:DescribeSecret`
- `kms:Decrypt`

Example IAM policy:

[code example]

title: Get the RDS Proxy IP address

text:
After creating the RDS Proxy, you need to get its static IP address to use when configuring the Network Load Balancer.

To get the static IP address of your RDS Proxy, run the following command on an EC2 instance in the same VPC as the Proxy:

[code example]

Replace `<proxy-endpoint>` with the endpoint of your RDS Proxy. Save this IP address for use in the Network Load Balancer configuration.

title: Configure the Network Load Balancer

text:
When you [create the Network Load Balancer](), use the RDS Proxy IP address instead of the database IP address:

1. In **Register targets**, enter the static IP address of your RDS Proxy (obtained in the previous step).
2. Enter the port number where your RDS Proxy is exposed.
3. Select **Include as pending below**.
4. Complete the remaining Network Load Balancer setup as described in the [main setup guide]().

title: Next steps

text:
After setting up RDS Proxy and the Network Load Balancer:

1. [Create an endpoint service]() through AWS PrivateLink.
2. [Share your source database credentials]() with Redis Cloud.
3. Continue with the [RDI pipeline configuration]().

When using RDS Proxy, you do not need to set up the Lambda function for failover handling, as the proxy provides a static endpoint.

Effect: Allow

section_id: iam-permissions

code: $ nslookup <proxy-endpoint>

section_id: get-the-rds-proxy-ip-address


title: Prepare source database

title: Create new data pipeline

text:
1. In the [Redis Cloud console](https://cloud.redis.io/), go to your target database and select the **Data Pipeline** tab.
1. Select **Create pipeline**.

1. Select your source database type. The following database types are supported:
    - MySQL
    - mariaDB
    - Oracle
    - SQL Server
    - PostgreSQL

1. If you know the size of your source database, enter it into the **Source dataset size** field.

1. Under **Setup connectivity**, save the provided ARN and extract the AWS account ID for the account associated with your Redis Cloud cluster from it.

    The AWS account ID is the string of numbers after `arn:aws:iam::` in the ARN. For example, if the ARN is `arn:aws:iam::123456789012:role/redis-data-pipeline`, the AWS account ID is `123456789012`.

title: Prepare source database

text:
Before using the pipeline, you must first prepare your source database to use the Debezium connector for change data capture (CDC). See [Prerequisites]() to find a list of supported source databases and database versions.

See [Prepare source databases]() to find steps for your database type:
- Hosted on an AWS EC2 instance:
    - [MySQL and mariaDB]()
    - [Oracle]()
    - [SQL Server]()
    - [PostgreSQL]()
- Hosted on AWS RDS or AWS Aurora:
    - [AWS Aurora PostgreSQL and AWS RDS PostgreSQL]()
    - [AWS Aurora MySQL and AWS RDS MySQL]()
    - [AWS RDS SQL Server]()

See the [RDI architecture overview]() for more information about CDC.

title: Set up connectivity

text:
To ensure that you can connect your Redis Cloud database to the source database, you need to set up an endpoint service through AWS PrivateLink.

The following diagrams show the network setup for the different database setups:

- Database hosted on an AWS EC2 instance:

- Database hosted on AWS RDS or AWS Aurora:

Select the steps for your database setup.

**EC2 instance:**

To set up PrivateLink for a database hosted on an EC2 instance:

1. [Create a network load balancer](#create-network-load-balancer-ec2) that will route incoming HTTP requests to your database.
1. [Create an endpoint service](#create-endpoint-service-ec2) through AWS PrivateLink.

title: Create network load balancer {#create-network-load-balancer-ec2}

text:
In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Compute** > **EC2**. [Create a network load balancer](https://docs.aws.amazon.com/elasticloadbalancing/latest/network/create-network-load-balancer.html#configure-load-balancer) with the following settings:

1. In **Basic configuration**:
    - **Scheme**: Select **Internal**.
    - **Load balancer IP address type**: Select **IPv4**.
1. In **Network mapping**, select the VPC and availability zone associated with your source database.
1. In **Security groups**, select the security group associated with your source database, or another security group that allows traffic from PrivateLink and allows traffic to the database.
1. In **Listeners and routing**:
    1. Select **Create target group** to [create a target group](https://docs.aws.amazon.com/elasticloadbalancing/latest/application/create-target-group.html) with the following settings:
        1. In **Specify group details**:
            - **Target type**: Select **Instances**.
            - **Protocol : Port**: Select **TCP**, and then enter the port number where your database is exposed.
            - The **IP address type** and **VPC** should be selected already and match the VPC you selected earlier.
        1. In **Register targets**, select the EC2 instance that runs your source database, enter the port, and select **Include as pending below**. Then, select **Create target group** to create your target group. Return to **Listeners and routing** in the Network Load Balancer setup.
    1. Set the following **Listener** properties:
        - **Protocol**: Select **TCP**.
        - **Port**: Enter your source database's port.
        - **Default action**: Select the target group you created in the previous step.
1. Review the network load balancer settings, and then select **Create load balancer** to continue.
1. After the network load balancer is active, select **Security**.

    If you selected the same security group as your source database, you must not enforce security group rules on PrivateLink traffic. Select **Edit** and then deselect **Enforce inbound rules on PrivateLink traffic**, and then select **Save changes**.

1. Select the security group ID to open the Security group settings.
1. Select **Edit inbound rules**, then **Add rule** to add a rule with the following settings:
    - **Type**: Select **HTTP**.
    - **Source**: Select **Anywhere - IPv4**.
    Select **Save rules** to save your changes.
1. Select **Actions** > **Edit Load Balancer Attributes**.
    - Under **Load balancer targets selection policy** select **Enable cross-zone load balancing**.
    Click the **Save Changes** button.

title: Create endpoint service {#create-endpoint-service-ec2}

text:
In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Networking & Content Delivery** > **VPC**. There, select **PrivateLink and Lattice** > **Endpoint services**. [Create an endpoint service](https://docs.aws.amazon.com/vpc/latest/privatelink/create-endpoint-service.html) with the following settings:

1. In **Available load balancers**, select the [network load balancer](#create-network-load-balancer-ec2) you created.
1. In **Additional settings**, choose the following settings:
    - **Require acceptance for endpoint**: Select **Acceptance required**.
    - **Supported IP address types**: Select **IPv4**.
1. Select **Create** to create the endpoint service.

After you create the endpoint service, you need to add Redis Cloud as an Allowed Principal on your [endpoint service VPC permissions](https://docs.aws.amazon.com/vpc/latest/privatelink/configure-endpoint-service.html#add-remove-permissions).

1. In the Redis Cloud Console, copy the Amazon Resource Name (ARN) provided in the **Setup connectivity** section.
1. Return to the endpoint service list on the [Amazon VPC console](https://console.aws.amazon.com/vpc/). Select the endpoint service you just created.
1. Navigate to **Allow principals** tab.
1. Add the Redis Cloud ARN you copied and choose **Allow principals**.
1. Save the service name for later.

For more details on AWS PrivateLink, see [Share your services through AWS PrivateLink](https://docs.aws.amazon.com/vpc/latest/privatelink/privatelink-share-your-services.html).

-

**AWS RDS or Aurora:**

-

To set up PrivateLink for a database hosted on AWS RDS or AWS Aurora:

To connect to your RDS or Aurora database, we recommend using a Lambda function approach. This provides a reliable and secure connection method for all database types.

1. [Create a network load balancer](#create-network-load-balancer-rds) that will route incoming requests to your database.
1. [Create an endpoint service](#create-endpoint-service-rds) through AWS PrivateLink.
1. [Set up Lambda function connectivity](#setup-lambda-function) to route requests to your database.

If you have specific requirements that necessitate using RDS Proxy instead of the recommended Lambda function approach, see the [RDS Proxy setup guide](). Note that RDS Proxy is not recommended and does not work with PostgreSQL.

title: Create network load balancer {#create-network-load-balancer-rds}

text:
In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Compute** > **EC2**. [Create a network load balancer](https://docs.aws.amazon.com/elasticloadbalancing/latest/network/create-network-load-balancer.html#configure-load-balancer) with the following settings:

1. In **Basic configuration**:
    - **Scheme**: Select **Internal**.
    - **Load balancer IP address type**: Select **IPv4**.
1. In **Network mapping**, select the VPC and availability zone associated with your source database.
1. In **Security groups**, select the security group associated with your source database, or another security group that allows traffic from PrivateLink and allows traffic to the database.
1. In **Listeners and routing**:
    1. Select **Create target group** to [create a target group](https://docs.aws.amazon.com/elasticloadbalancing/latest/application/create-target-group.html) with the following settings:
        1. In **Specify group details**:
            - **Target type**: Select **IP Addresses**.
            - **Protocol : Port**: Select **TCP**, and then enter the port number where your database is exposed.
            - The **IP address type** and **VPC** should be selected already and match the VPC you selected earlier.
        1. In **Register targets**, enter the static IP address of your database, enter the port, and select **Include as pending below**. Then, select **Create target group** to create your target group. Return to **Listeners and routing** in the Network Load Balancer setup.

            To get the static IP address of your database, run the following command on an EC2 instance in the same VPC as the database:
            [code example]
            Replace `<database-endpoint>` with the endpoint of your RDS or Aurora database.
    1. Set the following **Listener** properties:
        - **Protocol**: Select **TCP**.
        - **Port**: Enter your source database's port.
        - **Default action**: Select the target group you created in the previous step.
1. Review the network load balancer settings, and then select **Create load balancer** to continue.
1. After the network load balancer is active, select **Security**.

    If you selected the same security group as your source database, you must not enforce security group rules on PrivateLink traffic. Select **Edit** and then deselect **Enforce inbound rules on PrivateLink traffic**, and then select **Save changes**.

1. Select the security group ID to open the Security group settings.

1. Select **Edit inbound rules**, then **Add rule** to add a rule with the following settings:
    - **Type**: Select **HTTP**.
    - **Source**: Select **Anywhere - IPv4**.
    Select **Save rules** to save your changes.
1. Select **Actions** > **Edit Load Balancer Attributes**.
    - Under **Load balancer targets selection policy** select **Enable cross-zone load balancing**.
    Click the **Save Changes** button.

title: Create endpoint service {#create-endpoint-service-rds}

text:
In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Networking & Content Delivery** > **VPC**. There, select **PrivateLink and Lattice** > **Endpoint services**. [Create an endpoint service](https://docs.aws.amazon.com/vpc/latest/privatelink/create-endpoint-service.html) with the following settings:

1. In **Available load balancers**, select the [network load balancer](#create-network-load-balancer-rds) you created.
1. In **Additional settings**, choose the following settings:
    - **Require acceptance for endpoint**: Select **Acceptance required**.
    - **Supported IP address types**: Select **IPv4**.
1. Select **Create** to create the endpoint service.

After you create the endpoint service, you need to add Redis Cloud as an Allowed Principal on your [endpoint service VPC permissions](https://docs.aws.amazon.com/vpc/latest/privatelink/configure-endpoint-service.html#add-remove-permissions).

1. In the Redis Cloud Console, copy the Amazon Resource Name (ARN) provided in the **Setup connectivity** section.
1. Return to the endpoint service list on the [Amazon VPC console](https://console.aws.amazon.com/vpc/). Select the endpoint service you just created.
1. Navigate to **Allow principals** tab.
1. Add the Redis Cloud ARN you copied and choose **Allow principals**.
1. Save the service name for later.

For more details on AWS PrivateLink, see [Share your services through AWS PrivateLink](https://docs.aws.amazon.com/vpc/latest/privatelink/privatelink-share-your-services.html).

title: Set up Lambda function connectivity {#setup-lambda-function}

text:
Setting up the Lambda function is optional but recommended for production environments. The Lambda function provides automatic failover handling and a more robust connection to your RDS or Aurora database.

The Lambda function monitors RDS failover events and automatically updates the NLB Target Group to point to the new primary instance's IP address. This ensures RDI reconnects automatically after a failover.

#### Option 1: Use the Redis Terraform module

Redis provides a ready-to-use Terraform module that automates the Lambda function deployment. This is the recommended approach.

##### Prerequisites

- [Terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli) >= 1.5.7
- [AWS CLI](https://aws.amazon.com/cli/) configured with credentials
- The ARNs from the Network Load Balancer and Endpoint Service you created in the previous steps

##### Required variables

Before deploying the Lambda module, gather the following information:

| Variable | Description | Where to find it |
|----------|-------------|------------------|
| `identifier` | A unique name for the Lambda resources | Choose a descriptive name (e.g., `rdi-failover-handler`) |
| `db_endpoint` | Your RDS cluster or instance endpoint | AWS Console → RDS → Your database → Connectivity |
| `db_port` | Your database port | AWS Console → RDS → Your database → Connectivity (default: `5432` for PostgreSQL, `3306` for MySQL, `1433` for SQL Server) |
| `elb_tg_arn` | The NLB Target Group ARN | AWS Console → EC2 → Target Groups → Your target group |
| `rds_arn` | The RDS cluster or instance ARN | AWS Console → RDS → Your database → Configuration |
| `rds_cluster_identifier` | The RDS cluster identifier | AWS Console → RDS → Your cluster name |

##### Deploy the Lambda module

1. Clone the Redis cloud automation repository:

    [code example]

1. Create a `terraform.tfvars` file with your configuration:

    [code example]

1. Initialize and apply Terraform:

    [code example]

##### How the Lambda function works

The deployed Lambda function:

1. **Monitors RDS events**: Subscribes to RDS failover events via SNS
1. **Detects failover**: When a failover occurs, RDS triggers an SNS notification
1. **Resolves new IP**: The Lambda function queries DNS to get the new primary's IP address
1. **Updates NLB target**: Automatically updates the NLB Target Group with the new IP

This process typically completes within 30-60 seconds for Aurora, or 60-120 seconds for standard RDS.

##### Verify the deployment

After deployment, verify the Lambda function is configured correctly:

1. Check the Lambda function in AWS Console → Lambda → Functions
1. Verify the environment variables are set correctly:
    - `Cluster_EndPoint`: Your RDS endpoint
    - `RDS_Port`: Your database port
    - `NLB_TG_ARN`: Your NLB Target Group ARN
1. Check the SNS subscription in AWS Console → SNS → Subscriptions

#### Option 2: Full infrastructure deployment

For new deployments, Redis provides a complete Terraform example that deploys the entire infrastructure including the RDS database, NLB, PrivateLink, and Lambda function.

See the [AWS RDS PrivateLink Failover Example](https://github.com/redis/rdi-cloud-automation/tree/main/examples/aws-rds-privatelink-failover) for:

- Multi-engine support (PostgreSQL, MySQL, SQL Server)
- Automatic CDC user creation
- Complete VPC and networking setup
- Lambda-based failover handling

#### Option 3: Manual Lambda setup

For custom implementations, refer to the AWS documentation:
[Access Amazon RDS across VPCs using AWS PrivateLink and Network Load Balancer](https://aws.amazon.com/blogs/database/access-amazon-rds-across-vpcs-using-aws-privatelink-and-network-load-balancer/)

title: Share source database credentials

text:
You need to share your source database credentials and certificates in an Amazon secret with Redis Cloud so that the pipeline can connect to your database.

To do this, you need to:
1. [Create an encryption key](#create-encryption-key) using AWS Key Management Service with the right permissions.
1. [Create secrets](#create-database-credentials-secrets) containing the source database credentials encrypted using that key.

title: Create encryption key

text:
In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Key Management Service**. [Create an encryption key](https://docs.aws.amazon.com/kms/latest/developerguide/create-symmetric-cmk.html) with the following settings:

1. In **Step 1 - Configure key**:
    - **Key type**: Select **Symmetric**.
    - **Key usage**: Select **Encrypt and decrypt**.
    - Under **Advanced options**, set the following:
        - **Key material origin**: Select **KMS - recommended**.
        - **Regionality**: Select **Single-Region key**.
1. In **Step 2 - Add labels**, add an alias and description for the key.
1. In **Step 3 - Define key administrative permissions**, under **Key deletion**, select **Allow key administrators to delete this key**.
1. In **Step 4 - Define key usage permissions**, under **Other AWS accounts**, select **Add another AWS account**. Enter the AWS account ID for the Redis Cloud cluster that you saved earlier.

Review the key policy and key settings, and then select **Finish** to create the key.

title: Create database credentials secrets

text:
To let Redis Cloud access your source database, you need to create AWS secrets for the source database's credentials and certificates.

The required secrets depend on your source database's security configuration. The following table shows the required secrets for each configuration:

| Security configuration | Required secrets |
| :-- | :-- |
| Username and password only |

Credentials secret (username and password for the RDI pipeline user)

 |
| TLS connection |

Credentials secret (username and password for the RDI pipeline user)

CA Certificate secret (server certificate)

 |
| mTLS connection |

Credentials secret (username and password for the RDI pipeline user)

CA Certificate secret (server certificate)

Client certificate secret

Client key secret

 |
| mTLS connection with client key passphrase |

Credentials secret (username and password for the RDI pipeline user)

CA Certificate secret (server certificate)

Client certificate secret

Client key secret

Client key passphrase secret

 |

Select a tab to learn how to create the required secret.

**Credentials secret:**

In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Secrets Manager**. [Create a secret](https://docs.aws.amazon.com/secretsmanager/latest/userguide/create_secret.html) of type **Other type of secret** with the following settings:

- **Key/value pairs**: Enter the following key/value pairs.

    - `username`: Database username for the RDI pipeline user
    - `password`: Database password for the RDI pipeline user

-

**CA Certificate secret:**

-

In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Secrets Manager**. [Create a secret](https://docs.aws.amazon.com/secretsmanager/latest/userguide/create_secret.html) of type **Other type of secret** with the following settings:

- **Key/value pairs**: Select **Plaintext** and enter the server certificate.

-

**Client certificate secret:**

-

In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Secrets Manager**. [Create a secret](https://docs.aws.amazon.com/secretsmanager/latest/userguide/create_secret.html) of type **Other type of secret** with the following settings:

- **Key/value pairs**: Select **Plaintext** and enter the client certificate.

-

**Client key secret:**

-

Use the [AWS CLI create-secret command](https://docs.aws.amazon.com/cli/latest/reference/secretsmanager/create-secret.html) or the [AWS CreateSecret API endpoint](https://docs.aws.amazon.com/secretsmanager/latest/apireference/API_CreateSecret.html) to create a binary secret containing the client key.

For example, using the AWS CLI, run the following command:

[code example]

Where:
- `<secret-name>` - Name of the secret
- `<path-to-client-key>` - Path to the client key file
- `<encryption-key-arn>` - ARN of the [encryption key](#create-encryption-key) you created earlier

After you create the secret, you need to add permissions to allow the data pipeline to access it.

In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Secrets Manager**. Select the private key secret you just created and then select **Edit permissions**.

Add the following permissions to your secret. Replace `<AWS ACCOUNT ID>` with the AWS account ID for the Redis Cloud cluster that you saved earlier.

-

**Client key passphrase secret:**

-

In the [AWS Management Console](https://console.aws.amazon.com/), use the **Services** menu to locate and select **Security, Identity, and Compliance** > **Secrets Manager**. [Create a secret](https://docs.aws.amazon.com/secretsmanager/latest/userguide/create_secret.html) of type **Other type of secret** with the following settings:

- **Key/value pairs**: Select **Plaintext** and enter the client key passphrase.

title: Next steps

text: After you have set up your source database and prepared connectivity and credentials, select **Define source database** to [define your source connection and data pipeline]().

code: $ nslookup <database-endpoint>

code:
git clone https://github.com/redis/rdi-cloud-automation.git
    cd rdi-cloud-automation/modules/aws-rds-lambda

code:
identifier             = "rdi-failover-handler"
    db_endpoint            = "your-cluster.cluster-xxxxxxxxx.us-east-1.rds.amazonaws.com"
    db_port                = 5432
    elb_tg_arn             = "arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/your-tg/xxxxxxxxx"
    rds_arn                = "arn:aws:rds:us-east-1:123456789012:cluster:your-cluster"
    rds_cluster_identifier = "your-cluster"

code:
terraform init
    terraform apply

code:
aws secretsmanager create-secret \
    --name <secret-name> \
    --secret-binary fileb://<path-to-client-key> \
    --kms-key-id <encryption-key-arn>

section_id: create-database-credentials-secrets


title: View and edit data pipeline

summary: Observe and change your data pipeline.

title: Overview

text:
Use the **Data pipeline** tab in your database to view and edit your data pipeline.

The **Data pipeline** tab gives an overview of your data pipeline and lets you view your data stream metrics.

The **Status** table shows statistics for the whole data pipeline:
- **Status**: The status of the data pipeline. Possible statuses include:
    | Status | Description |
    |--------|-------------|
    | **Initial Sync** | The data pipeline is ingesting all records from the source database into the target database. |
    | **Streaming** | The data pipeline is capturing new changes from the source database as they happen. Changes in the source database are added to the target database within a few seconds. |
    | **Stopped**| The data pipeline has been [stopped](#stop-and-restart-data-pipeline). |
    | **Error** | There is an error in the data pipeline. [Reset the pipeline](#reset-data-pipeline) and contact support if the issue persists. |
- **Total ingested**: Total number of records ingested from the source database.
- **Total inserted**: Total number of records inserted into the target database.
- **Total filtered**: Total number of records filtered from being inserted into the target database.
- **Total rejected**: Total number of records that could not be parsed or inserted into the target database.

The **Data stream metrics** table shows the following metrics for each data stream:
| Metric | Description |
|--------|-------------|
| **Name** | Name of the data stream. Each stream corresponds to a table from the source database.  |
| **Total** | Total number of records that arrived from the source table. |
| **Pending** | Number of records from the source table that are waiting to be processed. |
| **Inserted** | Number of new records from the source table that have been written to the target database. |
| **Updated** | Number of updated records from the source table that have been updated in the target database. |
| **Deleted** | Number of deleted records from the source table that have been deleted in the target database. |
| **Filtered** | Number of records from the source table that were filtered from being inserted into the target database. |
| **Rejected** | Number of records from the source table that could not be parsed or inserted into the target database. |

title: Edit data pipeline

text:
To change the data you want to ingest from the data pipeline:

1. From the **Data pipeline** tab, select **Edit**.

1. Select the Schema and Tables you want to migrate to the target database from the list.

    Select **Manage Columns** to choose which columns you want to import.

    You can select any number of columns from a table.

    If any tables are missing a unique constraint, a warning will appear in the **Data modeling** section. Select **Manage columns** to select the columns that define a unique constraint for those tables.

    Select **Save** to save your column changes and go back to schema selection.

    Select **Add schema** to add more database schemas.

    Select **Delete** to delete a schema. You must have at least one schema to continue.

    After you've selected the schemas and tables you want to sync, select **Continue**.

1. Select the Redis data type to write keys to the target. You can choose **Hash** or **JSON** if the target database supports JSON.

    You can also supply one or more [transformation job files]() that specify how you want to transform the captured data before writing it to the target. Select **Upload jobs** to upload your job files.

    When you upload job files, Redis Cloud will validate the job files to check for errors.

    Select **Continue**.

1. In the **Advanced properties** section, you can add any processor properties to control how the data is processed. See the [RDI configuration file reference]() for all available processor properties.

    Select **Continue**.

1. Review the tables you selected in and select how you want to update the data pipeline:

    - **Apply to new data changes only**: The data pipeline will only synchronize new updates to the schema and tables selected. The data pipeline will not ingest any data from new schemas or tables that are selected.
    - **Reset pipeline (re-process all data)**: The data pipeline will re-ingest all of the selected data.
    - **Flush cached data and reset pipeline**: The data pipeline will flush the target Redis database, and then re-ingest all of the selected data from the source database.

1. Select **Apply changes**.

At this point, the data pipeline will apply the changes. If you selected **Reset pipeline** or **Flush cached data and reset pipeline**, the data pipeline will ingest data from the source database to the target database. After this initial sync is complete, the data pipeline enters the *change streaming* phase, where changes are captured as they happen.

If you selected **Apply to new data changes only**, the data pipeline will enter the *change streaming* phase without ingesting data.

title: View metrics endpoints

text:
You can use [Prometheus and Grafana]() to track and display metrics for the data pipeline.

To view the metrics endpoints for the source collector and pipeline processor, go to the **Data pipeline** tab and select **More actions**, and then **Show metrics**. You can add these endpoints as Prometheus targets to start tracking your RDI metrics.

Prometheus endpoints are exposed on Redis Cloud's internal network. To access this network, enable [VPC peering]() or [AWS Transit Gateway](). See [Prometheus and Grafana with Redis Cloud]() for more information.

For more information about available RDI metrics, see [Observability]().

title: Reset data pipeline

text:
Resetting the data pipeline creates a new baseline snapshot from the current state of your source database, and re-processes the data from the source database to the target Redis database. You may want to reset the pipeline if the source and target databases were disconnected or you made large changes to the data pipeline.

To reset the data pipeline and restart the ingest process:

1. From the **Data pipeline** tab, select **More actions**, and then **Reset pipeline**.

1. If you want to flush the database, check **Flush target database**.

1. Select **Reset data pipeline**.

At this point, the data pipeline will re-ingest data from the source database to your target Redis database.

title: Stop and restart data pipeline

text:
To stop the data pipeline from synchronizing new data:

1. From the **Data pipeline** tab, select **More actions**, and then **Stop pipeline**.

1. Select **Stop data pipeline** to confirm.

Stopping the data pipeline will suspend data processing. To restart the pipeline from the **Data pipeline** tab, select **More actions**, and then **Start pipeline**.

title: Delete pipeline

text:
To delete the data pipeline:

1. From the **Data pipeline** tab, select **More actions**, and then **Delete pipeline**.

1. Select **Delete data pipeline** to confirm.

Deleted data pipelines cannot be recovered.


title: Manage database tags

title: Overview

text: Tags are key-value pairs that let you categorize your databases. You can create tags and add them to your databases to associate them with each other. Once you've added tags, you can filter your databases in the [database list]() or in the [cost report]() by tag key or value.

title: Manage tags

text:
You can manage tags from the [Redis Cloud console](https://cloud.redis.io/#/) in the [tag manager](#tag-manager). You can find the tag manager in the following places:

- [From your database in the **Configuration** tab](#configuration-tab)
- [From the database list](#database-list)

After you open the [tag manager](#tag-manager), you can use it to add, edit, or delete tags.

title: Open tag manager from the Configuration tab {#configuration-tab}

text:
To learn how to navigate to your database, see [View and edit databases](). Select the **Configuration** tab and go to the **General** section to view the tags that are set for your database.

Select **Manage Tags** to open the [tag manager](#tag-manager).

title: Open tag manager from the database list {#database-list}

text:
Using the database list allows you to manage tags for multiple databases without having to go into each database's **Tags** tab.

To get to the database list, select **Databases** from the main menu.

Hover over the database and select **Manage tags**, or select **More actions** > **Manage tags** to open the [tag manager](#tag-manager).

title: Use the tag manager {#tag-manager}

text:
The tag manager shows any tags that are associated with the database and allows you to create, edit, or delete tags.

Select **Save tags** to save your changes.


title: Redis version management

summary: Describes Redis Cloud supported database versions and upgrade options.

summary: Describes when you can upgrade your database to the latest available version for each plan type.

title: Upgrade Redis database version

title: Overview

text:
Redis Cloud provides comprehensive database version management that prioritizes customer control over major changes.

This page describes database version management for Redis Cloud. Redis Cloud manages the cluster version for you automatically.

title: Redis version structure

text:
Redis uses a **MAJOR.MINOR.PATCH** versioning scheme:

- **Major versions**: Significant changes that may include breaking changes (e.g., Redis 7 → Redis 8)
- **Minor versions**: New features and improvements within a major version (e.g., 8.2 → 8.4 → 8.6)
- **Patch versions**: Bug fixes and security updates (e.g., 8.2.1 → 8.2.2)

title: Version support models

role: compatibility

text:
Redis Cloud supports the following version support models:

- **Long-Term Support (LTS)** versions are the second and last minor versions in a major version. LTS versions on Redis Cloud get 5 years of extended support, including security updates and major bug fixes.
- **Short-Term Support (STS)** versions are all minor releases except the second and last minor versions in a major version. STS versions on Redis Cloud are supported for 6 months after the release of the following version.

When a Redis version reaches **End-of-Life (EOL)**, Redis Cloud will automatically upgrade your database to the next minor version during maintenance windows if you do not manually upgrade before EOL.

title: Supported database versions

text:
**We strongly recommend using the latest available database version** to benefit from the newest features, performance improvements, and security updates.

| Version | Support model | Status | EOL Date | Plans |
|---------|--------|--------|----------|-------|
| **Redis 8.4** | STS | GA | TBD | Essentials, Pro |
| **Redis 8.2** | LTS | GA | TBD | Essentials, Pro |
| **Redis 8.0** | STS | Preview | TBD | Essentials[1](#table-note-1) |
| **Redis 7.4** | LTS | GA | December 1, 2029 | Essentials, Pro |
| **Redis 7.2** | LTS | GA | December 1, 2029 | Essentials, Pro |
| **Redis 6.2** | LTS | GA | April 1, 2027 | Pro |

1.  Redis 8.0 is not available for new databases.

When a database version reaches End-of-Life (EOL), Redis Cloud will automatically upgrade your database to the following minor version during maintenance windows if you do not manually upgrade before EOL.

title: Version selection

text:
When creating a database, you select the database version (e.g., Redis 8.2). Redis Cloud automatically provides the latest patch version within that version.

For existing databases:

- **Redis 8.4+**: Minor version auto-upgrades are available (with opt-out for Pro users)
- **Redis 8.2 and earlier**: Auto-upgrade for minor versions is not supported; all upgrades must be done manually. See [Upgrade database version]() for more details.

title: Plan differences

text:
| Feature | Essentials | Pro |
|---------|------------|-----|
| Minor version auto-upgrades (Redis 8.4+) | Always enabled, upgrades to latest minor version | Default enabled, can disable |
| Major version upgrades | Customer controlled | Customer controlled |
| Manual upgrades | Yes | Yes |
| [Automatic upgrade time]() | Standard - between 12 AM and 6 AM region time | Configurable - [Set maintenance windows]() |

title: Manual upgrades

text:
You can update your databases to a later version if by selecting **More actions** > **Version upgrade** from the database list or database page.

Before upgrading, you should:

- Review the [release notes]() for your target version and all versions in between to ensure compatibility with your applications.
- [Back up your data](), review [breaking changes]().
- Upgrade your staging or QA database before upgrading your production database.

See [Upgrade database version]() for detailed instructions.

title: FAQ

text:
**Can I prevent minor version auto-upgrades?**
Pro users can opt out of minor version auto-upgrades for Redis 8.4+.

**What if I don't upgrade before EOL?**
Redis Cloud will force upgrade after notifications during your next maintenance window to ensure security and support.

**Can I downgrade?**
Automatically reverting to a previous Redis version is not supported on Redis Cloud. See [Manually revert upgrade]() for more details.

**How do I identify LTS vs STS?**
Check the [supported versions table](#supported-versions).


title: Upgrade Redis database version

title: Overview

text:
You can upgrade databases that are not on the latest available version of Redis to a later database version at any time.

Please keep in mind the following before upgrading your database version:

- We recommend that you [back up your data]() before upgrading to make it easier to [manually revert the upgrade](#manually-revert-upgrade) if needed.

- We recommend that you upgrade your database during off-peak hours or during application maintenance to minimize reconnections.

- Review the breaking changes for the new database version before upgrading:
    - [Redis 7.2]()
    - [Redis 7.4]()
    - [Redis 8.0]()
    - [Redis 8.2]()
    - [Redis 8.4]()

- You must upgrade the target database in an [Active-Passive]() setup before you upgrade the source database to prevent compatibility issues.

title: Upgrade database

text:
**Single-region database:**

To upgrade a single-region Redis Cloud database:

1. Choose your database from the **Databases** list to open your database page. Select **More actions > Version upgrade**.

    You can also select **More actions > Version upgrade** from the database list.

1. Select the target version from the **Select version** list.

    If your database has not been backed up before, we recommend that you back up your database. Select **Go to backup** to go to the [backup settings]().

1. Select **Upgrade Now** to start the upgrade.

The database will start upgrading to the selected version immediately. The upgrade may take a few minutes.

You can continue to use the Redis Cloud console for other tasks during the upgrade.

**Active-Active database:**

To request to upgrade all databases in an [Active-Active]() subscription:

1. Choose your Active-Active subscription from the **Subscriptions** list to open your subscription page. Select **Version upgrade**.

1. Select the version to upgrade your databases from the list and select **Upgrade** to submit the upgrade request.

The upgrade will start in 1-3 weeks from your request, according to your subscription's [maintenance windows](). All databases in the subscription will be upgraded to the same version.

title: Manually revert upgrade

text:
Automatically reverting to a previous Redis database version is not supported on Redis Cloud.

If you [backed up your database]() before you upgraded your database version, you can:

1. [Delete your database]() without deleting your subscription.
1. [Create a new database]() in your subscription with the following settings:
    - **Port number**: Use the same port number as the old database.
    - **Version**: Select the original version of Redis.
1. [Import the backup files]() into the new database.

This allows you to connect to the database on the previous version without changing your connection details in your application.

If you did not back up your database before upgrading:

1. [Back up your database]().
1. [Create a new database]() in your subscription and select the original version of Redis.
1. [Import the backup files]() into the new database.
1. Change connection details in your application from the old database to the new database.


title: View and edit databases

title: Overview

text:
Use the **Databases** menu of the Redis Cloud console to manage your databases.

To view the details of a database:

1. Sign in to the [Redis Cloud console](https://cloud.redis.io/).  (Create an account if you don't already have one.)

2. Select the **Databases** menu to display a [searchable list of all databases](#manage-the-database-list).

3. Locate the database in the list.

4. Select the database name to open the **Database** page.

The **Database** screen lets you review:
- Configuration details of a database
- Graphs showing performance metrics
- Recent activity via a "[slowlog]()," which lists queries that exceed a certain execution time.

For help changing database settings, see [Edit database details](#edit-database-details).

title: Configuration tab

text: The **Configuration** screen is divided into sections, each dedicated to a specific category.  Note that not every section or setting is available to every [subscription plan]().

title: General settings

text:
The **General** section defines basic properties about your database.

The available settings vary according to your plan, cloud provider, and design choices.  For example, if you do not select an Advanced Capability when creating a database, the **Advanced Capabilities** setting is not displayed when you view its configuration details.

| Setting name              | Description                                                                                |
|:--------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **Database Name**         | The name given to your database                                                                                |
| **Subscription Name**     | The name for the subscription your database is a part of                                                                                |
| **Public endpoint**       | Public URI used by any application or client to access the database. Redis Cloud Pro databases can [block the public endpoint]().                                                  |
| **Private endpoint**      | Private endpoint URI available to approved clients; use CIDR allow list, VPC peering, or other connectivity options to enable access. (_Redis Cloud Pro only_) |
| **Tags**                  | A list of the [tags]() associated with the database. Select [Manage tags]() to manage the database tags. |
| **Vendor**                | The Cloud vendor hosting your database: AWS, Google Cloud, or Azure.                                                   |
| **Region**                | The Cloud vendor region hosting your database                                                  |
| **Type**                  | Displays 'Redis', 'Redis Stack' or 'memcached' based on the value selected when the database was created                                                    |
| **Redis version**         | Redis version of the database                                                                                |
| **Auto Tiering**          | Checked when the subscription supports Auto Tiering (_Redis Cloud Pro only_)                                                               |
| **Active-Active Redis**   | Checked when the database is part of an [Active-Active]() relationship (_Redis Cloud Pro only_)                                                                                |
| **Creation time**         | Date and time the database was created                                                                                |
| **Last changed**          | Date and time of last update                                                                                |
| **Supported Protocol(s)** | Shows which version of RESP the database uses. See [Redis serialization protocol](#resp-versions) for details |
| **Advanced Capabilities**  | This setting appears when an [advanced capability]() is enabled for a database                                                  |

title: Performance section

role: performance

text:
The **Performance** section describes the memory size, throughput, and hashing policy for a database.

| Setting name          |Description|
|:----------------------|:----------|
| **Dataset size** | Maximum size (in GB) for your dataset. See [Dataset size]().  |
| **Throughput**        | Defines [throughput]() in terms of maximum operations per second for the database (_Redis Cloud Pro only_). |
| **Memory used**       | Memory currently used for your database.  |
| **High availability**    | Replicates your data across multiple nodes; [available options]() depend on your plan type  |
| **Hashing policy**    | Defines the [hashing policy]() (_Redis Cloud Pro only_).  |
| **OSS Cluster API**       | Enables the [Cluster API]() for a database (_Redis Cloud Pro only_).

When this option is enabled, you cannot define a custom hashing policy.|

To learn more about these settings and when to use them, see [Sizing]() and [Database clustering]().

title: Durability section

text:
The Durability section helps protect your data when problems occur.  These settings define replication, persistence, backup, and eviction policies.

| Setting name             | Description                                                                                |
|:-------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **Data persistence**     | Defines whether (and how) data is saved to disk; [available options]() depend on your plan type |
| **Data eviction policy** | Configures which [policy]() is applied when your database reaches its memory limit        |
| **Remote backup**        | When enabled, identifies a location and interval for [data backups](). (_Paid plans only_)                |
| **Active-Passive Redis** | When enabled, identifies a path to the [linked database](). (_Redis Cloud Pro only_)                                                               |

title: Security section

role: security

text:
The **Security** section helps you control access to your database.

|Setting name| Description                                                                                |
|:-----------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **Default user** | When enabled, permits access using a simple password                                                                                |
| **Default user password** | Password for default user. A default password is assigned to the database on creation and may be updated. If you [block the public endpoint](), you can also turn on passwordless authentication for the default user here.  |
| **CIDR allow list** | [Allow list]() of IP addresses/security groups permitted to access the database. (_Paid plans only_)                    |
| **Transport layer security (TLS)** | Enables [transport layer security]() (TLS) encryption for database access. (_Pro plans only_)  |

title: Alerts section

text:
The **Alerts** section defines notification emails sent to your account and the conditions that trigger them.

The available alerts vary according to the plan type. See [Configure alerts]() for more information.

title: Danger zone

text:
Actions in the **Danger Zone** are permanent and should not be taken lightly.

Here, you can:

- Delete the database. Databases must be active before they can be deleted.  To learn more, see [Delete a database]().
- Flush the database (_Active-Active databases only_).

For best results, we recommend [backing up data]() before any danger zone actions.

title: Other actions and info

text:
The **View Database** screen also has tabs that let you view:

- **Metrics**: a series of graphs showing database performance over time.  See [Monitor performance]() for more information.

- **Slowlog**: a log showing recent [slow queries]() run against your database.  The log displays when the action started, the duration, the complexity of the operation, and any parameters passed to the operation.

title: Edit database details

text:
Use the **Edit** button to edit database details.

Because databases exist within the context of a deployment, certain fields cannot be updated, especially those that might lead to data loss.

Here's what you can change:

| Section | Setting                        | Comments |
|:-----------|:-------------------------------|:---------|
| General | Database name                  ||
| | Supported protocol(s)                  ||
| | Tags                                   ||
| Performance | Dataset size                   | |
| | High-availability                     | _Paid plans only_ |
| | Throughput                     | _Pro plans only_ |
| | Hashing policy                 | _Pro plans only_ |
| | OSS Cluster API                | _Pro plans only_ |
| Durability | Data persistence                | _Paid plans only_ |
| | Data eviction policy           | |
| | Remote backup                  | _Paid plans only_ |
| | Active-Passive Redis           | _Pro plans only_ |
| Security | Default user                   | |
| | Default user password          |
| | CIDR allow list                | _Paid plans only_ |
| | Transport layer security (TLS) | _Pro plans only_ |
| Alerts | all available for plan type |

Choose **Save database** to save your changes.

If you need to change other details, create a new database and then migrate existing data.

title: Manage the database list

text:
The **Databases** list summarizes the status of all databases associated with your account.

You can:

- Search by typing into the search box located above the database list.

- Filter by selecting a filter type and then selecting the checkbox next to the options you want to include from the dropdown.  Select the Filter toggle, located on the right of the search bar, if the filter types are hidden.

    You can filter the list on **Status**, **Subscription**, **Subscription Type**, **Capabilities**, **Options**, **Tags**, and **Version**.

    A list of selected filters appears below the filter types.

    To remove a filter click the **x** to the right of the name of that filter.  To remove all filters, select **Clear all**.

- Select **Columns** to change what information is displayed on the list.

- Select the **Export** button to export the current view as a CSV file.

- Sort the list in descending or ascending order using the arrow displayed to right of the field name in the header.  Supported fields include **Subscription**, **Database name**, **Memory usage**, and **Version**.

    Select the arrow icon to change the sort order.  One sort order can be active at any given time.

- Use the controls in the list footer to change the number of items displayed in the list or to navigate.

Sort orders and filter expressions are not saved between console sessions.


title: Redis Cloud

summary: The fastest way to set up Redis - a fully managed Redis database on major public cloud services.

title: Redis Cloud quick start

title: Manage databases

title: Manage subscriptions

summary: Store LLM responses for AI applications in Redis Cloud.

title: Semantic caching with LangCache on Redis Cloud

title: View logs and reports

summary: Describes how to work with Redis Cloud accounts and manage their settings.

title: Manage accounts and settings

summary: Describes how to view billing transactions and manage payment methods for Redis Cloud subscriptions.

title: Billing & payments

summary: Describes how to integrate Redis Cloud subscriptions into existing cloud provider services, whether existing subscriptions or through vendor marketplaces.

title: Manage marketplace integrations

title: Security

summary: Describes the Redis Cloud REST API and links to additional info

title: Redis Cloud REST API

summary: Set up your Redis Cloud databases to enable stable and highly available apps.

title: Develop highly available and resilient apps with Redis Cloud

summary: Use the Redis Cloud knowledge base to find answers to common Redis Cloud questions.

title: Troubleshoot Redis Cloud issues with the Redis Cloud knowledge base

summary: Redis Cloud compatibility with Redis Open Source.

title: Supported Cloud providers and regions

summary: Lists new features, enhancements, and other changes in Redis Cloud.

title: Redis Cloud changelog

summary: Describes where to view the archive of Redis Cloud documentation.

title: Archive

title: Overview

text:
[Redis Cloud](https://redis.io/cloud/) is a fully managed database-as-a-service that brings the speed and reliability of Redis to the cloud, offering seamless scalability and high availability for modern applications.

With Redis Cloud, you get all of the features of Redis Software, including:
- [Redis]() and [Redis Stack]() support
- Linear scalability
- Instant failover, backups, and recovery
- Predictable performance
- 24/7 monitoring and support

[Try Redis Cloud](https://redis.io/try-free/) to set up your free 30MB database.

title: Get started

text:
Use the [Quick start]() to learn how to create your free database.
- [Connect with redis-cli]()
- [Connect with Redis client]()
- [Connect with Redis Insight]()

You can also use [Vercel's Redis Cloud integration](https://vercel.com/marketplace/redis-cloud) or [Heroku's Redis Cloud add-on](https://elements.heroku.com/addons/rediscloud) to quickly add a Redis database to your project.

title: Databases

text:
Create and manage [Redis databases]() in the cloud.
- [Create database]()
- [View and edit databases]()
- [Monitor performance]()
- [Manage databases]()
- [Redis commands]() & [compatibility]()

title: Subscriptions

text:
Learn about the [types of subscriptions]().
- [View and upgrade Essentials plan]()
- [Essentials plans]()
- [View and edit Pro plan]()

title: Accounts & settings

text:
Manage Redis Cloud [accounts and settings]().
- [Billing and payments]()
- [Manage marketplace integrations]()

title: Security

text:
Manage [secure connections]() to cloud databases.
- [Access management]() for Redis Cloud console security and account management
- [Cloud database security]()
- [Multi-factor authentication]()
- [Single sign-on]() and [social login]()
- [Data access control]()

title: REST API

text:
Use the [REST API]() to manage Redis Cloud databases and subscriptions.
- [Get started with the REST API]()
- REST API [reference]() & [examples]()

title: Related info

role: related

text:
- [Redis Software]()
- [Develop with Redis]()
- [Redis Stack]()
- [Glossary]()


title: Create a LangCache service

title: Overview

text: Redis LangCache provides vector search capabilities and efficient caching for AI-powered applications. This guide walks you through creating and configuring a LangCache service in Redis Cloud.

title: Prerequisites

text:
To create a LangCache service, you will need:

- A Redis Cloud database. If you don't have one, see [Create a database]().

LangCache does not support the following databases during public preview:
- Databases with a [CIDR allow list]()
- [Active-Active]() databases
- Databases with the [default user]() turned off

- An API key for your embedding provider, if not using the default Redis embedding provider. LangCache supports [OpenAI](https://platform.openai.com/api-keys) and the Redis embedding provider during public preview.

title: Create a LangCache service

text:
From the [Redis Cloud console](https://cloud.redis.io/), select **LangCache** from the left-hand menu.

If you have not already created a LangCache service, you'll see a page with an introduction to LangCache. Otherwise, select **New service** to go to the LangCache introduction page.

From here:

- Select **Quick create** to create a LangCache service with default settings using your Free 30MB database. If you haven't created a Free database yet, Redis Cloud will create one and set up the LangCache service for you.

    After Redis Cloud creates your LangCache service, a window containing your LangCache service key will appear. Select **Copy** to copy the key to your clipboard.

This is the only time the value of the user key is available. Save it to a secure location before closing the dialog box.

If you lose the service key value, you will need to [generate a new service key]() to be able to use the LangCache API.

    After your cache is created, you can [use the LangCache API]() from your client app.

    You can also [view and edit the cache]() and [monitor the cache's performance]().

- If you want to customize your LangCache service, select **Create custom service**.

    This takes you to the **Create LangCache service** page. The page is divided into the following sections:

    1. The [General settings](#general-settings) section defines basic properties of your service.
    1. The [Embedding settings](#embedding-settings) section defines the embedding model used by your service.
    1. The [Attributes settings](#attributes-settings) section allows you to define attributes for your service.

title: General settings

text:
The **General settings** section defines basic properties of your service.

| Setting name          |Description|
|:----------------------|:----------|
| **Service name** | Enter a name for your LangCache service. We recommend you use a name that describes your service's purpose. |
| **Select database** | Select the Redis Cloud database to use for this service from the list. |
| **TTL** | The time to live (TTL) for cache entries, in milliseconds. Default: `No expiration` - items in the cache will remain until manually removed. |
| **User for this service** | The [database access user]() to use for this service. LangCache only supports the [`default` user]() during public preview. |

title: Embedding settings

text:
The **Embedding settings** section defines the embedding model used by your service.

Required settings depend on the embedding provider you select.

| Setting name          |Description|
|:----------------------|:----------|
| **Embedding Provider** | The embedding provider to use for your service. Select between `Redis`, `OpenAI`, and `Bring your own`.
Any embedding provider you use must support the [OpenAI embeddings API](https://platform.openai.com/docs/api-reference/embeddings). |
| **Embedding provider API key** | Enter your embedding provider's API key *(`OpenAI` and `Bring your own` embedding providers only)* |
| **Embedding provider URL** | Enter your embedding provider's API URL *(`Bring your own` embedding provider only)* |
| **Model** | Select or enter the embedding model to use for your service. |
| **Similarity threshold** | Set the minimum similarity score required to consider a cached response a match. Range: `0.5` to `1.0`. Default: `0.85`

A higher value means more precise matches, but if it's too high, you will compromise on the number of matches and may lose relevant matches. A lower value means more matches, but may include less relevant matches. We recommend starting between `0.8` and `0.9` and then fine-tuning based on your results. |

title: Attributes settings

text:
Attributes provide powerful scoping capabilities for your LangCache operations. Think of them as tags or labels that help you organize and manage your cached data with precision.

The **Attributes settings** section allows you to define attributes for your service. It is collapsed by default.

LangCache allows you to define up to 5 custom attributes that align with your specific use case. To add a new attribute:

1. Select **Add attribute**.

1. Give your custom attribute a descriptive name and select the check mark button to save it.

After you save your custom attribute, it will appear in the list of custom attributes. Use the **Delete** button to remove it.

You can also select **Add attribute** again to add an additional attribute.

title: Create service

text:
When you are done setting the details of your LangCache service, select **Create** to create it.

A window containing your LangCache service key will appear. Select **Copy** to copy the key to your clipboard.

This is the only time the value of the user key is available. Save it to a secure location before closing the dialog box.

If you lose the service key value, you will need to [generate a new service key]() to be able to use the LangCache API.

You'll be taken to your LangCache service's **Configuration** page. You'll also be able to see your LangCache service in the LangCache service list.

If an error occurs, verify that:
- Your database is active.
- You have provided a valid OpenAI API key.
- You have provided valid values for all the required fields.

For help, [contact support](https://redis.io/support/).

title: Next steps


title: Create a LangCache service

title: Use the LangCache API on Redis Cloud

title: View and edit LangCache service

title: Monitor a LangCache service

title: Overview

text:
LangCache is a semantic caching service available as a REST API that stores LLM responses for fast and cheaper retrieval, built on the Redis vector database. By using semantic caching, you can significantly reduce API costs and lower the average latency of your generative AI applications.

For more information about how LangCache works, see the [LangCache overview]().

title: LLM cost reduction with LangCache

title: Get started with LangCache on Redis Cloud


title: Monitor a LangCache service

title: Overview

text:
You can monitor a LangCache service's performance from the **Metrics** tab of the service's page.

The **Metrics** tab provides a series of graphs showing performance data for your LangCache service.

You can switch between hourly, daily, and weekly stats using the **Hour**, **Day**, and **Week** buttons at the top of the page. Each graph also includes minimum, average, maximum, and latest values.

title: LangCache metrics reference

title: Cache hit ratio

text:
The percentage of requests that were successfully served from the cache without needing to call the LLM API. A healthy cache will generally show an increasing hit ratio over time as it becomes more populated by cached responses.

To optimize your cache hit ratio:

- Tune similarity thresholds to capture more semantically related queries.
- Analyze recurring query patterns to fine-tune your embedding strategies.
- Test different embedding models to understand their impact on cache hit rates.

A higher cache hit ratio does not always mean better performance. If the cache is too lenient in its similarity matching, it may return irrelevant responses, leading to a higher cache hit rate but poorer overall performance.

title: Cache search requests

text: The number of read attempts against the cache at the specified time. This metric can help you understand the load on your cache and identify periods of high or low activity.

title: Cache latency

text:
The average time to process a cache lookup request. This metric can help you identify performance bottlenecks and optimize your cache configuration.

Cache latency is highly dependent on embedding model performance, since the cache must generate embeddings for each request in order to compare them to the cached responses.

High cache latency may indicate one of the following:

- Inefficient embedding generation from the embedding provider
- Large cache requiring longer comparison times
- Network latency between the cache and embedding provider
- Resource constraints


title: Use the LangCache API on Redis Cloud

title: Content

text:
You can use the [LangCache API and SDK]() from your client app to store and retrieve LLM, RAG, or agent responses.

To access the LangCache API, you need:

- LangCache API base URL
- LangCache service API key
- Cache ID

For LangCache on Redis Cloud, the base URL and cache ID are available in the LangCache service's **Configuration** page in the [**Connectivity** section]().

The LangCache API key is only available immediately after you create the LangCache service. If you lost this value, you will need to [replace the service API key]() to be able to use the LangCache API.

When you call the API, you need to pass the LangCache API key in the `Authorization` header as a Bearer token and the Cache ID as the `cacheId` path parameter.

See the [LangCache API and SDK examples]() for more information on how to use the LangCache API.