java.lang.Object
io.jooby.redis.RedisModule
- All Implemented Interfaces:
Extension
Redis module: https://jooby.io/modules/redis.
Usage:
{
install(new RedisModule());
get("/", ctx -> {
StatefulRedisConnection redis = require(StatefulRedisConnection.class);
// work with redis
});
}
application.conf:
redis = "redis://localhost:6379"Module is built on top of lettuce. Once installed you are able to work with:
- io.lettuce.core.RedisClient
- io.lettuce.core.api.StatefulRedisConnection
- io.lettuce.core.pubsub.StatefulRedisPubSubConnection
install(new RedisModule("redis://localhost:6379"));
- Since:
- 2.8.5
- Author:
- edgar
-
Constructor Details
-
RedisModule
Creates a new redis module. Value must be: - Valid redis URI; or - Property name- Parameters:
value
- Redis URI or property name.
-
RedisModule
public RedisModule()Create a new redis module. The application configuration file must have a redis property, like:redis = "redis://localhost:6379"
-
-
Method Details