config

package
v0.0.0-...-b1f166a Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Concurrency = struct {
	Value int
	Mutex *sync.Mutex
}{
	Value: -1,
	Mutex: &sync.Mutex{},
}

Concurrency is the max number of concurrent requests and a mutex. Ignored if value < 0

View Source
var IgnoredHeaders []string

IgnoredHeaders are the headers we ignore diffs on

View Source
var KV = logger.New("http-science")

KV is this worker's Kayvee logger

View Source
var WeakCompare = false

WeakCompare if set to true by the payload allows arrays to be out of order in the json comparison

Functions

func LogAndExitIfErr

func LogAndExitIfErr(err error, title string, extra interface{})

LogAndExitIfErr KV logs and exits with code 1 if there is an error

Types

type Payload

type Payload struct {
	// Required
	JobType     string `json:"job_type"`
	ServiceName string `json:"service_name"`
	// Only Correctness
	ExperimentEnv  string   `json:"experiment_env"`
	ControlEnv     string   `json:"control_env"`
	ExperimentURL  string   // initialized in validate.go
	ControlURL     string   // initialized in validate.go
	DiffLoc        string   `json:"diff_loc"`
	WeakCompare    bool     `json:"weak_equal"`
	IgnoredHeaders []string `json:"ignored_headers"`
	// Only Load
	LoadEnv string `json:"load_env"`
	LoadURL string // initialized in validate.go
	Speed   int    `json:"speed"`
	// Optional
	Concurrency      int    `json:"concurrency"`
	Reqs             int    `json:"reqs"`
	JobNumber        int    `json:"job_number"`
	TotalJobs        int    `json:"total_jobs"`
	StartBefore      string `json:"start_before"`
	Methods          string `json:"methods"`
	Email            string `json:"email"`
	DisallowURLRegex string `json:"disallow_url_regex"`
	AllowURLRegex    string `json:"allow_url_regex"`
	Port             string `json:"port"`
	PodID            string `json:"pod_id"`
}

Payload is the payload specifiying info for a load test

Jump to

Keyboard shortcuts

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