io.quarkus.redis.client.RedisClientName Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of quarkus-redis-client Show documentation
Show all versions of quarkus-redis-client Show documentation
Connect to Redis in either imperative or reactive style
package io.quarkus.redis.client;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import javax.inject.Qualifier;
/**
* Marker annotation to select the Redis client.
*
* For example, if the Redis connection is configured like so in {@code application.properties}:
*
*
* quarkus.redis.client1.hosts=localhost:6379
*
*
* Then to inject the proper {@code redisClient}, you would need to use {@code RedisClientName} like indicated below:
*
*
* @Inject
* @RedisClientName("client1")
* RedisClient client;
*
*/
@Target({ ElementType.TYPE, ElementType.METHOD, ElementType.FIELD, ElementType.PARAMETER })
@Retention(RUNTIME)
@Documented
@Qualifier
public @interface RedisClientName {
/**
* The Redis client name.
*/
String value() default "";
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy