From 6d007762a05a4e265351083e1c23bc16508d416e Mon Sep 17 00:00:00 2001 From: "Alex Ellis (OpenFaaS Ltd)" Date: Thu, 30 Jan 2025 09:10:25 +0000 Subject: [PATCH] Fix for proxy exiting early 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) --- pkg/proxy.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/proxy.go b/pkg/proxy.go index daad079..f56fc9a 100644 --- a/pkg/proxy.go +++ b/pkg/proxy.go @@ -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)