+ * Production usage requires configuration of connection timeouts and connection pooling.
+ * @see JedisCluster For dedicated Redis Cluster support
+ * @see JedisSentineled For dedicated Redis Sentinel support
+ */
+public class UnifiedJedis implements JedisCommands, JedisBinaryCommands, SampleKeyedCommands,
+ SampleBinaryKeyedCommands, RedisModuleCommands, AutoCloseable {
@Deprecated
protected RedisProtocol protocol = null;
@@ -57,34 +102,49 @@ public class UnifiedJedis implements JedisCommands, JedisBinaryCommands,
private JedisBroadcastAndRoundRobinConfig broadcastAndRoundRobinConfig = null;
private final Cache cache;
+ /**
+ * Creates a UnifiedJedis instance with default host and port (localhost:6379).
+ */
public UnifiedJedis() {
this(new HostAndPort(Protocol.DEFAULT_HOST, Protocol.DEFAULT_PORT));
}
+ /**
+ * Creates a UnifiedJedis instance with the specified host and port.
+ * @param hostAndPort The host and port of the Redis server
+ */
public UnifiedJedis(HostAndPort hostAndPort) {
this(new PooledConnectionProvider(hostAndPort), (RedisProtocol) null);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified URL.
+ * @param url The URL of the Redis server (e.g., "redis://localhost:6379")
+ */
public UnifiedJedis(final String url) {
this(URI.create(url));
}
+ /**
+ * Creates a UnifiedJedis instance with the specified URI. The URI can include authentication
+ * information, database index, and SSL configuration.
+ * @param uri The URI of the Redis server (e.g., "redis://user:password@localhost:6379/1")
+ */
public UnifiedJedis(final URI uri) {
- this(JedisURIHelper.getHostAndPort(uri), DefaultJedisClientConfig.builder()
- .user(JedisURIHelper.getUser(uri)).password(JedisURIHelper.getPassword(uri))
- .database(JedisURIHelper.getDBIndex(uri)).protocol(JedisURIHelper.getRedisProtocol(uri))
- .ssl(JedisURIHelper.isRedisSSLScheme(uri)).build());
+ this(JedisURIHelper.getHostAndPort(uri),
+ DefaultJedisClientConfig.builder().user(JedisURIHelper.getUser(uri))
+ .password(JedisURIHelper.getPassword(uri)).database(JedisURIHelper.getDBIndex(uri))
+ .protocol(JedisURIHelper.getRedisProtocol(uri))
+ .ssl(JedisURIHelper.isRedisSSLScheme(uri)).build());
}
/**
- * Create a new UnifiedJedis with the provided URI and JedisClientConfig object. Note that all fields
- * that can be parsed from the URI will be used instead of the corresponding configuration values. This includes
- * the following fields: user, password, database, protocol version, and whether to use SSL.
- *
- * For example, if the URI is "redis://user:password@localhost:6379/1", the user and password fields will be set
- * to "user" and "password" respectively, the database field will be set to 1. Those fields will be ignored
- * from the JedisClientConfig object.
- *
+ * Create a new UnifiedJedis with the provided URI and JedisClientConfig object. Note that all
+ * fields that can be parsed from the URI will be used instead of the corresponding configuration
+ * values. This includes the following fields: user, password, database, protocol version, and
+ * whether to use SSL. For example, if the URI is "redis://user:password@localhost:6379/1", the
+ * user and password fields will be set to "user" and "password" respectively, the database field
+ * will be set to 1. Those fields will be ignored from the JedisClientConfig object.
* @param uri The URI to connect to
* @param config The JedisClientConfig object to use
*/
@@ -95,33 +155,70 @@ public UnifiedJedis(final URI uri, JedisClientConfig config) {
.blockingSocketTimeoutMillis(config.getBlockingSocketTimeoutMillis())
.user(JedisURIHelper.getUser(uri)).password(JedisURIHelper.getPassword(uri))
.database(JedisURIHelper.getDBIndex(uri)).clientName(config.getClientName())
- .protocol(JedisURIHelper.getRedisProtocol(uri))
- .ssl(JedisURIHelper.isRedisSSLScheme(uri)).sslSocketFactory(config.getSslSocketFactory())
- .sslParameters(config.getSslParameters()).hostnameVerifier(config.getHostnameVerifier()).build());
+ .protocol(JedisURIHelper.getRedisProtocol(uri)).ssl(JedisURIHelper.isRedisSSLScheme(uri))
+ .sslSocketFactory(config.getSslSocketFactory()).sslParameters(config.getSslParameters())
+ .hostnameVerifier(config.getHostnameVerifier()).build());
}
+ /**
+ * Creates a UnifiedJedis instance with the specified host, port, and client configuration.
+ * @param hostAndPort The host and port of the Redis server
+ * @param clientConfig The client configuration
+ */
public UnifiedJedis(HostAndPort hostAndPort, JedisClientConfig clientConfig) {
this(new PooledConnectionProvider(hostAndPort, clientConfig), clientConfig.getRedisProtocol());
}
+ /**
+ * Creates a UnifiedJedis instance with the specified host, port, client configuration, and cache
+ * configuration. This constructor enables client-side caching.
+ * @param hostAndPort The host and port of the Redis server
+ * @param clientConfig The client configuration
+ * @param cacheConfig The cache configuration
+ */
@Experimental
- public UnifiedJedis(HostAndPort hostAndPort, JedisClientConfig clientConfig, CacheConfig cacheConfig) {
+ public UnifiedJedis(HostAndPort hostAndPort, JedisClientConfig clientConfig,
+ CacheConfig cacheConfig) {
this(hostAndPort, clientConfig, CacheFactory.getCache(cacheConfig));
}
+ /**
+ * Creates a UnifiedJedis instance with the specified host, port, client configuration, and cache.
+ * This constructor enables client-side caching with a pre-configured cache.
+ * @param hostAndPort The host and port of the Redis server
+ * @param clientConfig The client configuration
+ * @param cache The pre-configured cache
+ */
@Experimental
public UnifiedJedis(HostAndPort hostAndPort, JedisClientConfig clientConfig, Cache cache) {
- this(new PooledConnectionProvider(hostAndPort, clientConfig, cache), clientConfig.getRedisProtocol(), cache);
+ this(new PooledConnectionProvider(hostAndPort, clientConfig, cache),
+ clientConfig.getRedisProtocol(), cache);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified connection provider.
+ * @param provider The connection provider
+ */
public UnifiedJedis(ConnectionProvider provider) {
this(new DefaultCommandExecutor(provider), provider);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified connection provider and Redis protocol.
+ * @param provider The connection provider
+ * @param protocol The Redis protocol version
+ */
protected UnifiedJedis(ConnectionProvider provider, RedisProtocol protocol) {
this(new DefaultCommandExecutor(provider), provider, new CommandObjects(), protocol);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified connection provider, Redis protocol, and
+ * cache. This constructor enables client-side caching.
+ * @param provider The connection provider
+ * @param protocol The Redis protocol version
+ * @param cache The cache
+ */
@Experimental
protected UnifiedJedis(ConnectionProvider provider, RedisProtocol protocol, Cache cache) {
this(new DefaultCommandExecutor(provider), provider, new CommandObjects(), protocol, cache);
@@ -168,54 +265,113 @@ public UnifiedJedis(Connection connection) {
}
}
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified nodes, client
+ * configuration, and retry attempts.
+ * @param jedisClusterNodes The set of cluster nodes
+ * @param clientConfig The client configuration
+ * @param maxAttempts The maximum number of retry attempts
+ * @deprecated Use constructor with explicit maxTotalRetriesDuration parameter
+ */
@Deprecated
- public UnifiedJedis(Set jedisClusterNodes, JedisClientConfig clientConfig, int maxAttempts) {
+ public UnifiedJedis(Set jedisClusterNodes, JedisClientConfig clientConfig,
+ int maxAttempts) {
this(jedisClusterNodes, clientConfig, maxAttempts,
Duration.ofMillis(maxAttempts * clientConfig.getSocketTimeoutMillis()));
}
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified nodes, client
+ * configuration, and retry parameters.
+ * @param jedisClusterNodes The set of cluster nodes
+ * @param clientConfig The client configuration
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ * @deprecated Use constructor with ClusterConnectionProvider
+ */
@Deprecated
- public UnifiedJedis(Set jedisClusterNodes, JedisClientConfig clientConfig, int maxAttempts,
- Duration maxTotalRetriesDuration) {
- this(new ClusterConnectionProvider(jedisClusterNodes, clientConfig), maxAttempts, maxTotalRetriesDuration,
- clientConfig.getRedisProtocol());
+ public UnifiedJedis(Set jedisClusterNodes, JedisClientConfig clientConfig,
+ int maxAttempts, Duration maxTotalRetriesDuration) {
+ this(new ClusterConnectionProvider(jedisClusterNodes, clientConfig), maxAttempts,
+ maxTotalRetriesDuration, clientConfig.getRedisProtocol());
}
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified nodes, client
+ * configuration, pool configuration, and retry parameters.
+ * @param jedisClusterNodes The set of cluster nodes
+ * @param clientConfig The client configuration
+ * @param poolConfig The connection pool configuration
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ * @deprecated Use constructor with ClusterConnectionProvider
+ */
@Deprecated
public UnifiedJedis(Set jedisClusterNodes, JedisClientConfig clientConfig,
- GenericObjectPoolConfig poolConfig, int maxAttempts, Duration maxTotalRetriesDuration) {
+ GenericObjectPoolConfig poolConfig, int maxAttempts,
+ Duration maxTotalRetriesDuration) {
this(new ClusterConnectionProvider(jedisClusterNodes, clientConfig, poolConfig), maxAttempts,
maxTotalRetriesDuration, clientConfig.getRedisProtocol());
}
- // Uses a fetched connection to process protocol. Should be avoided if possible.
- public UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts, Duration maxTotalRetriesDuration) {
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified connection provider and
+ * retry parameters. Uses a fetched connection to process protocol. Should be avoided if possible.
+ * @param provider The cluster connection provider
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ */
+ public UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts,
+ Duration maxTotalRetriesDuration) {
this(new ClusterCommandExecutor(provider, maxAttempts, maxTotalRetriesDuration), provider,
new ClusterCommandObjects());
}
- protected UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts, Duration maxTotalRetriesDuration,
- RedisProtocol protocol) {
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified connection provider,
+ * retry parameters, and protocol.
+ * @param provider The cluster connection provider
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ * @param protocol The Redis protocol version
+ */
+ protected UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts,
+ Duration maxTotalRetriesDuration, RedisProtocol protocol) {
this(new ClusterCommandExecutor(provider, maxAttempts, maxTotalRetriesDuration), provider,
new ClusterCommandObjects(), protocol);
}
+ /**
+ * Creates a UnifiedJedis instance for a Redis Cluster with the specified connection provider,
+ * retry parameters, protocol, and cache. This constructor enables client-side caching.
+ * @param provider The cluster connection provider
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ * @param protocol The Redis protocol version
+ * @param cache The cache
+ */
@Experimental
- protected UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts, Duration maxTotalRetriesDuration,
- RedisProtocol protocol, Cache cache) {
+ protected UnifiedJedis(ClusterConnectionProvider provider, int maxAttempts,
+ Duration maxTotalRetriesDuration, RedisProtocol protocol, Cache cache) {
this(new ClusterCommandExecutor(provider, maxAttempts, maxTotalRetriesDuration), provider,
new ClusterCommandObjects(), protocol, cache);
}
/**
+ * Creates a UnifiedJedis instance with a sharded connection provider.
+ * @param provider The sharded connection provider
* @deprecated Sharding/Sharded feature will be removed in next major release.
*/
@Deprecated
public UnifiedJedis(ShardedConnectionProvider provider) {
- this(new DefaultCommandExecutor(provider), provider, new ShardedCommandObjects(provider.getHashingAlgo()));
+ this(new DefaultCommandExecutor(provider), provider,
+ new ShardedCommandObjects(provider.getHashingAlgo()));
}
/**
+ * Creates a UnifiedJedis instance with a sharded connection provider and tag pattern.
+ * @param provider The sharded connection provider
+ * @param tagPattern The pattern for extracting key tags
* @deprecated Sharding/Sharded feature will be removed in next major release.
*/
@Deprecated
@@ -224,16 +380,25 @@ public UnifiedJedis(ShardedConnectionProvider provider, Pattern tagPattern) {
new ShardedCommandObjects(provider.getHashingAlgo(), tagPattern));
}
- public UnifiedJedis(ConnectionProvider provider, int maxAttempts, Duration maxTotalRetriesDuration) {
+ /**
+ * Creates a UnifiedJedis instance with the specified connection provider and retry parameters.
+ * @param provider The connection provider
+ * @param maxAttempts The maximum number of retry attempts
+ * @param maxTotalRetriesDuration The maximum total duration for retries
+ */
+ public UnifiedJedis(ConnectionProvider provider, int maxAttempts,
+ Duration maxTotalRetriesDuration) {
this(new RetryableCommandExecutor(provider, maxAttempts, maxTotalRetriesDuration), provider);
}
/**
- * Constructor which supports multiple cluster/database endpoints each with their own isolated connection pool.
- *
- * With this Constructor users can seamlessly failover to Disaster Recovery (DR), Backup, and Active-Active cluster(s)
- * by using simple configuration which is passed through from Resilience4j - https://resilience4j.readme.io/docs
+ * Constructor which supports multiple cluster/database endpoints each with their own isolated
+ * connection pool.
*
+ * With this Constructor users can seamlessly failover to Disaster Recovery (DR), Backup, and
+ * Active-Active cluster(s) by using simple configuration which is passed through from
+ * Resilience4j - https://resilience4j.readme.io/docs
+ * @param provider The multi-cluster pooled connection provider
*/
@Experimental
public UnifiedJedis(MultiClusterPooledConnectionProvider provider) {
@@ -250,13 +415,25 @@ public UnifiedJedis(CommandExecutor executor) {
this(executor, (ConnectionProvider) null);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified command executor and connection provider.
+ * @param executor The command executor
+ * @param provider The connection provider
+ */
private UnifiedJedis(CommandExecutor executor, ConnectionProvider provider) {
this(executor, provider, new CommandObjects());
}
- // Uses a fetched connection to process protocol. Should be avoided if possible.
+ /**
+ * Creates a UnifiedJedis instance with the specified command executor, connection provider, and
+ * command objects. Uses a fetched connection to process protocol. Should be avoided if possible.
+ * @param executor The command executor
+ * @param provider The connection provider
+ * @param commandObjects The command objects
+ */
@VisibleForTesting
- public UnifiedJedis(CommandExecutor executor, ConnectionProvider provider, CommandObjects commandObjects) {
+ public UnifiedJedis(CommandExecutor executor, ConnectionProvider provider,
+ CommandObjects commandObjects) {
this(executor, provider, commandObjects, null, null);
if (this.provider != null) {
try (Connection conn = this.provider.getConnection()) {
@@ -271,15 +448,33 @@ public UnifiedJedis(CommandExecutor executor, ConnectionProvider provider, Comma
}
}
+ /**
+ * Creates a UnifiedJedis instance with the specified command executor, connection provider,
+ * command objects, and protocol.
+ * @param executor The command executor
+ * @param provider The connection provider
+ * @param commandObjects The command objects
+ * @param protocol The Redis protocol version
+ */
@Experimental
- private UnifiedJedis(CommandExecutor executor, ConnectionProvider provider, CommandObjects commandObjects,
- RedisProtocol protocol) {
+ private UnifiedJedis(CommandExecutor executor, ConnectionProvider provider,
+ CommandObjects commandObjects, RedisProtocol protocol) {
this(executor, provider, commandObjects, protocol, (Cache) null);
}
+ /**
+ * Creates a UnifiedJedis instance with the specified command executor, connection provider,
+ * command objects, protocol, and cache. This constructor enables client-side caching.
+ * @param executor The command executor
+ * @param provider The connection provider
+ * @param commandObjects The command objects
+ * @param protocol The Redis protocol version
+ * @param cache The cache
+ * @throws IllegalArgumentException if cache is provided but protocol is not RESP3
+ */
@Experimental
- private UnifiedJedis(CommandExecutor executor, ConnectionProvider provider, CommandObjects commandObjects,
- RedisProtocol protocol, Cache cache) {
+ private UnifiedJedis(CommandExecutor executor, ConnectionProvider provider,
+ CommandObjects commandObjects, RedisProtocol protocol, Cache cache) {
if (cache != null && protocol != RedisProtocol.RESP3) {
throw new IllegalArgumentException("Client-side caching is only supported with RESP3.");
@@ -322,8 +517,8 @@ private T checkAndBroadcastCommand(CommandObject commandObject) {
} else if (commandObject.getArguments().getCommand() instanceof SearchProtocol.SearchCommand
&& broadcastAndRoundRobinConfig
.getRediSearchModeInCluster() == JedisBroadcastAndRoundRobinConfig.RediSearchMode.LIGHT) {
- broadcast = false;
- }
+ broadcast = false;
+ }
return broadcast ? broadcastCommand(commandObject) : executeCommand(commandObject);
}
@@ -1413,7 +1608,8 @@ public String lmove(String srcKey, String dstKey, ListDirection from, ListDirect
}
@Override
- public String blmove(String srcKey, String dstKey, ListDirection from, ListDirection to, double timeout) {
+ public String blmove(String srcKey, String dstKey, ListDirection from, ListDirection to,
+ double timeout) {
return executeCommand(commandObjects.blmove(srcKey, dstKey, from, to, timeout));
}
@@ -1423,7 +1619,8 @@ public byte[] lmove(byte[] srcKey, byte[] dstKey, ListDirection from, ListDirect
}
@Override
- public byte[] blmove(byte[] srcKey, byte[] dstKey, ListDirection from, ListDirection to, double timeout) {
+ public byte[] blmove(byte[] srcKey, byte[] dstKey, ListDirection from, ListDirection to,
+ double timeout) {
return executeCommand(commandObjects.blmove(srcKey, dstKey, from, to, timeout));
}
@@ -1438,12 +1635,14 @@ public KeyValue> lmpop(ListDirection direction, int count,
}
@Override
- public KeyValue> blmpop(double timeout, ListDirection direction, String... keys) {
+ public KeyValue> blmpop(double timeout, ListDirection direction,
+ String... keys) {
return executeCommand(commandObjects.blmpop(timeout, direction, keys));
}
@Override
- public KeyValue> blmpop(double timeout, ListDirection direction, int count, String... keys) {
+ public KeyValue> blmpop(double timeout, ListDirection direction, int count,
+ String... keys) {
return executeCommand(commandObjects.blmpop(timeout, direction, count, keys));
}
@@ -1458,12 +1657,14 @@ public KeyValue> lmpop(ListDirection direction, int count,
}
@Override
- public KeyValue> blmpop(double timeout, ListDirection direction, byte[]... keys) {
+ public KeyValue> blmpop(double timeout, ListDirection direction,
+ byte[]... keys) {
return executeCommand(commandObjects.blmpop(timeout, direction, keys));
}
@Override
- public KeyValue> blmpop(double timeout, ListDirection direction, int count, byte[]... keys) {
+ public KeyValue> blmpop(double timeout, ListDirection direction, int count,
+ byte[]... keys) {
return executeCommand(commandObjects.blmpop(timeout, direction, count, keys));
}
// List commands
@@ -1481,19 +1682,19 @@ public long hset(String key, Map hash) {
@Override
public long hsetex(String key, HSetExParams params, String field, String value) {
- return executeCommand(commandObjects.hsetex(key, params, field, value));
+ return executeCommand(commandObjects.hsetex(key, params, field, value));
}
@Override
public long hsetex(String key, HSetExParams params, Map hash) {
return executeCommand(commandObjects.hsetex(key, params, hash));
}
-
+
@Override
public String hget(String key, String field) {
return executeCommand(commandObjects.hget(key, field));
}
-
+
@Override
public List hgetex(String key, HGetExParams params, String... fields) {
return executeCommand(commandObjects.hgetex(key, params, fields));
@@ -1531,7 +1732,7 @@ public long hset(byte[] key, Map hash) {
@Override
public long hsetex(byte[] key, HSetExParams params, byte[] field, byte[] value) {
- return executeCommand(commandObjects.hsetex(key, params, field, value));
+ return executeCommand(commandObjects.hsetex(key, params, field, value));
}
@Override
@@ -1548,7 +1749,7 @@ public byte[] hget(byte[] key, byte[] field) {
public List hgetex(byte[] key, HGetExParams params, byte[]... fields) {
return executeCommand(commandObjects.hgetex(key, params, fields));
}
-
+
@Override
public List hgetdel(byte[] key, byte[]... fields) {
return executeCommand(commandObjects.hgetdel(key, fields));
@@ -1725,7 +1926,8 @@ public List hpexpire(String key, long milliseconds, String... fields) {
}
@Override
- public List hpexpire(String key, long milliseconds, ExpiryOption condition, String... fields) {
+ public List hpexpire(String key, long milliseconds, ExpiryOption condition,
+ String... fields) {
return executeCommand(commandObjects.hpexpire(key, milliseconds, condition, fields));
}
@@ -1735,7 +1937,8 @@ public List hexpireAt(String key, long unixTimeSeconds, String... fields)
}
@Override
- public List hexpireAt(String key, long unixTimeSeconds, ExpiryOption condition, String... fields) {
+ public List hexpireAt(String key, long unixTimeSeconds, ExpiryOption condition,
+ String... fields) {
return executeCommand(commandObjects.hexpireAt(key, unixTimeSeconds, condition, fields));
}
@@ -1745,7 +1948,8 @@ public List hpexpireAt(String key, long unixTimeMillis, String... fields)
}
@Override
- public List hpexpireAt(String key, long unixTimeMillis, ExpiryOption condition, String... fields) {
+ public List hpexpireAt(String key, long unixTimeMillis, ExpiryOption condition,
+ String... fields) {
return executeCommand(commandObjects.hpexpireAt(key, unixTimeMillis, condition, fields));
}
@@ -1765,7 +1969,8 @@ public List hpexpire(byte[] key, long milliseconds, byte[]... fields) {
}
@Override
- public List hpexpire(byte[] key, long milliseconds, ExpiryOption condition, byte[]... fields) {
+ public List hpexpire(byte[] key, long milliseconds, ExpiryOption condition,
+ byte[]... fields) {
return executeCommand(commandObjects.hpexpire(key, milliseconds, condition, fields));
}
@@ -1775,7 +1980,8 @@ public List hexpireAt(byte[] key, long unixTimeSeconds, byte[]... fields)
}
@Override
- public List hexpireAt(byte[] key, long unixTimeSeconds, ExpiryOption condition, byte[]... fields) {
+ public List hexpireAt(byte[] key, long unixTimeSeconds, ExpiryOption condition,
+ byte[]... fields) {
return executeCommand(commandObjects.hexpireAt(key, unixTimeSeconds, condition, fields));
}
@@ -1785,7 +1991,8 @@ public List hpexpireAt(byte[] key, long unixTimeMillis, byte[]... fields)
}
@Override
- public List hpexpireAt(byte[] key, long unixTimeMillis, ExpiryOption condition, byte[]... fields) {
+ public List hpexpireAt(byte[] key, long unixTimeMillis, ExpiryOption condition,
+ byte[]... fields) {
return executeCommand(commandObjects.hpexpireAt(key, unixTimeMillis, condition, fields));
}
@@ -2364,7 +2571,8 @@ public List zrevrangeByScoreWithScores(String key, double max, double min
}
@Override
- public List zrangeByScoreWithScores(String key, double min, double max, int offset, int count) {
+ public List zrangeByScoreWithScores(String key, double min, double max, int offset,
+ int count) {
return executeCommand(commandObjects.zrangeByScoreWithScores(key, min, max, offset, count));
}
@@ -2384,17 +2592,20 @@ public List zrevrangeByScoreWithScores(String key, String max, String min
}
@Override
- public List zrangeByScoreWithScores(String key, String min, String max, int offset, int count) {
+ public List zrangeByScoreWithScores(String key, String min, String max, int offset,
+ int count) {
return executeCommand(commandObjects.zrangeByScoreWithScores(key, min, max, offset, count));
}
@Override
- public List zrevrangeByScoreWithScores(String key, double max, double min, int offset, int count) {
+ public List zrevrangeByScoreWithScores(String key, double max, double min, int offset,
+ int count) {
return executeCommand(commandObjects.zrevrangeByScoreWithScores(key, max, min, offset, count));
}
@Override
- public List zrevrangeByScoreWithScores(String key, String max, String min, int offset, int count) {
+ public List zrevrangeByScoreWithScores(String key, String max, String min, int offset,
+ int count) {
return executeCommand(commandObjects.zrevrangeByScoreWithScores(key, max, min, offset, count));
}
@@ -2479,7 +2690,8 @@ public List zrevrangeByScoreWithScores(byte[] key, double max, double min
}
@Override
- public List zrangeByScoreWithScores(byte[] key, double min, double max, int offset, int count) {
+ public List zrangeByScoreWithScores(byte[] key, double min, double max, int offset,
+ int count) {
return executeCommand(commandObjects.zrangeByScoreWithScores(key, min, max, offset, count));
}
@@ -2499,17 +2711,20 @@ public List zrevrangeByScoreWithScores(byte[] key, byte[] max, byte[] min
}
@Override
- public List zrangeByScoreWithScores(byte[] key, byte[] min, byte[] max, int offset, int count) {
+ public List zrangeByScoreWithScores(byte[] key, byte[] min, byte[] max, int offset,
+ int count) {
return executeCommand(commandObjects.zrangeByScoreWithScores(key, min, max, offset, count));
}
@Override
- public List zrevrangeByScoreWithScores(byte[] key, double max, double min, int offset, int count) {
+ public List zrevrangeByScoreWithScores(byte[] key, double max, double min, int offset,
+ int count) {
return executeCommand(commandObjects.zrevrangeByScoreWithScores(key, max, min, offset, count));
}
@Override
- public List zrevrangeByScoreWithScores(byte[] key, byte[] max, byte[] min, int offset, int count) {
+ public List zrevrangeByScoreWithScores(byte[] key, byte[] max, byte[] min, int offset,
+ int count) {
return executeCommand(commandObjects.zrevrangeByScoreWithScores(key, max, min, offset, count));
}
@@ -2786,12 +3001,14 @@ public KeyValue> zmpop(SortedSetOption option, int count, St
}
@Override
- public KeyValue> bzmpop(double timeout, SortedSetOption option, String... keys) {
+ public KeyValue> bzmpop(double timeout, SortedSetOption option,
+ String... keys) {
return executeCommand(commandObjects.bzmpop(timeout, option, keys));
}
@Override
- public KeyValue> bzmpop(double timeout, SortedSetOption option, int count, String... keys) {
+ public KeyValue> bzmpop(double timeout, SortedSetOption option, int count,
+ String... keys) {
return executeCommand(commandObjects.bzmpop(timeout, option, count, keys));
}
@@ -2806,12 +3023,14 @@ public KeyValue> zmpop(SortedSetOption option, int count, by
}
@Override
- public KeyValue> bzmpop(double timeout, SortedSetOption option, byte[]... keys) {
+ public KeyValue> bzmpop(double timeout, SortedSetOption option,
+ byte[]... keys) {
return executeCommand(commandObjects.bzmpop(timeout, option, keys));
}
@Override
- public KeyValue> bzmpop(double timeout, SortedSetOption option, int count, byte[]... keys) {
+ public KeyValue> bzmpop(double timeout, SortedSetOption option, int count,
+ byte[]... keys) {
return executeCommand(commandObjects.bzmpop(timeout, option, count, keys));
}
// Sorted Set commands
@@ -2828,7 +3047,8 @@ public long geoadd(String key, Map memberCoordinateMap) {
}
@Override
- public long geoadd(String key, GeoAddParams params, Map memberCoordinateMap) {
+ public long geoadd(String key, GeoAddParams params,
+ Map memberCoordinateMap) {
return executeCommand(commandObjects.geoadd(key, params, memberCoordinateMap));
}
@@ -2863,7 +3083,8 @@ public long geoadd(byte[] key, Map memberCoordinateMap) {
}
@Override
- public long geoadd(byte[] key, GeoAddParams params, Map memberCoordinateMap) {
+ public long geoadd(byte[] key, GeoAddParams params,
+ Map memberCoordinateMap) {
return executeCommand(commandObjects.geoadd(key, params, memberCoordinateMap));
}
@@ -2888,53 +3109,67 @@ public List geopos(byte[] key, byte[]... members) {
}
@Override
- public List georadius(String key, double longitude, double latitude, double radius, GeoUnit unit) {
+ public List georadius(String key, double longitude, double latitude,
+ double radius, GeoUnit unit) {
return executeCommand(commandObjects.georadius(key, longitude, latitude, radius, unit));
}
@Override
- public List georadiusReadonly(String key, double longitude, double latitude, double radius, GeoUnit unit) {
+ public List georadiusReadonly(String key, double longitude, double latitude,
+ double radius, GeoUnit unit) {
return executeCommand(commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit));
}
@Override
- public List georadius(String key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param) {
+ public List georadius(String key, double longitude, double latitude,
+ double radius, GeoUnit unit, GeoRadiusParam param) {
return executeCommand(commandObjects.georadius(key, longitude, latitude, radius, unit, param));
}
@Override
- public List georadiusReadonly(String key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param) {
- return executeCommand(commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit, param));
+ public List georadiusReadonly(String key, double longitude, double latitude,
+ double radius, GeoUnit unit, GeoRadiusParam param) {
+ return executeCommand(
+ commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit, param));
}
@Override
- public List georadiusByMember(String key, String member, double radius, GeoUnit unit) {
+ public List georadiusByMember(String key, String member, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.georadiusByMember(key, member, radius, unit));
}
@Override
- public List georadiusByMemberReadonly(String key, String member, double radius, GeoUnit unit) {
+ public List georadiusByMemberReadonly(String key, String member, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.georadiusByMemberReadonly(key, member, radius, unit));
}
@Override
- public List georadiusByMember(String key, String member, double radius, GeoUnit unit, GeoRadiusParam param) {
+ public List georadiusByMember(String key, String member, double radius,
+ GeoUnit unit, GeoRadiusParam param) {
return executeCommand(commandObjects.georadiusByMember(key, member, radius, unit, param));
}
@Override
- public List georadiusByMemberReadonly(String key, String member, double radius, GeoUnit unit, GeoRadiusParam param) {
- return executeCommand(commandObjects.georadiusByMemberReadonly(key, member, radius, unit, param));
+ public List georadiusByMemberReadonly(String key, String member, double radius,
+ GeoUnit unit, GeoRadiusParam param) {
+ return executeCommand(
+ commandObjects.georadiusByMemberReadonly(key, member, radius, unit, param));
}
@Override
- public long georadiusStore(String key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
- return executeCommand(commandObjects.georadiusStore(key, longitude, latitude, radius, unit, param, storeParam));
+ public long georadiusStore(String key, double longitude, double latitude, double radius,
+ GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
+ return executeCommand(
+ commandObjects.georadiusStore(key, longitude, latitude, radius, unit, param, storeParam));
}
@Override
- public long georadiusByMemberStore(String key, String member, double radius, GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
- return executeCommand(commandObjects.georadiusByMemberStore(key, member, radius, unit, param, storeParam));
+ public long georadiusByMemberStore(String key, String member, double radius, GeoUnit unit,
+ GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
+ return executeCommand(
+ commandObjects.georadiusByMemberStore(key, member, radius, unit, param, storeParam));
}
@Override
@@ -2943,17 +3178,20 @@ public List geosearch(String key, String member, double radiu
}
@Override
- public List geosearch(String key, GeoCoordinate coord, double radius, GeoUnit unit) {
+ public List geosearch(String key, GeoCoordinate coord, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, coord, radius, unit));
}
@Override
- public List geosearch(String key, String member, double width, double height, GeoUnit unit) {
+ public List geosearch(String key, String member, double width, double height,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, member, width, height, unit));
}
@Override
- public List geosearch(String key, GeoCoordinate coord, double width, double height, GeoUnit unit) {
+ public List geosearch(String key, GeoCoordinate coord, double width,
+ double height, GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, coord, width, height, unit));
}
@@ -2968,17 +3206,20 @@ public long geosearchStore(String dest, String src, String member, double radius
}
@Override
- public long geosearchStore(String dest, String src, GeoCoordinate coord, double radius, GeoUnit unit) {
+ public long geosearchStore(String dest, String src, GeoCoordinate coord, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, coord, radius, unit));
}
@Override
- public long geosearchStore(String dest, String src, String member, double width, double height, GeoUnit unit) {
+ public long geosearchStore(String dest, String src, String member, double width, double height,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, member, width, height, unit));
}
@Override
- public long geosearchStore(String dest, String src, GeoCoordinate coord, double width, double height, GeoUnit unit) {
+ public long geosearchStore(String dest, String src, GeoCoordinate coord, double width,
+ double height, GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, coord, width, height, unit));
}
@@ -2993,53 +3234,67 @@ public long geosearchStoreStoreDist(String dest, String src, GeoSearchParam para
}
@Override
- public List georadius(byte[] key, double longitude, double latitude, double radius, GeoUnit unit) {
+ public List georadius(byte[] key, double longitude, double latitude,
+ double radius, GeoUnit unit) {
return executeCommand(commandObjects.georadius(key, longitude, latitude, radius, unit));
}
@Override
- public List georadiusReadonly(byte[] key, double longitude, double latitude, double radius, GeoUnit unit) {
+ public List georadiusReadonly(byte[] key, double longitude, double latitude,
+ double radius, GeoUnit unit) {
return executeCommand(commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit));
}
@Override
- public List georadius(byte[] key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param) {
+ public List georadius(byte[] key, double longitude, double latitude,
+ double radius, GeoUnit unit, GeoRadiusParam param) {
return executeCommand(commandObjects.georadius(key, longitude, latitude, radius, unit, param));
}
@Override
- public List georadiusReadonly(byte[] key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param) {
- return executeCommand(commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit, param));
+ public List georadiusReadonly(byte[] key, double longitude, double latitude,
+ double radius, GeoUnit unit, GeoRadiusParam param) {
+ return executeCommand(
+ commandObjects.georadiusReadonly(key, longitude, latitude, radius, unit, param));
}
@Override
- public List georadiusByMember(byte[] key, byte[] member, double radius, GeoUnit unit) {
+ public List georadiusByMember(byte[] key, byte[] member, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.georadiusByMember(key, member, radius, unit));
}
@Override
- public List georadiusByMemberReadonly(byte[] key, byte[] member, double radius, GeoUnit unit) {
+ public List georadiusByMemberReadonly(byte[] key, byte[] member, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.georadiusByMemberReadonly(key, member, radius, unit));
}
@Override
- public List georadiusByMember(byte[] key, byte[] member, double radius, GeoUnit unit, GeoRadiusParam param) {
+ public List georadiusByMember(byte[] key, byte[] member, double radius,
+ GeoUnit unit, GeoRadiusParam param) {
return executeCommand(commandObjects.georadiusByMember(key, member, radius, unit, param));
}
@Override
- public List georadiusByMemberReadonly(byte[] key, byte[] member, double radius, GeoUnit unit, GeoRadiusParam param) {
- return executeCommand(commandObjects.georadiusByMemberReadonly(key, member, radius, unit, param));
+ public List georadiusByMemberReadonly(byte[] key, byte[] member, double radius,
+ GeoUnit unit, GeoRadiusParam param) {
+ return executeCommand(
+ commandObjects.georadiusByMemberReadonly(key, member, radius, unit, param));
}
@Override
- public long georadiusStore(byte[] key, double longitude, double latitude, double radius, GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
- return executeCommand(commandObjects.georadiusStore(key, longitude, latitude, radius, unit, param, storeParam));
+ public long georadiusStore(byte[] key, double longitude, double latitude, double radius,
+ GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
+ return executeCommand(
+ commandObjects.georadiusStore(key, longitude, latitude, radius, unit, param, storeParam));
}
@Override
- public long georadiusByMemberStore(byte[] key, byte[] member, double radius, GeoUnit unit, GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
- return executeCommand(commandObjects.georadiusByMemberStore(key, member, radius, unit, param, storeParam));
+ public long georadiusByMemberStore(byte[] key, byte[] member, double radius, GeoUnit unit,
+ GeoRadiusParam param, GeoRadiusStoreParam storeParam) {
+ return executeCommand(
+ commandObjects.georadiusByMemberStore(key, member, radius, unit, param, storeParam));
}
@Override
@@ -3048,17 +3303,20 @@ public List geosearch(byte[] key, byte[] member, double radiu
}
@Override
- public List geosearch(byte[] key, GeoCoordinate coord, double radius, GeoUnit unit) {
+ public List geosearch(byte[] key, GeoCoordinate coord, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, coord, radius, unit));
}
@Override
- public List geosearch(byte[] key, byte[] member, double width, double height, GeoUnit unit) {
+ public List geosearch(byte[] key, byte[] member, double width, double height,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, member, width, height, unit));
}
@Override
- public List geosearch(byte[] key, GeoCoordinate coord, double width, double height, GeoUnit unit) {
+ public List geosearch(byte[] key, GeoCoordinate coord, double width,
+ double height, GeoUnit unit) {
return executeCommand(commandObjects.geosearch(key, coord, width, height, unit));
}
@@ -3073,17 +3331,20 @@ public long geosearchStore(byte[] dest, byte[] src, byte[] member, double radius
}
@Override
- public long geosearchStore(byte[] dest, byte[] src, GeoCoordinate coord, double radius, GeoUnit unit) {
+ public long geosearchStore(byte[] dest, byte[] src, GeoCoordinate coord, double radius,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, coord, radius, unit));
}
@Override
- public long geosearchStore(byte[] dest, byte[] src, byte[] member, double width, double height, GeoUnit unit) {
+ public long geosearchStore(byte[] dest, byte[] src, byte[] member, double width, double height,
+ GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, member, width, height, unit));
}
@Override
- public long geosearchStore(byte[] dest, byte[] src, GeoCoordinate coord, double width, double height, GeoUnit unit) {
+ public long geosearchStore(byte[] dest, byte[] src, GeoCoordinate coord, double width,
+ double height, GeoUnit unit) {
return executeCommand(commandObjects.geosearchStore(dest, src, coord, width, height, unit));
}
@@ -3172,7 +3433,8 @@ public List xrevrange(String key, StreamEntryID end, StreamEntryID
}
@Override
- public List xrevrange(String key, StreamEntryID end, StreamEntryID start, int count) {
+ public List xrevrange(String key, StreamEntryID end, StreamEntryID start,
+ int count) {
return executeCommand(commandObjects.xrevrange(key, end, start, count));
}
@@ -3252,23 +3514,31 @@ public long xtrim(String key, XTrimParams params) {
}
@Override
- public List xclaim(String key, String group, String consumerName, long minIdleTime, XClaimParams params, StreamEntryID... ids) {
- return executeCommand(commandObjects.xclaim(key, group, consumerName, minIdleTime, params, ids));
+ public List xclaim(String key, String group, String consumerName, long minIdleTime,
+ XClaimParams params, StreamEntryID... ids) {
+ return executeCommand(
+ commandObjects.xclaim(key, group, consumerName, minIdleTime, params, ids));
}
@Override
- public List xclaimJustId(String key, String group, String consumerName, long minIdleTime, XClaimParams params, StreamEntryID... ids) {
- return executeCommand(commandObjects.xclaimJustId(key, group, consumerName, minIdleTime, params, ids));
+ public List xclaimJustId(String key, String group, String consumerName,
+ long minIdleTime, XClaimParams params, StreamEntryID... ids) {
+ return executeCommand(
+ commandObjects.xclaimJustId(key, group, consumerName, minIdleTime, params, ids));
}
@Override
- public Map.Entry> xautoclaim(String key, String group, String consumerName, long minIdleTime, StreamEntryID start, XAutoClaimParams params) {
- return executeCommand(commandObjects.xautoclaim(key, group, consumerName, minIdleTime, start, params));
+ public Map.Entry> xautoclaim(String key, String group,
+ String consumerName, long minIdleTime, StreamEntryID start, XAutoClaimParams params) {
+ return executeCommand(
+ commandObjects.xautoclaim(key, group, consumerName, minIdleTime, start, params));
}
@Override
- public Map.Entry> xautoclaimJustId(String key, String group, String consumerName, long minIdleTime, StreamEntryID start, XAutoClaimParams params) {
- return executeCommand(commandObjects.xautoclaimJustId(key, group, consumerName, minIdleTime, start, params));
+ public Map.Entry> xautoclaimJustId(String key, String group,
+ String consumerName, long minIdleTime, StreamEntryID start, XAutoClaimParams params) {
+ return executeCommand(
+ commandObjects.xautoclaimJustId(key, group, consumerName, minIdleTime, start, params));
}
@Override
@@ -3302,23 +3572,29 @@ public List xinfoConsumers2(String key, String group) {
}
@Override
- public List>> xread(XReadParams xReadParams, Map streams) {
+ public List>> xread(XReadParams xReadParams,
+ Map streams) {
return executeCommand(commandObjects.xread(xReadParams, streams));
}
@Override
- public Map> xreadAsMap(XReadParams xReadParams, Map streams) {
+ public Map> xreadAsMap(XReadParams xReadParams,
+ Map streams) {
return executeCommand(commandObjects.xreadAsMap(xReadParams, streams));
}
@Override
- public List>> xreadGroup(String groupName, String consumer, XReadGroupParams xReadGroupParams, Map streams) {
- return executeCommand(commandObjects.xreadGroup(groupName, consumer, xReadGroupParams, streams));
+ public List>> xreadGroup(String groupName, String consumer,
+ XReadGroupParams xReadGroupParams, Map streams) {
+ return executeCommand(
+ commandObjects.xreadGroup(groupName, consumer, xReadGroupParams, streams));
}
@Override
- public Map> xreadGroupAsMap(String groupName, String consumer, XReadGroupParams xReadGroupParams, Map streams) {
- return executeCommand(commandObjects.xreadGroupAsMap(groupName, consumer, xReadGroupParams, streams));
+ public Map> xreadGroupAsMap(String groupName, String consumer,
+ XReadGroupParams xReadGroupParams, Map streams) {
+ return executeCommand(
+ commandObjects.xreadGroupAsMap(groupName, consumer, xReadGroupParams, streams));
}
@Override
@@ -3407,23 +3683,31 @@ public List