schedulers

package
v3.0.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

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.

type BalanceType

type BalanceType int

BalanceType : the perspective of balance

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL