Documentation
¶
Index ¶
Constants ¶
const ( LocalStrategy = "org.apache.cassandra.locator.LocalStrategy" SimpleStrategy = "org.apache.cassandra.locator.SimpleStrategy" NetworkTopologyStrategy = "org.apache.cassandra.locator.NetworkTopologyStrategy" )
Replication strategies
const (
Murmur3Partitioner = "org.apache.cassandra.dht.Murmur3Partitioner"
)
Partitioners
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) HostDatacenter ¶
HostDatacenter looks up the datacenter that the given host belongs to.
type CommandStatus ¶
type CommandStatus string
CommandStatus specifies a result of a command
const ( CommandRunning CommandStatus = "RUNNING" CommandSuccessful CommandStatus = "SUCCESSFUL" CommandFailed CommandStatus = "FAILED" )
Command statuses
type NodeState ¶
type NodeState string
NodeState represents nodetool State=Normal/Leaving/Joining/Moving
type NodeStatus ¶
type NodeStatus bool
NodeStatus represents nodetool Status=Up/Down.
const ( NodeStatusUp NodeStatus = true NodeStatusDown NodeStatus = false )
NodeStatus enumeration
func (NodeStatus) String ¶
func (s NodeStatus) String() string
type NodeStatusInfo ¶
type NodeStatusInfo struct { Datacenter string HostID string Addr string Status NodeStatus State NodeState }
NodeStatusInfo represents a nodetool status line.
func (NodeStatusInfo) IsUN ¶
func (s NodeStatusInfo) IsUN() bool
IsUN returns true if host is Up and NORMAL meaning it's a fully functional live node.
type NodeStatusInfoSlice ¶
type NodeStatusInfoSlice []NodeStatusInfo
NodeStatusInfoSlice adds functionality to Status response.
func (NodeStatusInfoSlice) Datacenter ¶
func (s NodeStatusInfoSlice) Datacenter(dcs []string) NodeStatusInfoSlice
Datacenter resturns sub slice containing only nodes from given datacenters.
func (NodeStatusInfoSlice) DownHosts ¶
func (s NodeStatusInfoSlice) DownHosts() []string
DownHosts returns slice of address of nodes that are down.
func (NodeStatusInfoSlice) Hosts ¶
func (s NodeStatusInfoSlice) Hosts() []string
Hosts returns slice of address of all nodes.
func (NodeStatusInfoSlice) LiveHosts ¶
func (s NodeStatusInfoSlice) LiveHosts() []string
LiveHosts returns slice of address of nodes in UN state.
type ReplicationStrategy ¶
type ReplicationStrategy string
ReplicationStrategy specifies type of a keyspace replication strategy.
type Ring ¶
type Ring struct { Tokens []TokenRange HostDC map[string]string Replication ReplicationStrategy }
Ring describes token ring of a keyspace.
func (Ring) Datacenters ¶
Datacenters returs a list of datacenters the keyspace is replicated in.
type ScyllaFeatures ¶
type ScyllaFeatures struct {
RowLevelRepair bool
}
ScyllaFeatures specifies features supported by the Scylla version.
type TokenRange ¶
TokenRange describes replicas of a token (range).