Configure a Memorystore for Redis instance

In Application Design Center, you can configure a Memorystore for Redis instance to provide fully managed, scalable in-memory Redis caching for your Google Cloud applications without managing complex Redis deployments. You can customize the instance's component connections and configuration parameters based on the terraform-google-memorystore Terraform module on GitHub.

Component connections

The following table includes the components that you can connect to a Memorystore for Redis instance, and the resulting updates to your application and its generated Terraform code.

Connected component Application updates Background information

Compute Engine instance template

  • The Compute Engine instances can manage and cache data in the Memorystore for Redis instance.
  • The Memorystore for Redis connection information is added to the Compute Engine instance template metadata.
  • The roles/redis.editor role is granted to the Compute Engine service account.
Deployment options for Redis on Google Cloud

Service account

  • The service account can manage the Memorystore for Redis instance.
  • The roles/redis.editor role is granted to the service account.
Access control with Identity and Access Management (IAM)

Cloud Run

  • The Cloud Run service can cache data in the Memorystore for Redis instance.
  • The Memorystore for Redis connection information is added to the Cloud Run environment variables.
  • The roles/redis.editor role is granted to the Cloud Run service account.
Connecting to a Redis instance from a Cloud Run service

Required configuration parameters

If your template includes a Memorystore for Redis component, you must configure the following parameters before you deploy.

Parameter name Description and constraints Background information

Project ID

The project where you want to deploy the Memorystore for Redis resource.

Configure components

Region

locationId Regions and zones

Zone

locationId Regions and zones

Name

name Create and manage Redis instances

Optional configuration parameters

The following parameters are optional. To display advanced parameters, in the Configuration area, select Show advanced fields.

Feature Parameter name Description and constraint information Background information

Display Name

displayName Create and manage Redis instances

Tier

Tier Redis tier capabilities

Memory Size GB

memorySizeGb Capacity tiers

Redis Version

redisVersion Supported versions

Connect Mode

ConnectMode Connection modes

Replica Count

replicaCount About read replicas

Auth Enabled

authEnabled About Redis AUTH

Transit Encryption Mode

TransitEncryptionMode About in-transit encryption
Maintenance Policy

Description

description About maintenance on Memorystore for Redis
Maintenance Policy

Day

day About maintenance on Memorystore for Redis
Maintenance Policy

Hours

hours About maintenance on Memorystore for Redis
Maintenance Policy

Minutes

minutes About maintenance on Memorystore for Redis
Maintenance Policy

Seconds

seconds About maintenance on Memorystore for Redis
Maintenance Policy

Nanos

nanos About maintenance on Memorystore for Redis
Persistence Config

Persistence Mode

persistenceMode About RDB snapshots
Persistence Config

RDB Snapshot Period

rdbSnapshotPeriod About RDB snapshots

Read Replicas Mode

ReadReplicasMode About read replicas

Authorized Network

authorizedNetwork VPC networks

Enable APIs

By default, enables the redis.googleapis.com API.

Google Cloud Memorystore for Redis API

Alternative Location ID

alternativeLocationId Regions and zones

Reserved IP Range

reservedIpRange Creating a Redis instance with a specific IP address range

Secondary IP Range

secondaryIpRange Creating a Redis instance with a specific IP address range
Labels

Key

labels Overview of labels
Labels

Value

labels Overview of labels

Customer Managed Key

customerManagedKey About customer-managed encryption keys (CMEK)