definition

package
v0.0.0-...-f45f4dd Latest Latest
Warning

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

Go to latest
Published: May 12, 2016 License: Apache-2.0 Imports: 7 Imported by: 4

Documentation

Overview

This definition package implements the transformation of a YAML definition to a nomi benchmark

Index

Constants

View Source
const (
	StopAll StopCommand = "stop-all"

	Lower   ExpectRunningSymbol = "<"
	Greater ExpectRunningSymbol = ">"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

type Application struct {
	Name         string
	Image        string
	Type         string
	Network      string
	Volumes      Volumes
	Ports        []int
	Args         []string
	Envs         map[string]string
	UnitFilePath string `yaml:"unitfile-path"`
}

type BenchmarkDef

type BenchmarkDef struct {
	Application       Application
	Instructions      Instructions
	InstanceGroupSize int `yaml:"instancegroup-size"`
}

func BenchmarkDefByFile

func BenchmarkDefByFile(filePath string) (BenchmarkDef, error)

BenchmarkDefByFile procudes a benchmark definition out of a YAML file Return a benchmark definition object and error

func BenchmarkDefByRawInstructions

func BenchmarkDefByRawInstructions(instructions string, igSize int) (BenchmarkDef, error)

BenchmarkDefByRawInstructions creates a benchmark definition using raw instructions and instance group size Return a benchmark definition and error

type ExpectRunning

type ExpectRunning struct {
	Symbol ExpectRunningSymbol `yaml:"symbol"`
	Amount int                 `yaml:"amount"`
}

type ExpectRunningSymbol

type ExpectRunningSymbol string

type Float

type Float struct {
	Rate     float64 `yaml:"rate"`
	Duration int     `yaml:"duration"`
}

type Instruction

type Instruction struct {
	Start         Start
	Float         Float
	ExpectRunning ExpectRunning
	Sleep         int         `yaml:"sleep"`
	Stop          StopCommand `yaml:"stop"`
}

type Instructions

type Instructions []Instruction

type Start

type Start struct {
	Max      int `yaml:"max"`
	Interval int `yaml:"interval"`
}

type StopCommand

type StopCommand string

type Volume

type Volume struct {
	Source string
	Target string
}

type Volumes

type Volumes []Volume

Jump to

Keyboard shortcuts

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