redis.clients.jedis.commands.ClusterCommands Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jedis_preview Show documentation
Show all versions of jedis_preview Show documentation
Jedis is a blazingly small and sane Redis java client.
The newest version!
package redis.clients.jedis.commands;
import java.util.List;
import java.util.Map;
import redis.clients.jedis.args.ClusterResetType;
import redis.clients.jedis.args.ClusterFailoverOption;
import redis.clients.jedis.resps.ClusterShardInfo;
public interface ClusterCommands {
String asking();
String readonly();
String readwrite();
String clusterNodes();
String clusterMeet(String ip, int port);
String clusterAddSlots(int... slots);
String clusterDelSlots(int... slots);
String clusterInfo();
List clusterGetKeysInSlot(int slot, int count);
List clusterGetKeysInSlotBinary(int slot, int count);
String clusterSetSlotNode(int slot, String nodeId);
String clusterSetSlotMigrating(int slot, String nodeId);
String clusterSetSlotImporting(int slot, String nodeId);
String clusterSetSlotStable(int slot);
String clusterForget(String nodeId);
String clusterFlushSlots();
long clusterKeySlot(String key);
long clusterCountFailureReports(String nodeId);
long clusterCountKeysInSlot(int slot);
String clusterSaveConfig();
/**
* Set a specific config epoch in a fresh node. It only works when the nodes' table
* of the node is empty or when the node current config epoch is zero.
* @param configEpoch
* @return OK
*/
String clusterSetConfigEpoch(long configEpoch);
/**
* Advance the cluster config epoch.
* @return BUMPED if the epoch was incremented, or STILL if the node already has the
* greatest config epoch in the cluster.
*/
String clusterBumpEpoch();
String clusterReplicate(String nodeId);
/**
* {@code CLUSTER SLAVES} command is deprecated since Redis 5.
*
* @deprecated Use {@link ClusterCommands#clusterReplicas(java.lang.String)}.
*/
@Deprecated
List clusterSlaves(String nodeId);
List clusterReplicas(String nodeId);
String clusterFailover();
String clusterFailover(ClusterFailoverOption failoverOption);
/**
* {@code CLUSTER SLOTS} command is deprecated since Redis 7.
*
* @deprecated Use {@link ClusterCommands#clusterShards()}.
*/
@Deprecated
List