internal

package
v0.0.0-...-3dea9e2 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const APP_NAME = "STRESS_GO"

Variables

This section is empty.

Functions

func GetLoadRacer

func GetLoadRacer(requests int64, racer int64) (*[]int64, error)

func MessageLog

func MessageLog(format string, a ...any) (n int, err error)

func MessageWithPrefixLog

func MessageWithPrefixLog(prefix string, format string, a ...any) (n int, err error)

func NewRacer

func NewRacer(name string, url string, requests int64, relatorio *Relatorio) *stressTestRacer

func RunStressTester

func RunStressTester(url string, requests int64, concurrency int64)

Types

type Relatorio

type Relatorio struct {
	URL             string
	Racer           int64
	Duration        *time.Duration
	RequestCount    int64
	StatusCodeCount map[int]int64
	ErrorCount      int64
	// contains filtered or unexported fields
}

func NewRelatorio

func NewRelatorio(url string, racer int64) *Relatorio

func (*Relatorio) AddError

func (r *Relatorio) AddError()

func (*Relatorio) AddRequest

func (r *Relatorio) AddRequest(statusCode int)

func (*Relatorio) PrintRelatorio

func (r *Relatorio) PrintRelatorio(finished bool)

Jump to

Keyboard shortcuts

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