Documentation ¶
Index ¶
Constants ¶
View Source
const ( HashCacheExpiration = 60 * time.Second HashCacheCleanupInterval = 1 * time.Second )
View Source
const ( MaxBufLen = 1024 * 16 // maximum buffer to receive message DialTimeout = 3 * time.Second // timeout for dialing )
View Source
const ( MaxSyncHeaderReq = 2 // max concurrent sync header request count MaxMsgChanNum = 2048 // max goroutine num for message handler ConnectionMaxBackoff = 4000 // back off for retry MaxRetryCount = 3 // max retry count KeepAliveTicker = 3 * time.Second // ticker for ping/pong and keepalive message KeepaliveTimeout = 9 * time.Second // timeout for keeping alive BlockSyncingTicker = 3 * time.Second // ticker for syncing block ProtocolVersion = 0 // protocol version ConnectionTicker = 10 * time.Second // ticker for connection MaxReqBlkOnce = 16 // max block count requested ConnectingTimeout = 10 * time.Second // timeout for waiting for connection )
Variables ¶
This section is empty.
Functions ¶
func NewHashCache ¶
func NewHashCache() *hashCache
Types ¶
type ConnectingNodes ¶
Click to show internal directories.
Click to hide internal directories.