From 5c73e43912bcd55844c1c56d432e9b517b6f91d1 Mon Sep 17 00:00:00 2001 From: Irena Rindos Date: Tue, 13 Dec 2022 14:25:40 -0500 Subject: [PATCH] revert 2712 (#2713) --- internal/daemon/worker/status.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/internal/daemon/worker/status.go b/internal/daemon/worker/status.go index 7f9f2dab8..e4db0fa3b 100644 --- a/internal/daemon/worker/status.go +++ b/internal/daemon/worker/status.go @@ -347,6 +347,20 @@ func (w *Worker) updateAddresses(cancelCtx context.Context, addrs []string, addr event.WriteSysEvent(cancelCtx, op, fmt.Sprintf("Upstreams after first status set to: %s", addrs)) } } + + // regardless of whether or not it's a new address, we need to set + // them for dialingListeners + for _, as := range *addressReceivers { + switch { + case as.Type() == dialingListenerReceiverType: + tmpAddrs := make([]string, len(addrs)) + copy(tmpAddrs, addrs) + if len(tmpAddrs) == 0 { + tmpAddrs = append(tmpAddrs, w.conf.RawConfig.Worker.InitialUpstreams...) + } + as.SetAddresses(tmpAddrs) + } + } } // cleanupConnections walks all sessions and shuts down all proxy connections.