Interface RedisConfig
@ConfigMapping(prefix="quarkus.redis")
@ConfigRoot(phase=RUN_TIME)
public interface RedisConfig
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionThe default redis clientstatic boolean
isDefaultClient
(String name) Configures additional (named) Redis clients.static String
propertyKey
(String name, String radical)
-
Field Details
-
REDIS_CONFIG_ROOT_NAME
- See Also:
-
HOSTS_CONFIG_NAME
- See Also:
-
DEFAULT_CLIENT_NAME
- See Also:
-
-
Method Details
-
defaultRedisClient
The default redis client -
namedRedisClients
@WithParentName @ConfigDocMapKey("redis-client-name") Map<String,RedisClientConfig> namedRedisClients()Configures additional (named) Redis clients.Each client has a unique name which must be identified to select the right client. For example:
quarkus.redis.client1.hosts = redis://localhost:6379 quarkus.redis.client2.hosts = redis://localhost:6380
And then use the
RedisClientName
annotation to select theRedis
,Redis
,RedisAPI
andRedisAPI
beans.{ @code @RedisClientName("client1") @Inject RedisAPI redis; }
-
isDefaultClient
-
propertyKey
-