Documentation ¶
Index ¶
- Constants
- func B2Kib(numB uint32) uint32
- func Check(e error)
- func Hash(s string) uint64
- func Hex2Int(hexStr string) int64
- func Kib2Mib(numB uint32) uint32
- func MaxOf(vars ...int) int
- func Mib2Kib(numMb uint32) uint32
- func Mib2b(numMb uint32) uint32
- func MinOf(vars ...int) int
- func RandBool() bool
- func RandIntBetween(min, max int) int
- func SumNumberOfInvocations(withWarmup bool, totalDuration int, functions []*Function) int
- type DirigentMetadata
- type ExperimentPhase
- type Function
- type FunctionInvocationStats
- type FunctionMemoryStats
- type FunctionRuntimeStats
- type FunctionSpecification
- type IATMatrix
- type IatDistribution
- type Pair
- type PairList
- type ProbabilisticDuration
- type RuntimeAssertType
- type RuntimeSpecification
- type RuntimeSpecificationMatrix
- type TraceGranularity
Constants ¶
View Source
const ( FunctionNamePrefix = "trace-func" OneSecondInMicroseconds = 1_000_000.0 )
View Source
const ( // MinExecTimeMilli 1ms (min. billing unit of AWS) MinExecTimeMilli = 1 // MaxExecTimeMilli 60s (avg. p96 from Wild) MaxExecTimeMilli = 60e3 )
View Source
const ( // MaxMemQuotaMib Number taken from AWS Lambda settings // https://docs.aws.amazon.com/lambda/latest/dg/configuration-function-common.html#configuration-memory-console MaxMemQuotaMib = 10_240 MinMemQuotaMib = 1 // OvercommitmentRatio Machine overcommitment ratio to provide to CPU requests in YAML specification. // Value taken from the Firecracker NSDI'20 paper. OvercommitmentRatio = 10 )
View Source
const ( // RequestedVsIssuedWarnThreshold Print warning on stdout if the relative difference between requested // and issued number of invocations is higher than this threshold RequestedVsIssuedWarnThreshold = 0.1 // RequestedVsIssuedTerminateThreshold Terminate experiment if the relative difference between // requested and issued number of invocations is higher than this threshold RequestedVsIssuedTerminateThreshold = 0.2 // FailedWarnThreshold Print warning on stdout if the percentage of failed invocations (e.g., connection timeouts, // function timeouts) is greater than this threshold FailedWarnThreshold = 0.3 // FailedTerminateThreshold Terminate experiment if the percentage of failed invocations (e.g., connection timeouts, // function timeouts) is greater than this threshold FailedTerminateThreshold = 0.5 )
View Source
const ( AwsRegion = "us-east-1" AwsTraceFuncRepositoryName = "invitro_trace_function_aws" )
Variables ¶
This section is empty.
Functions ¶
func RandIntBetween ¶
Types ¶
type DirigentMetadata ¶
type DirigentMetadata struct { HashFunction string `csv:"HashFunction"` Image string `csv:"Image"` Port int `csv:"Port"` Protocol string `csv:"Protocol"` ScalingUpperBound int `csv:"ScalingUpperBound"` ScalingLowerBound int `csv:"ScalingLowerBound"` IterationMultiplier int `csv:"IterationMultiplier"` }
type ExperimentPhase ¶
type ExperimentPhase int
const ( WarmupPhase ExperimentPhase = 1 ExecutionPhase ExperimentPhase = 2 )
type Function ¶
type Function struct { Name string Endpoint string // From the static trace profiler InitialScale int // From the trace InvocationStats *FunctionInvocationStats RuntimeStats *FunctionRuntimeStats MemoryStats *FunctionMemoryStats DirigentMetadata *DirigentMetadata CPURequestsMilli int MemoryRequestsMiB int CPULimitsMilli int Specification *FunctionSpecification }
type FunctionInvocationStats ¶
type FunctionMemoryStats ¶
type FunctionMemoryStats struct { HashOwner string `csv:"HashOwner"` HashApp string `csv:"HashApp"` HashFunction string `csv:"HashFunction"` Count float64 `csv:"SampleCount"` Average float64 `csv:"AverageAllocatedMb"` Percentile1 float64 `csv:"AverageAllocatedMb_pct1"` Percentile5 float64 `csv:"AverageAllocatedMb_pct5"` Percentile25 float64 `csv:"AverageAllocatedMb_pct25"` Percentile50 float64 `csv:"AverageAllocatedMb_pct50"` Percentile75 float64 `csv:"AverageAllocatedMb_pct75"` Percentile95 float64 `csv:"AverageAllocatedMb_pct95"` Percentile99 float64 `csv:"AverageAllocatedMb_pct99"` Percentile100 float64 `csv:"AverageAllocatedMb_pct100"` }
type FunctionRuntimeStats ¶
type FunctionRuntimeStats struct { HashOwner string `csv:"HashOwner"` HashApp string `csv:"HashApp"` HashFunction string `csv:"HashFunction"` Average float64 `csv:"Average"` Count float64 `csv:"Count"` Minimum float64 `csv:"Minimum"` Maximum float64 `csv:"Maximum"` Percentile0 float64 `csv:"percentile_Average_0"` Percentile1 float64 `csv:"percentile_Average_1"` Percentile25 float64 `csv:"percentile_Average_25"` Percentile50 float64 `csv:"percentile_Average_50"` Percentile75 float64 `csv:"percentile_Average_75"` Percentile99 float64 `csv:"percentile_Average_99"` Percentile100 float64 `csv:"percentile_Average_100"` }
type FunctionSpecification ¶
type FunctionSpecification struct { IAT IATMatrix `json:"IAT"` RawDuration ProbabilisticDuration `json:"RawDuration"` RuntimeSpecification RuntimeSpecificationMatrix `json:"RuntimeSpecification"` }
type IatDistribution ¶
type IatDistribution int
const ( Exponential IatDistribution = iota Uniform Equidistant )
type ProbabilisticDuration ¶
type ProbabilisticDuration []float64
ProbabilisticDuration used for testing the exponential distribution
type RuntimeAssertType ¶
type RuntimeAssertType int
const ( RequestedVsIssued RuntimeAssertType = 0 IssuedVsFailed RuntimeAssertType = 1 )
type RuntimeSpecification ¶
type RuntimeSpecificationMatrix ¶
type RuntimeSpecificationMatrix [][]RuntimeSpecification
type TraceGranularity ¶
type TraceGranularity int
const ( MinuteGranularity TraceGranularity = iota SecondGranularity )
Click to show internal directories.
Click to hide internal directories.