From b731d5e5641110b891b04951b8dda46bc30d6e9b Mon Sep 17 00:00:00 2001 From: deepthi Date: Fri, 3 Nov 2023 14:51:11 -0700 Subject: [PATCH] servenv: reset ListeningURL when closing Signed-off-by: deepthi --- go/vt/servenv/run.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/go/vt/servenv/run.go b/go/vt/servenv/run.go index 70b534bdcc3..6f028786eaf 100644 --- a/go/vt/servenv/run.go +++ b/go/vt/servenv/run.go @@ -18,6 +18,7 @@ package servenv import ( "net" + "net/url" "os" "os/signal" "strconv" @@ -73,6 +74,7 @@ func Run(bindAddress string, port int) { log.Info("Shutting down gracefully") fireOnCloseHooks(onCloseTimeout) + ListeningURL = url.URL{} } // OnClose registers f to be run at the end of the app lifecycle.