From c16c05034797583036d30d5d5d53847cdaea00f5 Mon Sep 17 00:00:00 2001 From: andrewsykim Date: Thu, 30 Aug 2018 15:07:58 -0400 Subject: [PATCH] dont shutdown gobgp server if graceful restart is enabled --- pkg/controllers/routing/network_routes_controller.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/controllers/routing/network_routes_controller.go b/pkg/controllers/routing/network_routes_controller.go index d5837d0d5a..baf5eecc5d 100644 --- a/pkg/controllers/routing/network_routes_controller.go +++ b/pkg/controllers/routing/network_routes_controller.go @@ -222,7 +222,9 @@ func (nrc *NetworkRoutingController) Run(healthChan chan<- *healthcheck.Controll } nrc.bgpServerStarted = true - defer nrc.bgpServer.Shutdown() + if !nrc.bgpGracefulRestart { + defer nrc.bgpServer.Shutdown() + } // loop forever till notified to stop on stopCh for {