Documentation
¶
Index ¶
- Constants
- Variables
- func ActivateWindowsServiceHandler(stopHandler func()) (isService bool)
- func BytesToMegabytes(bytes uint64) uint64
- func CheckTargetHostname(attributes map[string][]string) (*string, error)
- func LogTestSigningStatus()
- func NewFillDiskAction() action_kit_sdk.Action[FillDiskActionState]
- func NewFillMemAction() action_kit_sdk.Action[FillMemActionState]
- func NewHostDiscovery() discovery_kit_sdk.TargetDiscovery
- func NewNetworkBlackholeContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewNetworkBlockDnsContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewNetworkCorruptPackagesContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewNetworkDelayContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewNetworkLimitBandwidthContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewNetworkPackageLossContainerAction() action_kit_sdk.Action[NetworkActionState]
- func NewShutdownAction() action_kit_sdk.Action[ActionState]
- func NewStopProcessAction() action_kit_sdk.Action[StopProcessActionState]
- func NewStressCpuAction() action_kit_sdk.Action[CPUStressActionState]
- func NewStressIoAction() action_kit_sdk.Action[IoStressActionState]
- func NewTimetravelAction() action_kit_sdk.Action[TimeTravelActionState]
- func RegisterQosPolicyCleanup() func()
- type ActionState
- type CPUStressActionState
- type CpuStressOpts
- type ExtensionRegistry
- type FillDiskActionState
- type FillDiskOpts
- type FillMemActionState
- type FillMemOpts
- type FillMethod
- type FillMode
- type IOStressLayer
- type IoStressActionState
- type IoStressOpts
- type Mode
- type NetworkActionState
- type ProcessPriority
- type StopProcessActionState
- type TimeTravelActionState
- type Unit
Constants ¶
const ( Percentage FillMode = "PERCENTAGE" MBToFill FillMode = "MB_TO_FILL" MBLeft FillMode = "MB_LEFT" AtOnce FillMethod = "AT_ONCE" OverTime FillMethod = "OVER_TIME" )
const ( ModeUsage Mode = "usage" ModeAbsolute Mode = "absolute" UnitPercent Unit = "%" UnitMegabyte Unit = "MiB" )
const ( WindowsHostTechnology = "Windows Host" BaseActionID = "com.steadybit.extension_host_windows" )
const SteadybitLabelPrefix = "steadybit_label_"
Variables ¶
var FillDiskMethods = struct { AtOnce FillMethod OverTime FillMethod }{ AtOnce: AtOnce, OverTime: OverTime, }
var FillDiskModes = struct { Percentage FillMode MBToFill FillMode MBLeft FillMode }{ Percentage: Percentage, MBToFill: MBToFill, MBLeft: MBLeft, }
var FillMemoryModes = struct { Usage Mode Absolute Mode }{ Usage: ModeUsage, Absolute: ModeAbsolute, }
var FillMemoryUnits = struct { Percent Unit Megabyte Unit }{ Percent: UnitPercent, Megabyte: UnitMegabyte, }
var IOStressLayers = struct { FileSystem IOStressLayer NamedPartition IOStressLayer PhysicalDisk IOStressLayer }{ FileSystem: FileSystem, NamedPartition: NamedPartition, PhysicalDisk: PhysicalDisk, }
var ProcessPriorities = struct { Normal ProcessPriority AboveNormal ProcessPriority High ProcessPriority RealTime ProcessPriority }{ Normal: Normal, AboveNormal: AboveNormal, High: High, RealTime: RealTime, }
Functions ¶
func ActivateWindowsServiceHandler ¶
func ActivateWindowsServiceHandler(stopHandler func()) (isService bool)
ActivateWindowsServiceHandler exits the process only after the service control manager has been told that the service stopped, also on a later log.Fatal. Exiting any earlier, e.g. by returning from main, makes the SCM report the service as "terminated unexpectedly" (error 1067). The service reports RUNNING once the extension serves HTTP. It returns whether the process runs as a service.
func BytesToMegabytes ¶ added in v0.2.0
func CheckTargetHostname ¶
func LogTestSigningStatus ¶ added in v0.5.0
func LogTestSigningStatus()
LogTestSigningStatus records whether test signing is enabled, which helps to diagnose WinDivert driver load failures.
func NewFillDiskAction ¶ added in v0.2.0
func NewFillDiskAction() action_kit_sdk.Action[FillDiskActionState]
func NewFillMemAction ¶ added in v0.2.0
func NewFillMemAction() action_kit_sdk.Action[FillMemActionState]
func NewHostDiscovery ¶
func NewHostDiscovery() discovery_kit_sdk.TargetDiscovery
func NewNetworkBlackholeContainerAction ¶
func NewNetworkBlackholeContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewNetworkBlockDnsContainerAction ¶
func NewNetworkBlockDnsContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewNetworkCorruptPackagesContainerAction ¶
func NewNetworkCorruptPackagesContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewNetworkDelayContainerAction ¶
func NewNetworkDelayContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewNetworkLimitBandwidthContainerAction ¶
func NewNetworkLimitBandwidthContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewNetworkPackageLossContainerAction ¶
func NewNetworkPackageLossContainerAction() action_kit_sdk.Action[NetworkActionState]
func NewShutdownAction ¶
func NewShutdownAction() action_kit_sdk.Action[ActionState]
func NewStopProcessAction ¶
func NewStopProcessAction() action_kit_sdk.Action[StopProcessActionState]
func NewStressCpuAction ¶ added in v0.2.0
func NewStressCpuAction() action_kit_sdk.Action[CPUStressActionState]
func NewStressIoAction ¶ added in v0.2.0
func NewStressIoAction() action_kit_sdk.Action[IoStressActionState]
func NewTimetravelAction ¶
func NewTimetravelAction() action_kit_sdk.Action[TimeTravelActionState]
func RegisterQosPolicyCleanup ¶
func RegisterQosPolicyCleanup() func()
Types ¶
type ActionState ¶
type ActionState struct {
Reboot bool
}
type CPUStressActionState ¶ added in v0.2.0
type CPUStressActionState struct {
StressOpts CpuStressOpts
ExecutionId uuid.UUID
}
type CpuStressOpts ¶ added in v0.2.0
type CpuStressOpts struct {
Cores int
CpuLoad int
Priority ProcessPriority
Duration time.Duration
}
func (*CpuStressOpts) Args ¶ added in v0.2.0
func (o *CpuStressOpts) Args() []string
type ExtensionRegistry ¶ added in v0.2.5
type ExtensionRegistry struct {
// contains filtered or unexported fields
}
func NewExtensionRegistry ¶ added in v0.2.5
func NewExtensionRegistry(name string, port uint16, types []string) *ExtensionRegistry
func (*ExtensionRegistry) Port ¶ added in v0.2.5
func (r *ExtensionRegistry) Port(port uint16)
func (*ExtensionRegistry) RemoveLocalDiscovery ¶ added in v0.2.5
func (r *ExtensionRegistry) RemoveLocalDiscovery() error
func (*ExtensionRegistry) SetupLocalDiscovery ¶ added in v0.2.5
func (r *ExtensionRegistry) SetupLocalDiscovery() error
type FillDiskActionState ¶ added in v0.2.0
type FillDiskActionState struct {
StressOpts FillDiskOpts
ExecutionId uuid.UUID
}
type FillDiskOpts ¶ added in v0.2.0
type FillDiskOpts struct {
Duration time.Duration
FillMode FillMode
Method FillMethod
Path string
ByteSize uint64
BlockSize uint
FilePath string
}
func (*FillDiskOpts) Args ¶ added in v0.2.0
func (o *FillDiskOpts) Args() []string
type FillMemActionState ¶ added in v0.2.0
type FillMemActionState struct {
StressOpts FillMemOpts
ExecutionId uuid.UUID
}
type FillMemOpts ¶ added in v0.2.0
func (*FillMemOpts) Args ¶ added in v0.2.0
func (o *FillMemOpts) Args() []string
type FillMethod ¶ added in v0.2.0
type FillMethod string
func (FillMethod) IsValid ¶ added in v0.2.0
func (fm FillMethod) IsValid() bool
type IOStressLayer ¶ added in v0.2.0
type IOStressLayer string
const ( FileSystem IOStressLayer = "File System" NamedPartition IOStressLayer = "Named Partition" PhysicalDisk IOStressLayer = "Physical Disk" )
func (IOStressLayer) IsValid ¶ added in v0.2.0
func (sl IOStressLayer) IsValid() bool
type IoStressActionState ¶ added in v0.2.0
type IoStressActionState struct {
StressOpts IoStressOpts
ExecutionId uuid.UUID
}
type IoStressOpts ¶ added in v0.2.0
type IoStressOpts struct {
StressLayer IOStressLayer
StressLayerInput string
ThreadCount uint
Duration time.Duration
DisableSwHwCaching bool
}
func (*IoStressOpts) Args ¶ added in v0.2.0
func (o *IoStressOpts) Args() []string
type NetworkActionState ¶
type NetworkActionState struct {
NetworkOpts json.RawMessage
}
type ProcessPriority ¶ added in v0.2.0
type ProcessPriority string
const ( Normal ProcessPriority = "Normal" AboveNormal ProcessPriority = "AboveNormal" High ProcessPriority = "High" RealTime ProcessPriority = "RealTime" )
func (ProcessPriority) IsValid ¶ added in v0.2.0
func (p ProcessPriority) IsValid() bool
type StopProcessActionState ¶
type TimeTravelActionState ¶
Source Files
¶
- action_fill_disk.go
- action_fill_mem.go
- action_network.go
- action_network_bandwidth.go
- action_network_blackhole.go
- action_network_corrupt.go
- action_network_delay.go
- action_network_dns.go
- action_network_loss.go
- action_shutdown.go
- action_stop_process.go
- action_stress_cpu.go
- action_stress_io.go
- action_timetravel.go
- common.go
- discovery.go
- envVars.go
- extension_registry.go
- parameter_groups.go
- service.go