Fix proxy not healthy before graceful stop (#28223)

Signed-off-by: Wei Liu <wei.liu@zilliz.com>
This commit is contained in:
wei liu 2023-11-08 02:22:26 +08:00 committed by GitHub
parent 2b5f632fa4
commit 64f6dbabdc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -640,8 +640,6 @@ func (s *Server) start() error {
func (s *Server) Stop() error {
Params := &paramtable.Get().ProxyGrpcServerCfg
log.Debug("Proxy stop", zap.String("internal address", Params.GetInternalAddress()), zap.String("external address", Params.GetInternalAddress()))
s.proxy.UpdateStateCode(commonpb.StateCode_Abnormal)
var err error
if s.etcdCli != nil {
defer s.etcdCli.Close()
@ -670,7 +668,7 @@ func (s *Server) Stop() error {
s.wg.Wait()
err = s.proxy.Stop()
err := s.proxy.Stop()
if err != nil {
return err
}