Documentation ¶
Index ¶
Constants ¶
View Source
const ( MaxScheduleInterval = time.Second * 5 MinScheduleInterval = time.Millisecond * 10 MinSlowScheduleInterval = time.Second * 3 ScheduleIntervalFactor = 1.3 )
options for interval of schedulers
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BalanceLeaderCreateOption ¶
type BalanceLeaderCreateOption func(s *balanceLeaderScheduler)
BalanceLeaderCreateOption is used to create a scheduler with an option.
func WithBalanceLeaderCounter ¶
func WithBalanceLeaderCounter(counter *prometheus.CounterVec) BalanceLeaderCreateOption
WithBalanceLeaderCounter sets the counter for the scheduler.
func WithBalanceLeaderName ¶
func WithBalanceLeaderName(name string) BalanceLeaderCreateOption
WithBalanceLeaderName sets the name for the scheduler.
type BalanceRegionCreateOption ¶
type BalanceRegionCreateOption func(s *balanceRegionScheduler)
BalanceRegionCreateOption is used to create a scheduler with an option.
func WithBalanceRegionCounter ¶
func WithBalanceRegionCounter(counter *prometheus.CounterVec) BalanceRegionCreateOption
WithBalanceRegionCounter sets the counter for the scheduler.
func WithBalanceRegionName ¶
func WithBalanceRegionName(name string) BalanceRegionCreateOption
WithBalanceRegionName sets the name for the scheduler.
Click to show internal directories.
Click to hide internal directories.