public class ClusterInfo extends Object
ClusterInfo
gives access to cluster information such as cluster_state
and
cluster_slots_assigned
provided by the CLUSTER INFO
command.Modifier and Type | Class and Description |
---|---|
static class |
ClusterInfo.Info |
Constructor and Description |
---|
ClusterInfo(Properties clusterProperties)
Creates new
ClusterInfo for given Properties . |
Modifier and Type | Method and Description |
---|---|
String |
get(ClusterInfo.Info info) |
String |
get(String key) |
Long |
getClusterSize() |
Long |
getCurrentEpoch() |
Long |
getKnownNodes() |
Long |
getMessagesReceived() |
Long |
getMessagesSent() |
Long |
getSlotsAssigned() |
Long |
getSlotsFail() |
Long |
getSlotsOk() |
Long |
getSlotsPfail() |
String |
getState() |
String |
toString() |
public ClusterInfo(Properties clusterProperties)
ClusterInfo
for given Properties
.clusterProperties
- must not be null.public String getState()
ClusterInfo.Info.STATE
public Long getSlotsAssigned()
ClusterInfo.Info.SLOTS_ASSIGNED
public Long getSlotsOk()
ClusterInfo.Info.SLOTS_OK
public Long getSlotsPfail()
ClusterInfo.Info.SLOTS_PFAIL
public Long getSlotsFail()
ClusterInfo.Info.SLOTS_FAIL
public Long getKnownNodes()
ClusterInfo.Info.KNOWN_NODES
public Long getClusterSize()
ClusterInfo.Info.SIZE
public Long getCurrentEpoch()
ClusterInfo.Info.CURRENT_EPOCH
public Long getMessagesSent()
ClusterInfo.Info.MESSAGES_SENT
public Long getMessagesReceived()
ClusterInfo.Info.MESSAGES_RECEIVED
public String get(ClusterInfo.Info info)
info
- must not be nullRedisClientInfo.INFO
.public String get(String key)
key
- must not be null or empty.key
.Copyright © 2011-2016–2016 Pivotal Software, Inc.. All rights reserved.