diff --git a/server/events.go b/server/events.go index 7a51add5..1cd9d995 100644 --- a/server/events.go +++ b/server/events.go @@ -828,6 +828,9 @@ func (s *Server) addSystemAccountExports(sacc *Account) { if err := sacc.AddServiceExport(accSubsSubj, nil); err != nil { s.Errorf("Error adding system service export for %q: %v", accSubsSubj, err) } + if s.JetStreamEnabled() { + s.checkJetStreamExports() + } } // accountClaimUpdate will receive claim updates for accounts. diff --git a/server/jetstream.go b/server/jetstream.go index 6704d272..7e71a58a 100644 --- a/server/jetstream.go +++ b/server/jetstream.go @@ -333,7 +333,6 @@ func (s *Server) DisableJetStream() error { } // Once here we can forward our proposal to remove ourselves. meta.ProposeRemovePeer(meta.ID()) - time.Sleep(250 * time.Millisecond) meta.Delete() } } diff --git a/server/reload.go b/server/reload.go index 7ac6b143..09ac07af 100644 --- a/server/reload.go +++ b/server/reload.go @@ -1,4 +1,4 @@ -// Copyright 2017-2020 The NATS Authors +// Copyright 2017-2021 The NATS Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at