timeout.go 355 B

1234567891011121314151617
  1. package server
  2. // import (
  3. // "time"
  4. // )
  5. const (
  6. // The amount of time to elapse without a heartbeat before becoming a candidate.
  7. // ElectionTimeout = 200 * time.Millisecond
  8. ElectionTimeout = 200
  9. // The frequency by which heartbeats are sent to followers.
  10. //HeartbeatTimeout = 50 * time.Millisecond
  11. HeartbeatTimeout = 50
  12. RetryInterval = 10
  13. )