Ce contenu n'est pas disponible dans la langue sélectionnée.
Chapter 6. Configuring Redis storage for rate limiting
To configure persistence for rate limit counters in a multicluster environment, you must configure the connection details for your shared Redis-based datastore. This datastore is used to persist shared rate limit counters for the Limitador component of Connectivity Link.
You must configure connection details for your shared Redis-based datastore on each OpenShift cluster that you want to use Connectivity Link for rate limiting.
Prerequisites
Procedure
Set the following environment variable to your shared Redis-based instance URL:
export REDIS_URL=rediss://user:xxxxxx@some-redis.com:10340
export REDIS_URL=rediss://user:xxxxxx@some-redis.com:10340
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Ensure that you include the appropriate URI scheme for your environment:
-
Secure Redis:
rediss://
-
Standard Redis:
redis://
-
Secure Redis:
Create a
Secret
resource for your Redis URL as follows:kubectl -n kuadrant-system create secret generic redis-config \ --from-literal=URL=$REDIS_URL
kubectl -n kuadrant-system create secret generic redis-config \ --from-literal=URL=$REDIS_URL
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Update your Limitador custom resource to use the secret that you created as follows:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Additional resources
For details on how to set up your shared Redis-based datastore, see your Redis-compatible product documentation: