Documentation ¶
Index ¶
- type CopiedIn
- type CopiedOut
- type CopyInCallback
- type CopyOutCallback
- type DiskLimit
- type FakeGordon
- func (f *FakeGordon) Attach(handle string, jobID uint32) (<-chan *warden.ProcessPayload, error)
- func (f *FakeGordon) CPULimits() []Limit
- func (f *FakeGordon) Connect() error
- func (f *FakeGordon) CopyIn(handle, src, dst string) (*warden.CopyInResponse, error)
- func (f *FakeGordon) CopyOut(handle, src, dst, owner string) (*warden.CopyOutResponse, error)
- func (f *FakeGordon) Create(properties map[string]string) (*warden.CreateResponse, error)
- func (f *FakeGordon) CreatedHandles() []string
- func (f *FakeGordon) CreatedProperties(handle string) map[string]string
- func (f *FakeGordon) Destroy(handle string) (*warden.DestroyResponse, error)
- func (f *FakeGordon) DestroyedHandles() []string
- func (f *FakeGordon) DiskLimits() []DiskLimit
- func (f *FakeGordon) GetDiskLimit(handle string) (uint64, error)
- func (f *FakeGordon) GetMemoryLimit(handle string) (uint64, error)
- func (f *FakeGordon) Info(handle string) (*warden.InfoResponse, error)
- func (f *FakeGordon) LimitCPU(handle string, limitInShares uint64) (*warden.LimitCpuResponse, error)
- func (f *FakeGordon) LimitDisk(handle string, limits gordon.DiskLimits) (*warden.LimitDiskResponse, error)
- func (f *FakeGordon) LimitMemory(handle string, limit uint64) (*warden.LimitMemoryResponse, error)
- func (f *FakeGordon) List(filterProperties map[string]string) (*warden.ListResponse, error)
- func (f *FakeGordon) MemoryLimits() []Limit
- func (f *FakeGordon) NetIn(handle string) (*warden.NetInResponse, error)
- func (f *FakeGordon) Reset()
- func (f *FakeGordon) Run(handle string, script string, resourceLimits gordon.ResourceLimits, ...) (uint32, <-chan *warden.ProcessPayload, error)
- func (f *FakeGordon) ScriptsThatRan() []*RunningScript
- func (f *FakeGordon) SetCopyInErr(err error)
- func (f *FakeGordon) SetCopyOutErr(err error)
- func (f *FakeGordon) SetCopyOutFileContent(data []byte)
- func (f *FakeGordon) SetInfoError(err error)
- func (f *FakeGordon) SetInfoResponse(response *warden.InfoResponse)
- func (f *FakeGordon) SetLimitCPUError(err error)
- func (f *FakeGordon) SetLimitDiskError(err error)
- func (f *FakeGordon) SetLimitMemoryError(err error)
- func (f *FakeGordon) SetRunReturnValues(processID uint32, processPayloadChan <-chan *warden.ProcessPayload, err error)
- func (f *FakeGordon) Stop(handle string, background, kill bool) (*warden.StopResponse, error)
- func (f *FakeGordon) StoppedHandles() []string
- func (f *FakeGordon) ThingsCopiedIn() []*CopiedIn
- func (f *FakeGordon) ThingsCopiedOut() []*CopiedOut
- func (f *FakeGordon) WhenCopyingIn(copiedIn CopiedIn, callback CopyInCallback)
- func (f *FakeGordon) WhenCopyingOut(copiedOut CopiedOut, callback CopyOutCallback)
- func (f *FakeGordon) WhenListing(callback ListCallback)
- func (f *FakeGordon) WhenRunning(handle string, script string, resourceLimits gordon.ResourceLimits, ...)
- type Limit
- type ListCallback
- type RunCallback
- type RunningScript
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CopyInCallback ¶
type CopyOutCallback ¶
type DiskLimit ¶
type DiskLimit struct { Handle string Limits gordon.DiskLimits }
type FakeGordon ¶
type FakeGordon struct { Connected bool ConnectError error CreateError error StopError error DestroyError error SpawnError error LinkError error NetInError error GetMemoryLimitError error GetDiskLimitError error AttachError error // contains filtered or unexported fields }
func New ¶
func New() *FakeGordon
func (*FakeGordon) Attach ¶
func (f *FakeGordon) Attach(handle string, jobID uint32) (<-chan *warden.ProcessPayload, error)
func (*FakeGordon) CPULimits ¶
func (f *FakeGordon) CPULimits() []Limit
func (*FakeGordon) Connect ¶
func (f *FakeGordon) Connect() error
func (*FakeGordon) CopyIn ¶
func (f *FakeGordon) CopyIn(handle, src, dst string) (*warden.CopyInResponse, error)
func (*FakeGordon) CopyOut ¶
func (f *FakeGordon) CopyOut(handle, src, dst, owner string) (*warden.CopyOutResponse, error)
func (*FakeGordon) Create ¶
func (f *FakeGordon) Create(properties map[string]string) (*warden.CreateResponse, error)
func (*FakeGordon) CreatedHandles ¶
func (f *FakeGordon) CreatedHandles() []string
func (*FakeGordon) CreatedProperties ¶
func (f *FakeGordon) CreatedProperties(handle string) map[string]string
func (*FakeGordon) Destroy ¶
func (f *FakeGordon) Destroy(handle string) (*warden.DestroyResponse, error)
func (*FakeGordon) DestroyedHandles ¶
func (f *FakeGordon) DestroyedHandles() []string
func (*FakeGordon) DiskLimits ¶
func (f *FakeGordon) DiskLimits() []DiskLimit
func (*FakeGordon) GetDiskLimit ¶
func (f *FakeGordon) GetDiskLimit(handle string) (uint64, error)
func (*FakeGordon) GetMemoryLimit ¶
func (f *FakeGordon) GetMemoryLimit(handle string) (uint64, error)
func (*FakeGordon) Info ¶
func (f *FakeGordon) Info(handle string) (*warden.InfoResponse, error)
func (*FakeGordon) LimitCPU ¶
func (f *FakeGordon) LimitCPU(handle string, limitInShares uint64) (*warden.LimitCpuResponse, error)
func (*FakeGordon) LimitDisk ¶
func (f *FakeGordon) LimitDisk(handle string, limits gordon.DiskLimits) (*warden.LimitDiskResponse, error)
func (*FakeGordon) LimitMemory ¶
func (f *FakeGordon) LimitMemory(handle string, limit uint64) (*warden.LimitMemoryResponse, error)
func (*FakeGordon) List ¶
func (f *FakeGordon) List(filterProperties map[string]string) (*warden.ListResponse, error)
func (*FakeGordon) MemoryLimits ¶
func (f *FakeGordon) MemoryLimits() []Limit
func (*FakeGordon) NetIn ¶
func (f *FakeGordon) NetIn(handle string) (*warden.NetInResponse, error)
func (*FakeGordon) Reset ¶
func (f *FakeGordon) Reset()
func (*FakeGordon) Run ¶
func (f *FakeGordon) Run(handle string, script string, resourceLimits gordon.ResourceLimits, environmentVariables []gordon.EnvironmentVariable) (uint32, <-chan *warden.ProcessPayload, error)
func (*FakeGordon) ScriptsThatRan ¶
func (f *FakeGordon) ScriptsThatRan() []*RunningScript
func (*FakeGordon) SetCopyInErr ¶
func (f *FakeGordon) SetCopyInErr(err error)
func (*FakeGordon) SetCopyOutErr ¶
func (f *FakeGordon) SetCopyOutErr(err error)
func (*FakeGordon) SetCopyOutFileContent ¶
func (f *FakeGordon) SetCopyOutFileContent(data []byte)
func (*FakeGordon) SetInfoError ¶
func (f *FakeGordon) SetInfoError(err error)
func (*FakeGordon) SetInfoResponse ¶
func (f *FakeGordon) SetInfoResponse(response *warden.InfoResponse)
func (*FakeGordon) SetLimitCPUError ¶
func (f *FakeGordon) SetLimitCPUError(err error)
func (*FakeGordon) SetLimitDiskError ¶
func (f *FakeGordon) SetLimitDiskError(err error)
func (*FakeGordon) SetLimitMemoryError ¶
func (f *FakeGordon) SetLimitMemoryError(err error)
func (*FakeGordon) SetRunReturnValues ¶
func (f *FakeGordon) SetRunReturnValues(processID uint32, processPayloadChan <-chan *warden.ProcessPayload, err error)
func (*FakeGordon) Stop ¶
func (f *FakeGordon) Stop(handle string, background, kill bool) (*warden.StopResponse, error)
func (*FakeGordon) StoppedHandles ¶
func (f *FakeGordon) StoppedHandles() []string
func (*FakeGordon) ThingsCopiedIn ¶
func (f *FakeGordon) ThingsCopiedIn() []*CopiedIn
func (*FakeGordon) ThingsCopiedOut ¶
func (f *FakeGordon) ThingsCopiedOut() []*CopiedOut
func (*FakeGordon) WhenCopyingIn ¶
func (f *FakeGordon) WhenCopyingIn(copiedIn CopiedIn, callback CopyInCallback)
func (*FakeGordon) WhenCopyingOut ¶
func (f *FakeGordon) WhenCopyingOut(copiedOut CopiedOut, callback CopyOutCallback)
func (*FakeGordon) WhenListing ¶
func (f *FakeGordon) WhenListing(callback ListCallback)
func (*FakeGordon) WhenRunning ¶
func (f *FakeGordon) WhenRunning(handle string, script string, resourceLimits gordon.ResourceLimits, environmentVariables []gordon.EnvironmentVariable, callback RunCallback)
type ListCallback ¶
type ListCallback func(filterProperties map[string]string) (*warden.ListResponse, error)
type RunCallback ¶
type RunCallback func() (uint32, <-chan *warden.ProcessPayload, error)
type RunningScript ¶
type RunningScript struct { Handle string Script string ResourceLimits gordon.ResourceLimits EnvironmentVariables []gordon.EnvironmentVariable }
Click to show internal directories.
Click to hide internal directories.