Issue
You want to know what changes you must make for the upcoming changes to REDIS_URL
.
Resolution
We changed the REDIS_URL
config var to be the secure TLS connection URL for all mini
Heroku Key-Value Store add-on plans. We'll begin rolling REDIS_URL config vars for mini add-on plans to the TLS connection.
If you previously transferred your REDIS_URL
configuration to REDIS_TEMPORARY_URL
to prepare your app for supporting TLS, you must use REDIS_URL
by December 2, 2024. By that date, all Redis connections will require TLS, and REDIS_TEMPORARY_URL
and REDIS_TLS_URL
will reach end-of-life.
Many language clients support both rediss://
and redis://
for TLS connections. You can test with REDIS_TLS_URL
today on a test app with your client to see if rediss://
or redis://
are compatible. If your test app is compatible with your client, then no change is necessary. See Connecting to Heroku Key-Value Store on how to connect to your Key-Value Store instance.
Here are the recommended application changes on mini
plans:
-
REDIS_URL
-->REDIS_TEMPORARY_URL
: If you must keep your insecure connections to plan for updating your Redis client configurations to support TLS, use this config var to prepare your app for supporting TLS. -
REDIS_TEMPORARY_URL
-->REDIS_URL
: BeforeREDIS_TEMPORARY_URL
is no longer available on December 2, 2024, use this config var when TLS becomes the required and default connection and your app supports TLS andrediss://
. -
REDIS_TLS_URL
-->REDIS_URL
: After September 30, 2024,REDIS_URL
becomes the secure TLS connection URL. Use this config var beforeREDIS_TLS_URL
is deprecated on December 2, 2024.
Preparing for the change
Ensure all libraries that connect to Redis, such as redis, are updated. You must also deactivate SSL verification for the mini
instance connections. For details, see Connecting to Heroku Key-Value Store.
Before December 2nd, we suggest you ensure that your application can connect to a Redis TLS connection in a staging application. Here is an example of that for a Ruby on Rails application:
# config/application.rb
if redis_url = ENV["REDIS_TLS_URL"]
ENV["REDIS_URL"] = redis_url
warn "Using secure redis URL"
else
warn "No REDIS_TLS_URL environment variable set"
end
If your application can connect and run to the secure URL on the REDIS_TLS_URL
environment variable, it will be prepared for this change.