Skip to content

Commit

Permalink
Merge pull request #5823 from hashicorp/dani/fix-restart-api
Browse files Browse the repository at this point in the history
alloc-lifecycle: Fix restart with empty body
  • Loading branch information
endocrimes authored Jun 12, 2019
2 parents fe7c2ec + 91c7cf9 commit 2ce49f6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ BUG FIXES:
* core: Fixed a panic that may occur when preempting jobs for network resources [[GH-5794](https://github.com/hashicorp/nomad/issues/5794)]
* core: Fixed a config parsing issue when client metadata contains a boolean value [[GH-5802](https://github.com/hashicorp/nomad/issues/5802)]
* core: Fixed a config parsing issue where consul, vault, and autopilot stanzas break when using a config directory [[GH-5817](https://github.com/hashicorp/nomad/issues/5817)]
* api: Allow sumitting alloc restart requests with an empty body [[GH-5823](https://github.com/hashicorp/nomad/pull/5823)]
* client: Fixed an issue where task restart attempts is not honored properly [[GH-5737](https://github.com/hashicorp/nomad/issues/5737)]
* client: Fixed a panic that occurs when a 0.9.2 client is running with 0.8 nomad servers [[GH-5812](https://github.com/hashicorp/nomad/issues/5812)]

Expand Down
2 changes: 1 addition & 1 deletion command/agent/alloc_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ func (s *HTTPServer) allocRestart(allocID string, resp http.ResponseWriter, req
TaskName string
}
err := json.NewDecoder(req.Body).Decode(&reqBody)
if err != nil {
if err != nil && err != io.EOF {
return nil, err
}
if reqBody.TaskName != "" {
Expand Down

0 comments on commit 2ce49f6

Please sign in to comment.