messages

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const KindServerInfo = "ServerInfo"
View Source
const KindStartLoadTestRequest = "StartLoadTestRequest"
View Source
const KindStopLoadTestRequest = "StopLoadTestRequest"
View Source
const KindWorkerInfo = "WorkerInfo"
View Source
const KindWorkerLoadTestMetrics = "WorkerLoadTestMetrics"
View Source
const KindWorkersInfo = "WorkersInfo"
View Source
const ServerStateDone = 2
View Source
const ServerStateNotStarted = 0
View Source
const ServerStateRunning = 1
View Source
const ServerStateStopped = 3
View Source
const WorkerStateDone = WorkerState(2)
View Source
const WorkerStateNotStarted = WorkerState(0)
View Source
const WorkerStateRunning = WorkerState(1)
View Source
const WorkerStateStopped = WorkerState(3)

Variables

This section is empty.

Functions

This section is empty.

Types

type Envelope

type Envelope struct {
	Kind string `json:"kind"`
	Data string `json:"data"`
}

type ServerInfo

type ServerInfo struct {
	NumOfWorkers int    `json:"num_of_workers"`
	State        string `json:"state"`
}

type StartLoadTestRequest

type StartLoadTestRequest struct {
	Method   string `json:"method"`
	URL      string `json:"url"`
	Duration uint64 `json:"duration,string"`
	// Rate per worker
	Rate   uint64 `json:"rate,string"`
	Header string `json:"header"`
	Body   string `json:"body"`
}

type WorkerInfo

type WorkerInfo struct {
	State WorkerState `json:"state"`
}

type WorkerLoadTestMetrics

type WorkerLoadTestMetrics struct {
	// Duration is the duration of the attack.
	Duration time.Duration `json:"duration"`
	// Wait is the extra time waiting for responses from targets.
	Wait time.Duration `json:"wait"`
	// Requests is the total number of requests executed.
	Requests uint64 `json:"requests"`
	// Rate is the rate of sent requests per second.
	Rate float64 `json:"rate"`
	// Throughput is the rate of successful requests per second.
	Throughput float64 `json:"throughput"`
	// Success is the percentage of non-error responses.
	Success float64 `json:"success"`
	// Latencies holds computed request latency metrics.
	Latencies vegeta.LatencyMetrics `json:"latencies"`
	// BytesIn holds computed incoming byte metrics.
	BytesIn vegeta.ByteMetrics `json:"bytes_in"`
	// BytesOut holds computed outgoing byte metrics.
	BytesOut vegeta.ByteMetrics `json:"bytes_out"`
	// StatusCodes is a histogram of the responses' status codes.
	StatusCodes map[string]int `json:"status_codes"`
	// Errors is a set of unique errors returned by the targets during the attack.
	Errors []string `json:"errors"`
}

type WorkerState

type WorkerState int

Jump to

Keyboard shortcuts

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