Documentation
¶
Index ¶
Constants ¶
View Source
const ( PORT = 1735 HTTP_PORT = 8080 BUFFER_SIZE = 1024 * 1 // TODO merge below two value with with config CHAN_BUFFER_SIZE = 1024 * 1 )
default values
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Addrs map[ids.ID]string `json:"address"` // address for node communication
HTTPAddrs map[ids.ID]string `json:"http_address"` // address for bench server communication
Quorum string `json:"quorum"` // type of the quorums
F int `json:"f"` // number of failure zones in general grid quorums
RS int `json:"rs"` // number of failure zones in a replication region
LevelDBDir []string `json:"leveldb"` // directory for LevelDB instances
Transport string `json:"transport"` // not used
Codec string `json:"codec"`
ReplyWhenCommit bool `json:"reply_when_commit"` // reply to bench when request is committed, instead of executed
Adaptive bool `json:"adaptive"` // adaptive leader change, if true paxos forward request to current leader
Interval int `json:"interval"` // interval for leader change, 0 means immediate
BackOff int `json:"backoff"` // random backoff interval
Thrifty bool `json:"thrifty"` // only send messages to a quorum
ChanBufferSize int `json:"chan_buffer_size"`
BufferSize int `json:"buffer_size"`
BalGossipInt int64 `json:"balance_gossip_interval"` //Interval between balance data gossip messages in ms
OverldThrshld float64 `json:"overload_threshold"` //how many percent over even distribution is considered to be overlaod
TX_lease int `json:"tx_lease_duration"` //how long is tx lease (in ms) preventing other nodes from stealing
HandoverN int `json:"handoverN"` //how many request we need before making polite handover decision
Migration_maj float64 `json:"migration_majority"` //http max idle connection per host
MaxIdleCnx int `json:"max_idle_connections"` //http max idle connection per host
CoGAlpha float32 `json:"cog_alpha"`
CoGMinNumHits int `json:"cog_min_number_hits"`
}
var Instance *Config
func MakeDefaultConfig ¶
func MakeDefaultConfig() Config
func (*Config) GetZoneIds ¶
Click to show internal directories.
Click to hide internal directories.