Versions in this module Expand all Collapse all v0 v0.7.0 Dec 22, 2014 Changes in this version + func IsNetworkError(attempt request.Attempt) bool + func SplitFloat64(threshold, sentinel float64, values []float64) (good map[float64]bool, bad map[float64]bool) + func SplitLatencies(values []time.Duration, precision time.Duration) (good map[time.Duration]bool, bad map[time.Duration]bool) + func SplitRatios(values []float64) (good map[float64]bool, bad map[float64]bool) + type FailPredicate func(request.Attempt) bool + type FailRateMeter interface + GetRate func() float64 + GetWindowSize func() time.Duration + IsReady func() bool + type HDRHistogram struct + func NewHDRHistogram(low, high int64, sigfigs int) (h *HDRHistogram, err error) + func (h *HDRHistogram) LatencyAtQuantile(q float64) time.Duration + func (h *HDRHistogram) Merge(o Histogram) error + func (h *HDRHistogram) RecordLatencies(d time.Duration, n int64) error + func (h *HDRHistogram) RecordValues(v, n int64) error + func (h *HDRHistogram) Reset() + func (h *HDRHistogram) ValueAtQuantile(q float64) int64 + type Histogram interface + LatencyAtQuantile func(float64) time.Duration + Merge func(Histogram) error + RecordLatencies func(d time.Duration, n int64) error + RecordValues func(v, n int64) error + Reset func() + ValueAtQuantile func(q float64) int64 + type NewHistogramFn func() (Histogram, error) + func NewHDRHistogramFn(low, high int64, sigfigs int) NewHistogramFn + type NewRollingCounterFn func() (*RollingCounter, error) + type RollingCounter struct + func NewRollingCounter(buckets int, resolution time.Duration, timeProvider timetools.TimeProvider) (*RollingCounter, error) + func (c *RollingCounter) Buckets() int + func (c *RollingCounter) Count() int64 + func (c *RollingCounter) CountedBuckets() int + func (c *RollingCounter) GetWindowSize() time.Duration + func (c *RollingCounter) Inc() + func (c *RollingCounter) Reset() + func (c *RollingCounter) Resolution() time.Duration + type RollingHistogram interface + Merged func() (Histogram, error) + RecordLatencies func(d time.Duration, n int64) error + RecordValues func(v, n int64) error + Reset func() + func NewRollingHistogram(maker NewHistogramFn, bucketCount int, period time.Duration, ...) (RollingHistogram, error) + type RollingMeter struct + func NewRollingMeter(endpoint endpoint.Endpoint, buckets int, resolution time.Duration, ...) (*RollingMeter, error) + func (r *RollingMeter) Buckets() int + func (r *RollingMeter) FailureCount() int64 + func (r *RollingMeter) GetRate() float64 + func (r *RollingMeter) GetWindowSize() time.Duration + func (r *RollingMeter) IsReady() bool + func (r *RollingMeter) ObserveRequest(request.Request) + func (r *RollingMeter) ObserveResponse(req request.Request, lastAttempt request.Attempt) + func (r *RollingMeter) ProcessedCount() int64 + func (r *RollingMeter) Reset() + func (r *RollingMeter) Resolution() time.Duration + func (r *RollingMeter) SuccessCount() int64 + type RoundTripMetrics struct + func NewRoundTripMetrics(o RoundTripOptions) (*RoundTripMetrics, error) + func (m *RoundTripMetrics) GetLatencyHistogram() (Histogram, error) + func (m *RoundTripMetrics) GetNetworkErrorCount() int64 + func (m *RoundTripMetrics) GetNetworkErrorRatio() float64 + func (m *RoundTripMetrics) GetOptions() *RoundTripOptions + func (m *RoundTripMetrics) GetResponseCodeRatio(startA, endA, startB, endB int) float64 + func (m *RoundTripMetrics) GetStatusCodesCounts() map[int]int64 + func (m *RoundTripMetrics) GetTotalCount() int64 + func (m *RoundTripMetrics) RecordMetrics(a request.Attempt) + func (m *RoundTripMetrics) Reset() + type RoundTripOptions struct + CounterBuckets int + CounterResolution time.Duration + HistBuckets int + HistMax int64 + HistMin int64 + HistPeriod time.Duration + HistSignificantFigures int + TimeProvider timetools.TimeProvider + type TestMeter struct + NotReady bool + Rate float64 + WindowSize time.Duration + func (em *TestMeter) ObserveRequest(r request.Request) + func (em *TestMeter) ObserveResponse(r request.Request, lastAttempt request.Attempt) + func (tm *TestMeter) GetRate() float64 + func (tm *TestMeter) GetWindowSize() time.Duration + func (tm *TestMeter) IsReady() bool