Documentation ¶
Index ¶
- func NewHandler(handlerType string, dbService database.DBService, jobId string, eventQ *EventQ, ...) (handler, error)
- type DefaultHandler
- type EventQ
- type JobBuilder
- type JobEvent
- type JobHandlerState
- func NewStateApplying(h *DefaultHandler) JobHandlerState
- func NewStateCompleted(h *DefaultHandler) JobHandlerState
- func NewStateDeploying(h *DefaultHandler) JobHandlerState
- func NewStateFailed(h *DefaultHandler) JobHandlerState
- func NewStateReady(h *DefaultHandler) JobHandlerState
- func NewStateRunning(h *DefaultHandler) JobHandlerState
- func NewStateStarting(h *DefaultHandler) JobHandlerState
- func NewStateStopping(h *DefaultHandler) JobHandlerState
- func NewStateTerminated(h *DefaultHandler) JobHandlerState
- type Manager
- type StateApplying
- type StateBase
- func (s *StateBase) ApplyChange()
- func (s *StateBase) ApplyNone()
- func (s *StateBase) CleanUp()
- func (s *StateBase) Complete()
- func (s *StateBase) Deploy(event *JobEvent)
- func (s *StateBase) Fail()
- func (s *StateBase) Run(event *JobEvent)
- func (s *StateBase) Start(event *JobEvent)
- func (s *StateBase) Stop(event *JobEvent)
- func (s *StateBase) Timeout()
- func (s *StateBase) Update(event *JobEvent)
- type StateCompleted
- type StateDeploying
- type StateFailed
- type StateReady
- type StateRunning
- type StateStarting
- type StateStopping
- type StateTerminated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DefaultHandler ¶
type DefaultHandler struct {
// contains filtered or unexported fields
}
func NewDefaultHandler ¶
func (*DefaultHandler) ChangeState ¶
func (h *DefaultHandler) ChangeState(state JobHandlerState)
func (*DefaultHandler) Do ¶
func (h *DefaultHandler) Do()
type EventQ ¶
type EventQ struct {
// contains filtered or unexported fields
}
func (*EventQ) GetJobEventBuffer ¶ added in v0.1.5
type JobBuilder ¶
type JobBuilder struct {
// contains filtered or unexported fields
}
JobBuilder is a struct used to build a job.
func NewJobBuilder ¶
func NewJobBuilder(dbService database.DBService, jobParams config.JobParams) *JobBuilder
type JobHandlerState ¶
type JobHandlerState interface { ApplyChange() ApplyNone() CleanUp() Complete() Deploy(event *JobEvent) Fail() Run(event *JobEvent) Start(event *JobEvent) Stop(event *JobEvent) Timeout() Update(event *JobEvent) }
func NewStateApplying ¶
func NewStateApplying(h *DefaultHandler) JobHandlerState
func NewStateCompleted ¶
func NewStateCompleted(h *DefaultHandler) JobHandlerState
func NewStateDeploying ¶
func NewStateDeploying(h *DefaultHandler) JobHandlerState
func NewStateFailed ¶
func NewStateFailed(h *DefaultHandler) JobHandlerState
func NewStateReady ¶
func NewStateReady(h *DefaultHandler) JobHandlerState
func NewStateRunning ¶
func NewStateRunning(h *DefaultHandler) JobHandlerState
func NewStateStarting ¶
func NewStateStarting(h *DefaultHandler) JobHandlerState
func NewStateStopping ¶
func NewStateStopping(h *DefaultHandler) JobHandlerState
func NewStateTerminated ¶
func NewStateTerminated(h *DefaultHandler) JobHandlerState
type StateApplying ¶
type StateApplying struct {
StateBase
}
func (*StateApplying) ApplyChange ¶
func (s *StateApplying) ApplyChange()
func (*StateApplying) ApplyNone ¶
func (s *StateApplying) ApplyNone()
func (*StateApplying) Stop ¶
func (s *StateApplying) Stop(event *JobEvent)
func (*StateApplying) Timeout ¶
func (s *StateApplying) Timeout()
type StateBase ¶
type StateBase struct {
// contains filtered or unexported fields
}
func (*StateBase) ApplyChange ¶
func (s *StateBase) ApplyChange()
type StateCompleted ¶
type StateCompleted struct {
StateBase
}
type StateDeploying ¶
type StateDeploying struct {
StateBase
}
func (*StateDeploying) Fail ¶
func (s *StateDeploying) Fail()
func (*StateDeploying) Run ¶
func (s *StateDeploying) Run(event *JobEvent)
func (*StateDeploying) Stop ¶
func (s *StateDeploying) Stop(event *JobEvent)
func (*StateDeploying) Timeout ¶
func (s *StateDeploying) Timeout()
type StateFailed ¶
type StateFailed struct {
StateBase
}
type StateReady ¶
type StateReady struct {
StateBase
}
func (*StateReady) Start ¶
func (s *StateReady) Start(event *JobEvent)
type StateRunning ¶
type StateRunning struct {
StateBase
}
func (*StateRunning) Complete ¶
func (s *StateRunning) Complete()
func (*StateRunning) Fail ¶
func (s *StateRunning) Fail()
func (*StateRunning) Stop ¶
func (s *StateRunning) Stop(event *JobEvent)
func (*StateRunning) Timeout ¶
func (s *StateRunning) Timeout()
func (*StateRunning) Update ¶
func (s *StateRunning) Update(event *JobEvent)
type StateStarting ¶
type StateStarting struct {
StateBase
}
func (*StateStarting) Deploy ¶
func (s *StateStarting) Deploy(event *JobEvent)
func (*StateStarting) Fail ¶
func (s *StateStarting) Fail()
func (*StateStarting) Timeout ¶
func (s *StateStarting) Timeout()
type StateStopping ¶
type StateStopping struct {
StateBase
}
func (*StateStopping) CleanUp ¶
func (s *StateStopping) CleanUp()
type StateTerminated ¶
type StateTerminated struct {
StateBase
}
Click to show internal directories.
Click to hide internal directories.