Skip to content

Commit

Permalink
Merge pull request #7274 from hashicorp/b-exec-tls
Browse files Browse the repository at this point in the history
api: alloc exec recovers from bad client connection
  • Loading branch information
Mahmood Ali committed Apr 9, 2020
1 parent 2e2ee7d commit 484dabe
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions api/allocations.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
"errors"
"fmt"
"io"
"net"
"sort"
"strconv"
"sync"
Expand Down Expand Up @@ -234,11 +233,7 @@ func (a *Allocations) execFrames(ctx context.Context, alloc *Allocation, task st
var conn *websocket.Conn

if nodeClient != nil {
conn, _, err = nodeClient.websocket(reqPath, q)
if _, ok := err.(net.Error); err != nil && !ok {
errCh <- err
return nil, nil
}
conn, _, _ = nodeClient.websocket(reqPath, q)
}

if conn == nil {
Expand Down

0 comments on commit 484dabe

Please sign in to comment.