Explorar el Código

fix(server/peer_server): stop the raftServer in Stop()

Stop() the raftServer if we stop the peerServer so that tests that start
and stop PeerServers exit cleanly.
Brandon Philips hace 12 años
padre
commit
1b3481fe25
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      server/peer_server.go

+ 1 - 0
server/peer_server.go

@@ -158,6 +158,7 @@ func (s *PeerServer) Stop() {
 		close(s.closeChan)
 		s.closeChan = nil
 	}
+	s.raftServer.Stop()
 }
 
 func (s *PeerServer) HTTPHandler() http.Handler {