Documentation
¶
Index ¶
Constants ¶
View Source
const (
AbortTimeoutSec = 10
)
Variables ¶
This section is empty.
Functions ¶
func NewBoundedExecer ¶
func NewBoundedExecer(memCap scootexecer.Memory, getMemUtilization func() (int64, error), stat stats.StatsReceiver) *execer
NewBoundedExecer returns an execer with a ProcGetter and, if non-zero values are provided, a memCap, overriding memory utilization function, and a StatsReceiver
func NewProcWatcher ¶
func NewProcWatcher() *procWatcher
Types ¶
type ProcessWatcher ¶
type ProcessWatcher interface {
GetProcs() (map[int]ProcInfo, error)
MemUsage(int) (scootexecer.Memory, error)
LogProcs(*process, log.Level, io.Writer)
}
Used for mocking memCap monitoring
type WriterDelegater ¶
type WriterDelegater interface {
// Return an underlying Writer. Why? Because some methods type assert to
// a more specific type and are more clever (e.g., if it's an *os.File, hook it up
// directly to a new process's stdout/stderr.)
// We care about this cleverness, so Output both is-a and has-a Writer
// Cf. runner/runners/local_output.go
WriterDelegate() io.Writer
}
Click to show internal directories.
Click to hide internal directories.