Documentation ¶
Index ¶
- func NewComposite(scheds ...core.Schedule) core.Schedule
- func NewCompositeConf(conf CompositeConf) core.Schedule
- func NewConst(ops float64, duration time.Duration) core.Schedule
- func NewConstConf(conf ConstConfig) core.Schedule
- func NewDoAtSchedule(duration time.Duration, n int64, doAt DoAt) core.Schedule
- func NewInstanceStep(from, to int64, step int64, stepDuration time.Duration) core.Schedule
- func NewInstanceStepConf(conf InstanceStepConfig) core.Schedule
- func NewLine(from, to float64, duration time.Duration) core.Schedule
- func NewLineConf(conf LineConfig) core.Schedule
- func NewOnce(n int64) core.Schedule
- func NewOnceConf(conf OnceConfig) core.Schedule
- func NewStep(from, to float64, step int64, duration time.Duration) core.Schedule
- func NewStepConf(conf StepConfig) core.Schedule
- func NewUnlimited(duration time.Duration) core.Schedule
- func NewUnlimitedConf(conf UnlimitedConfig) core.Schedule
- type CompositeConf
- type ConstConfig
- type DoAt
- type InstanceStepConfig
- type LineConfig
- type OnceConfig
- type StartSync
- type StepConfig
- type UnlimitedConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCompositeConf ¶
func NewCompositeConf(conf CompositeConf) core.Schedule
func NewConstConf ¶
func NewConstConf(conf ConstConfig) core.Schedule
func NewDoAtSchedule ¶
func NewInstanceStep ¶ added in v0.4.0
func NewInstanceStepConf ¶ added in v0.4.0
func NewInstanceStepConf(conf InstanceStepConfig) core.Schedule
func NewLineConf ¶
func NewLineConf(conf LineConfig) core.Schedule
func NewOnce ¶
NewOnce returns schedule that emits all passed operation token at start time. That is, is schedule for zero duration, unlimited RPS, and n operations.
func NewOnceConf ¶
func NewOnceConf(conf OnceConfig) core.Schedule
func NewStepConf ¶ added in v0.3.3
func NewStepConf(conf StepConfig) core.Schedule
func NewUnlimited ¶
NewUnlimited returns schedule that generates unlimited ops for passed duration.
func NewUnlimitedConf ¶
func NewUnlimitedConf(conf UnlimitedConfig) core.Schedule
Types ¶
type CompositeConf ¶
type ConstConfig ¶
type DoAt ¶
DoAt returns when i'th operation should be performed, assuming that schedule started at 0.
type InstanceStepConfig ¶ added in v0.4.0
type LineConfig ¶
type OnceConfig ¶
type OnceConfig struct {
Times int64 `validate:"min=1"` // N is decoded like bool
}
type StartSync ¶ added in v0.3.0
type StartSync struct {
// contains filtered or unexported fields
}
StartSync is util to make schedule start goroutine safe. See doAtSchedule as example.
func (*StartSync) MarkStarted ¶ added in v0.3.0
func (s *StartSync) MarkStarted()
type StepConfig ¶ added in v0.3.3
type UnlimitedConfig ¶
Click to show internal directories.
Click to hide internal directories.