Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Job ¶
type Job interface { Config() *JobConfig JobConfirmer() JobConfirmer }
Job contains all nessisary information to run a job on a worker
type JobConfig ¶
type JobConfig struct { Name string `json:"name"` // Name the name of the job CaptureOutput bool `json:"capture_output"` // CaptureOutput if this is true, OutputWritter can not be nil! OutputWriter io.Writer `json:"-"` // The writter that will be used to process the output (only used if CaptureOutput is true) Params json.RawMessage `json:"params"` // Params list of parameters to be given to the job at call time Type string `json:"type"` // Type describes how this job can be run Retries int `json:"retries"` // Retries if this job fails, how many times should we retry // contains filtered or unexported fields }
JobConfig configureation options for a job
func ParseConfig ¶
ParseConfig takes a byte slice, atempts to parse it, and returns the new JobConfig
type JobConfirmer ¶
Confirms that a job has been completed
Click to show internal directories.
Click to hide internal directories.