sampler

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DurationSampler

type DurationSampler struct {
	// contains filtered or unexported fields
}

DurationSampler is the sampler for sampling duration.

func NewDurationSampler

func NewDurationSampler() *DurationSampler

NewDurationSampler creates a DurationSampler.

func (*DurationSampler) Count

func (ds *DurationSampler) Count() float64

Count return total count of DurationSampler.

func (*DurationSampler) P25

func (ds *DurationSampler) P25() float64

P25 returns the duration in millisecond greater than 25%.

func (*DurationSampler) P50

func (ds *DurationSampler) P50() float64

P50 returns the duration in millisecond greater than 50%.

func (*DurationSampler) P75

func (ds *DurationSampler) P75() float64

P75 returns the duration in millisecond greater than 75%.

func (*DurationSampler) P95

func (ds *DurationSampler) P95() float64

P95 returns the duration in millisecond greater than 95%.

func (*DurationSampler) P98

func (ds *DurationSampler) P98() float64

P98 returns the duration in millisecond greater than 98%.

func (*DurationSampler) P99

func (ds *DurationSampler) P99() float64

P99 returns the duration in millisecond greater than 99%.

func (*DurationSampler) P999

func (ds *DurationSampler) P999() float64

P999 returns the duration in millisecond greater than 99.9%.

func (*DurationSampler) Percentiles

func (ds *DurationSampler) Percentiles() []float64

Percentiles returns 7 metrics by order: P25, P50, P75, P95, P98, P99, P999

func (*DurationSampler) Update

func (ds *DurationSampler) Update(d time.Duration)

Update updates the sample.

Jump to

Keyboard shortcuts

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