Package redis.clients.jedis.commands
Interface ClusterCommands
- All Known Implementing Classes:
Jedis
public interface ClusterCommands
-
Method Summary
Modifier and TypeMethodDescriptionasking()clusterAddSlots(int... slots) clusterAddSlotsRange(int... ranges) Takes a list of slot ranges (specified by start and end slots) to assign to the nodeAdvance the cluster config epoch.longclusterCountFailureReports(String nodeId) longclusterCountKeysInSlot(int slot) clusterDelSlots(int... slots) clusterDelSlotsRange(int... ranges) Takes a list of slot ranges (specified by start and end slots) to remove to the node.clusterFailover(ClusterFailoverOption failoverOption) clusterForget(String nodeId) clusterGetKeysInSlot(int slot, int count) List<byte[]> clusterGetKeysInSlotBinary(int slot, int count) longclusterKeySlot(String key) return the information of all such peer links as an array, where each array element is a map that contains attributes and their values for an individual link.clusterMeet(String ip, int port) clusterReplicas(String nodeId) clusterReplicate(String nodeId) clusterReset(ClusterResetType resetType) resetTypecan be null for default behavior.clusterSetConfigEpoch(long configEpoch) Set a specific config epoch in a fresh node.clusterSetSlotImporting(int slot, String nodeId) clusterSetSlotMigrating(int slot, String nodeId) clusterSetSlotNode(int slot, String nodeId) clusterSetSlotStable(int slot) clusterSlaves(String nodeId) Deprecated.readonly()
-
Method Details
-
asking
String asking() -
readonly
String readonly() -
readwrite
String readwrite() -
clusterNodes
String clusterNodes() -
clusterMeet
-
clusterAddSlots
-
clusterDelSlots
-
clusterInfo
String clusterInfo() -
clusterGetKeysInSlot
-
clusterGetKeysInSlotBinary
-
clusterSetSlotNode
-
clusterSetSlotMigrating
-
clusterSetSlotImporting
-
clusterSetSlotStable
-
clusterForget
-
clusterFlushSlots
String clusterFlushSlots() -
clusterKeySlot
-
clusterCountFailureReports
-
clusterCountKeysInSlot
long clusterCountKeysInSlot(int slot) -
clusterSaveConfig
String clusterSaveConfig() -
clusterSetConfigEpoch
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.- Parameters:
configEpoch-- Returns:
- OK
-
clusterBumpEpoch
String clusterBumpEpoch()Advance the cluster config epoch.- Returns:
- BUMPED if the epoch was incremented, or STILL if the node already has the greatest config epoch in the cluster.
-
clusterReplicate
-
clusterSlaves
Deprecated.CLUSTER SLAVEScommand is deprecated since Redis 5. -
clusterReplicas
-
clusterFailover
String clusterFailover() -
clusterFailover
-
clusterSlots
-
clusterReset
String clusterReset() -
clusterReset
resetTypecan be null for default behavior.- Parameters:
resetType-- Returns:
- OK
-
clusterMyId
String clusterMyId() -
clusterMyShardId
String clusterMyShardId() -
clusterLinks
return the information of all such peer links as an array, where each array element is a map that contains attributes and their values for an individual link.- Returns:
- the information of all such peer links as an array
- See Also:
-
clusterAddSlotsRange
Takes a list of slot ranges (specified by start and end slots) to assign to the node- Parameters:
ranges- slots range- Returns:
- OK if the command was successful. Otherwise an error is returned.
-
clusterDelSlotsRange
Takes a list of slot ranges (specified by start and end slots) to remove to the node.- Parameters:
ranges- slots range- Returns:
- OK if the command was successful. Otherwise an error is returned.
-
clusterReplicas(java.lang.String).