mirror of
https://github.com/status-im/consul.git
synced 2025-02-01 16:37:12 +00:00
server: ensure that we also shutdown network segment serf instances on server shutdown (#8786)
This really only matters for unit tests, since typically if an agent shuts down its server, it follows that up by exiting the process, which would also clean up all of the networking anyway.
This commit is contained in:
parent
e138a6499c
commit
237a7a0da0
3
.changelog/8786.txt
Normal file
3
.changelog/8786.txt
Normal file
@ -0,0 +1,3 @@
|
||||
```release-note:improvement
|
||||
server: **(Consul Enterprise only)** ensure that we also shutdown network segment serf instances on server shutdown
|
||||
```
|
@ -914,6 +914,10 @@ func (s *Server) Shutdown() error {
|
||||
s.serfLAN.Shutdown()
|
||||
}
|
||||
|
||||
for _, segment := range s.segmentLAN {
|
||||
segment.Shutdown()
|
||||
}
|
||||
|
||||
if s.serfWAN != nil {
|
||||
s.serfWAN.Shutdown()
|
||||
if err := s.router.RemoveArea(types.AreaWAN); err != nil {
|
||||
|
Loading…
x
Reference in New Issue
Block a user