Documentation ¶
Index ¶
- type CertificateFileError
- type CertificateFileFormatError
- type Duration
- type Durations
- type HttpCodeError
- type HttpEngine
- type MeasurementResult
- type Parameters
- type PostDataFileError
- type RequestResult
- type RequestsProgress
- type Resource
- type ResourceFeeder
- type ResponseError
- type ResponseHeaders
- type TLS
- type TestEngine
- type Timing
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CertificateFileError ¶
func (*CertificateFileError) Error ¶
func (r *CertificateFileError) Error() string
type CertificateFileFormatError ¶
func (*CertificateFileFormatError) Error ¶
func (r *CertificateFileFormatError) Error() string
type Durations ¶
type Durations struct { DNSLookup, TCPConnection, TLSHandshake, ConnectionEstablishment, TTFB, Total Duration }
type HttpCodeError ¶ added in v0.0.9
type HttpCodeError struct {
Err error
}
func (*HttpCodeError) Error ¶ added in v0.0.9
func (r *HttpCodeError) Error() string
type HttpEngine ¶
type HttpEngine struct { Progress RequestsProgress // contains filtered or unexported fields }
func (*HttpEngine) GetProgress ¶
func (engine *HttpEngine) GetProgress() RequestsProgress
func (*HttpEngine) Measure ¶
func (engine *HttpEngine) Measure( parameters Parameters, resourceFeeder *ResourceFeeder, onProgress func(progress RequestsProgress), ) ([]MeasurementResult, time.Duration)
type MeasurementResult ¶
type MeasurementResult struct { RequestResult RequestResult Error error }
func Test ¶
func Test(parameters Parameters, onProgress func(progress RequestsProgress)) ( []MeasurementResult, time.Duration, error, )
type Parameters ¶
type Parameters struct { Resources []Resource Requests int Concurrency int Timeout time.Duration Method string UserAgent string UserAgentTemplate string KeepAlive bool Proxy string MaxIdleConnections int IdleConnTimeout time.Duration TLSHandshakeTimeout time.Duration IPv4Only bool IPv6Only bool AllowInsecureSSL bool ClientCertificateFile string PostDataFile string PostData string ContentType string FormData string OutputFormat string CustomHeaders []string TimeLimit time.Duration URLListFile string ExitWithErrorOnCode []string }
type PostDataFileError ¶
func (*PostDataFileError) Error ¶
func (r *PostDataFileError) Error() string
type RequestResult ¶
type RequestResult struct { Resource Resource Status string // e.g. "200 OK" StatusCode int // e.g. 200 ContentLength int64 Timing Timing Durations Durations TLS TLS Headers ResponseHeaders Error error }
func (RequestResult) ToJson ¶
func (result RequestResult) ToJson() ([]byte, error)
type RequestsProgress ¶
type RequestsProgress struct { TotalRequests, CompletedRequests, FailedRequests int }
type ResourceFeeder ¶ added in v0.0.9
type ResourceFeeder struct { Resources []Resource // contains filtered or unexported fields }
func (*ResourceFeeder) GetNextValue ¶ added in v0.0.9
func (s *ResourceFeeder) GetNextValue() (Resource, error)
type ResponseError ¶
func (*ResponseError) Error ¶
func (r *ResponseError) Error() string
type ResponseHeaders ¶
type ResponseHeaders struct { Server, PoweredBy string }
type TestEngine ¶
type TestEngine interface { Measure( parameters Parameters, resourceFeeder *ResourceFeeder, onProgress func(progress RequestsProgress), ) ([]MeasurementResult, time.Duration) GetProgress() RequestsProgress }
Click to show internal directories.
Click to hide internal directories.