From 51a6e95f58abd65b454e365d45a510eefd84bfe3 Mon Sep 17 00:00:00 2001 From: Carlos Tadeu Panato Junior Date: Tue, 17 Apr 2018 17:06:55 +0200 Subject: add app shutdown to make sure the goroutines finish and all process are closed (#8629) * run the send email verification as goroutine as well * add app shutdown to make sure all go routines finish --- cmd/commands/sampledata.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'cmd/commands/sampledata.go') diff --git a/cmd/commands/sampledata.go b/cmd/commands/sampledata.go index 910913eef..9f4db8616 100644 --- a/cmd/commands/sampledata.go +++ b/cmd/commands/sampledata.go @@ -134,6 +134,8 @@ func sampleDataCmdF(command *cobra.Command, args []string) error { if err != nil { return err } + defer a.Shutdown() + seed, err := command.Flags().GetInt64("seed") if err != nil { return errors.New("Invalid seed parameter") -- cgit v1.2.3-1-g7c22