Skip to content

Commit

Permalink
List unblocks on summary changes
Browse files Browse the repository at this point in the history
  • Loading branch information
dadgar committed Mar 15, 2018
1 parent 2f325cf commit 7440e23
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions nomad/job_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -797,12 +797,16 @@ func (j *Job) List(args *structs.JobListRequest,
}
reply.Jobs = jobs

// Use the last index that affected the jobs table
index, err := state.Index("jobs")
// Use the last index that affected the jobs table or summary
jindex, err := state.Index("jobs")
if err != nil {
return err
}
reply.Index = index
sindex, err := state.Index("job_summary")
if err != nil {
return err
}
reply.Index = helper.Uint64Max(jindex, sindex)

// Set the query response
j.srv.setQueryMeta(&reply.QueryMeta)
Expand Down

0 comments on commit 7440e23

Please sign in to comment.