Added the UpdataStrategy struct to the api/jobs struct so that we don't loose the information passed on from the cli

This commit is contained in:
Diptanu Choudhury
2015-10-20 16:16:05 -07:00
parent 60eda624ec
commit 7b843626b0

View File

@@ -100,6 +100,12 @@ func (j *Jobs) ForceEvaluate(jobID string, q *WriteOptions) (string, *WriteMeta,
return resp.EvalID, wm, nil
}
//UpdateStrategy is for serializing update strategy for a job.
type UpdateStrategy struct {
Stagger time.Duration
MaxParallel int
}
// Job is used to serialize a job.
type Job struct {
Region string
@@ -111,6 +117,7 @@ type Job struct {
Datacenters []string
Constraints []*Constraint
TaskGroups []*TaskGroup
Update *UpdateStrategy
Meta map[string]string
Status string
StatusDescription string