Documentation ¶
Index ¶
- type ClientLib
- type DynamicClientLib
- func (lib *DynamicClientLib) Close()
- func (lib *DynamicClientLib) FpPropose(cmd *dynamic.Command) (bool, bool, string)
- func (lib *DynamicClientLib) IsPaxosLeaderColocated() (bool, string)
- func (lib *DynamicClientLib) PaxosPropose(cmd *dynamic.Command) (bool, string)
- func (lib *DynamicClientLib) Propose(cmd *dynamic.Command) (bool, bool, bool, string)
- func (lib *DynamicClientLib) Test()
- type LatInfo
- type LatTimeInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientLib ¶
type ClientLib interface { /* Chooses a Paxos or Fast Paxos instance to propose the command * Returns (isFastUsed, isCommitted, isFast, execution result) */ Propose(cmd *dynamic.Command) (bool, bool, bool, string) /* Uses an Fast Paxos instance to propose the command * Returns (isCommitted, isFast, execution result) */ FpPropose(cmd *dynamic.Command) (bool, bool, string) /* Uses a Paxos instance to propose the command * Returns (isCommitted, execution result) */ PaxosPropose(cmd *dynamic.Command) (bool, string) // Shuts down the client lib Close() // Static network configuration Test() }
func NewClientLib ¶
type DynamicClientLib ¶
type DynamicClientLib struct { Id string // client id IsReplicaColocated bool // true if colocated with a replica in the same datacenter ColocatedReplicaAddr string // the net addr of the colocated replica // contains filtered or unexported fields }
func (*DynamicClientLib) Close ¶
func (lib *DynamicClientLib) Close()
func (*DynamicClientLib) IsPaxosLeaderColocated ¶
func (lib *DynamicClientLib) IsPaxosLeaderColocated() (bool, string)
Returns true and colocated paxos leasder's net addr TODO: The colocated replica may not be a Paxos leader
func (*DynamicClientLib) PaxosPropose ¶
func (lib *DynamicClientLib) PaxosPropose(cmd *dynamic.Command) (bool, string)
func (*DynamicClientLib) Test ¶
func (lib *DynamicClientLib) Test()
type LatTimeInfo ¶
type LatTimeInfo struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.