Skip to content

Commit

Permalink
close store after stoping worker (#4356)
Browse files Browse the repository at this point in the history
Signed-off-by: பாலாஜி <balaji@dgraph.io>
  • Loading branch information
poonai authored Dec 6, 2019
1 parent 747c847 commit 95c5865
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions dgraph/cmd/alpha/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -502,10 +502,6 @@ func run() {
glog.Infof("worker.Config: %s", worker.Config)

worker.InitServerState()
defer func() {
worker.State.Dispose()
glog.Info("Finished disposing server state.")
}()

if Alpha.Conf.GetBool("expose_trace") {
// TODO: Remove this once we get rid of event logs.
Expand Down Expand Up @@ -566,5 +562,7 @@ func run() {
glog.Infoln("GRPC and HTTP stopped.")
aclCloser.SignalAndWait()
worker.BlockingStop()
glog.Info("Disposing server state.")
worker.State.Dispose()
glog.Infoln("Server shutdown. Bye!")
}

0 comments on commit 95c5865

Please sign in to comment.