Documentation ¶
Index ¶
- Constants
- type Checker
- type InCommandQueue
- type NodeCaller
- func (nc *NodeCaller) ExecuteOperation(obj *storage.MetaDataUpdObj, destination *cluster.OvoNode, operation string) error
- func (nc *NodeCaller) GetTopology(currentNode string, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) Ping(currentNode string, destination *cluster.OvoNode) error
- func (nc *NodeCaller) RegisterNode(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) RegisterStepbrother(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) RegisterTwin(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) RegisterTwinAndStepbrother(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) RemoveClient(name string)
- func (nc *NodeCaller) UpdateNode(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- func (nc *NodeCaller) UpdateTopology(topology *cluster.ClusterTopology, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
- type OutCommandQueue
- type Partitioner
Constants ¶
View Source
const ( CheckerPeriod = 5 // 5 secs ErrorThreshold = 3 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Checker ¶
type Checker struct {
// contains filtered or unexported fields
}
func NewChecker ¶
func NewChecker(topology *cluster.ClusterTopology, outcomingQueue *OutCommandQueue, partitioner *Partitioner) *Checker
type InCommandQueue ¶
type InCommandQueue struct {
// contains filtered or unexported fields
}
func NewCommandQueue ¶
func NewCommandQueue(ks storage.OvoStorage) *InCommandQueue
func (*InCommandQueue) Enqueu ¶
func (cq *InCommandQueue) Enqueu(cmd *command.Command)
func (*InCommandQueue) KeyStore ¶
func (cq *InCommandQueue) KeyStore() storage.OvoStorage
type NodeCaller ¶
func (*NodeCaller) ExecuteOperation ¶
func (nc *NodeCaller) ExecuteOperation(obj *storage.MetaDataUpdObj, destination *cluster.OvoNode, operation string) error
Execute remote operation on destination server
func (*NodeCaller) GetTopology ¶
func (nc *NodeCaller) GetTopology(currentNode string, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to give the topology
func (*NodeCaller) Ping ¶
func (nc *NodeCaller) Ping(currentNode string, destination *cluster.OvoNode) error
Ask the destination to give the topology
func (*NodeCaller) RegisterNode ¶
func (nc *NodeCaller) RegisterNode(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to register the node
func (*NodeCaller) RegisterStepbrother ¶
func (nc *NodeCaller) RegisterStepbrother(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to register the node as a stepbrother
func (*NodeCaller) RegisterTwin ¶
func (nc *NodeCaller) RegisterTwin(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to register the node as a twin
func (*NodeCaller) RegisterTwinAndStepbrother ¶
func (nc *NodeCaller) RegisterTwinAndStepbrother(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to register the node as a twin and a stepbrother
func (*NodeCaller) RemoveClient ¶
func (nc *NodeCaller) RemoveClient(name string)
Remove a client by name
func (*NodeCaller) UpdateNode ¶
func (nc *NodeCaller) UpdateNode(node *cluster.ClusterTopologyNode, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to update the node
func (*NodeCaller) UpdateTopology ¶
func (nc *NodeCaller) UpdateTopology(topology *cluster.ClusterTopology, destination *cluster.OvoNode) (*cluster.ClusterTopology, error)
Ask the destination to update the topology
type OutCommandQueue ¶
type OutCommandQueue struct { Caller *NodeCaller // contains filtered or unexported fields }
func NewOutCommandQueue ¶
func NewOutCommandQueue(serverNode *cluster.ClusterTopologyNode, topology *cluster.ClusterTopology, incomingQueue *InCommandQueue) *OutCommandQueue
Create the outcoming command processor queue
func (*OutCommandQueue) Enqueu ¶
func (cq *OutCommandQueue) Enqueu(cmd *command.Command)
type Partitioner ¶
type Partitioner struct {
// contains filtered or unexported fields
}
func NewPartitioner ¶
func NewPartitioner(storage storage.OvoStorage, serverNode *cluster.ClusterTopologyNode, outcomingQueue *OutCommandQueue) *Partitioner
func (*Partitioner) MoveData ¶
func (p *Partitioner) MoveData()
func (*Partitioner) MoveObject ¶
func (p *Partitioner) MoveObject(obj *storage.MetaDataObj)
Click to show internal directories.
Click to hide internal directories.