Documentation
¶
Overview ¶
Package gofast is a go module that accesses www.fast.com in order to derive upload/download speeds
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Measurer ¶
Measurer is an interface used to measure values. The returned channel will be written to exactly once
type Results ¶
type Results struct { Bytes []int `json:"bytes,omitempty"` //A slice of the total bytes read by each worker Duration []time.Duration `json:"duration,omitempty"` // slice of total duration the operation took BitsPerSec []float64 `json:"bitspersec,omitempty"` //sice of calculated bits/sec from each worker Samples []nStats `json:"samples,omitempty"` //Slice of all the samples each worker measured. Workers int `json:"workers"` //number of workers used Bps float64 `json:"bps"` //bits per second Kbps float64 `json:"kbps"` //kbits per second Mbps float64 `json:"mbps"` //MBits per second }
Results is the final results of the test complete with raw data measured form each worker
type Settings ¶
type Settings struct { Workers int //number of workers to use MaxBytes int64 //maximum number of bytes to ingest Network time.Duration //maximal time to allow network operations to run for Timeout time.Duration //maximal time to run for EmitJSON bool //emit JSON output }
Settings is the configurable settings to pass to a Measurer
type Stats ¶
type Stats struct { Error error `json:"error,omitempty"` //Error, if any, that occurred while reading in a sample set Duration time.Duration `json:"duration"` //how long the operation took to read in Bytes Bytes int `json:"bytes"` //the number of bytes read in Bps float64 `json:"bps"` //bits per second over the immediate sample period Samples []Stats `json:"samples,omitempty"` //Workers should populate this with all their stats }
Stats is a simple store of statistic data
Click to show internal directories.
Click to hide internal directories.