src

package
v0.0.0-...-8079955 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2016 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// LogsGenerationVarianceAllowedPercent specifies how much variance we allow between results.
	// Precise semantics is that we say that difference is too big if greater value is more than
	// LogsGenerationVarianceAllowedPercent bigger than the smaller one. I.e. if X < Y, then Y is too
	// big if Y > X + X*(LogsGenerationVarianceAllowedPercent/100).
	LogsGenerationVarianceAllowedPercent = 50
)
View Source
const (
	// MetricsVarianceAllowedPercent specifies how much variance we allow between results.
	// Precise semantics is that we say that difference is too big if greater value is more than
	// MetricsVarianceAllowedPercent bigger than the smaller one. I.e. if X < Y, then Y is too
	// big if Y > X + X*(MetricsVarianceAllowedPercent/100).
	MetricsVarianceAllowedPercent = 50
)
View Source
const (
	// ResourceUsageVarianceAllowedPercent specifies how much variance we allow between results.
	// Precise semantics is that we say that difference is too big if greater value is more than
	// ResourceUsageVarianceAllowedPercent bigger than the smaller one. I.e. if X < Y, then Y is too
	// big if Y > X + X*(ResourceUsageVarianceAllowedPercent/100).
	ResourceUsageVarianceAllowedPercent = 50
)

Variables

This section is empty.

Functions

func ChangeColor

func ChangeColor(color ct.Color, writer io.Writer)

ChangeColor is a slightly modified version of daviddengcn/go-colortext, so it'll work well with io.Writer

func ProcessSingleTest

func ProcessSingleTest(scanner *bufio.Scanner, buildNumber int) (map[string]*e2e.LogsSizeDataSummary, map[string]*e2e.ResourceUsageSummary, map[string]*e2e.MetricsForE2E)

ProcessSingleTest processes single Jenkins output file, reading and parsing JSON summaries embedded in it.

func ResetColor

func ResetColor(writer io.Writer)

ResetColor is a slightly modified version of daviddengcn/go-colortext, so it'll work well with io.Writer

Types

type ViolatingLogGenerationData

type ViolatingLogGenerationData map[string]ViolatingLogGenerationPair

ViolatingLogGenerationData stores offending pairs keyed by the log file identified by the path.

func CompareLogGenerationSpeed

func CompareLogGenerationSpeed(left *e2e.LogsSizeDataSummary, right *e2e.LogsSizeDataSummary) ViolatingLogGenerationData

CompareLogGenerationSpeed given two summaries compares the data in them and returns set of offending values. Precise semantics is that for each file (e.g. /var/log/kubelet.log) we check if minimal and maximal values are roughly the same.

func (*ViolatingLogGenerationData) PrintToStdout

func (d *ViolatingLogGenerationData) PrintToStdout(leftBuild, rightBuild int, enableOutputColoring bool)

PrintToStdout prints offending data to the Stdout in a human readable format.

type ViolatingLogGenerationPair

type ViolatingLogGenerationPair struct {
	// contains filtered or unexported fields
}

ViolatingLogGenerationPair stores a pair of results which proves that the difference is too big

type ViolatingMetric

type ViolatingMetric struct {
	// contains filtered or unexported fields
}

ViolatingMetric stores a pair of metrics which proves that the difference between them is too big Contains an info about the source component for those metrics, and all their labels.

type ViolatingMetricsArr

type ViolatingMetricsArr map[string][]ViolatingMetric

ViolatingMetricsArr stores offending metrics keyed by the metric name.

func CompareMetrics

func CompareMetrics(left *e2e.MetricsForE2E, right *e2e.MetricsForE2E) ViolatingMetricsArr

CompareMetrics given two summaries compares the data in them and returns set of offending values. Precise semantics is that for each metric (identified as a name and set of labels) we check if values are roughly the same. For kubelet metrics we check minimal and maximal values over all Kubelets.

func (*ViolatingMetricsArr) PrintToStdout

func (d *ViolatingMetricsArr) PrintToStdout(leftBuild, rightBuild int, enableOutputColoring bool)

PrintToStdout prints offending data to the Stdout in a human readable format.

type ViolatingResourceUsageData

type ViolatingResourceUsageData map[string]ViolatingResourceUsageDataPair

ViolatingResourceUsageData stores offending pairs keyed by the log file identified by the container name.

func CompareResourceUsages

func CompareResourceUsages(left *e2e.ResourceUsageSummary, right *e2e.ResourceUsageSummary) ViolatingResourceUsageData

CompareResourceUsages given two summaries compares the data in them and returns set of offending values. Precise semantics is that for each container type, identified by the container name we check if minimal and maximal values for both CPU and memory usage are roughly the same.

func (*ViolatingResourceUsageData) PrintToStdout

func (d *ViolatingResourceUsageData) PrintToStdout(leftBuild, rightBuild int, enableOutputColoring bool)

PrintToStdout prints result to Stdout assuming that the comparison logic is a standard one (comparing minimums and maximums) If comparison logic is changed this function should be updated as well.

type ViolatingResourceUsageDataPair

type ViolatingResourceUsageDataPair struct {
	// contains filtered or unexported fields
}

ViolatingResourceUsageDataPair stores a pair of results which proves that the difference is too big

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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