Documentation
¶
Index ¶
Constants ¶
View Source
const ( // StateInactive - no associated process StateInactive int64 = iota // StateReady - ready for job. StateReady // StateWorking - working on given payload. StateWorking // StateInvalid - indicates that WorkerProcess is being disabled and will be removed. StateInvalid // StateStopping - process is being softly stopped. StateStopping // StateStopped - process has been terminated. StateStopped // StateDestroyed State of worker, when no need to allocate new one StateDestroyed // StateMaxJobsReached State of worker, when it reached executions limit StateMaxJobsReached // StateErrored - error StateImpl (can't be used). StateErrored // StateIdleTTLReached - worker idle TTL was reached StateIdleTTLReached // StateTTLReached - worker TTL was reached StateTTLReached // StateMaxMemoryReached - worker max memory limit was reached StateMaxMemoryReached // StateExecTTLReached - worker execution TTL was reached StateExecTTLReached )
All worker states
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Fsm ¶
type Fsm struct {
// contains filtered or unexported fields
}
Fsm is general https://en.wikipedia.org/wiki/Finite-state_machine to transition between worker states
func (*Fsm) RegisterExec ¶
func (s *Fsm) RegisterExec()
RegisterExec register new execution atomically
func (*Fsm) Transition ¶
Transition moves worker from one state to another
Click to show internal directories.
Click to hide internal directories.