Skip to content
This repository was archived by the owner on Jan 6, 2025. It is now read-only.

Redis Client

Matt Anger edited this page Mar 21, 2022 · 1 revision

We provide a wrapper around the Lettuce client for use with our config+Guice. Config looks something like this if you are using Yaml:

redis:
  friendlyname:
    uri: redis://127.0.0.1

This is a basic non-clustered redis-client that you can access when you inject a RedisContainer object like follows:

class MyClass(redisContainer: RedisContainer) {
  private val myRedisClient = redisContainer.redisClients.get("friendlyname")
}

The friendlyname is also what we will use when reporting metrics. The full list of configs we provide can be seen here.

Clone this wiki locally