Skip to content

Commit

Permalink
Fix for proxy exiting early
Browse files Browse the repository at this point in the history
When a proxied core service was accessed before it was ready
to accept a connection, due to a start-up, restart, etc of
a core service, then the proxy exited instead of continuing
to accept new connections.

This meant having to restart faasd and hope the race condition
worked itself out, or that no incoming requests were made.

Tested with Grafana, which seemed to manifest the issue
the most.

Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
  • Loading branch information
alexellis committed Jan 30, 2025
1 parent ef689d7 commit d7e0beb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (p *Proxy) Start() error {
conn.Close()

log.Printf("Unable to dial: %s, error: %s", upstreamAddr, err.Error())
return err
continue
}

go pipe(conn, upstream)
Expand Down

0 comments on commit d7e0beb

Please sign in to comment.