2
0
mirror of https://github.com/hibiken/asynq.git synced 2026-06-19 10:37:39 +08:00

Update log messages on shutdown

This commit is contained in:
Ken Hibino
2019-11-27 06:33:04 -08:00
parent 60132f3208
commit e6b1230c36
3 changed files with 8 additions and 8 deletions

View File

@@ -1,6 +1,7 @@
package asynq
import (
"fmt"
"os"
"os/signal"
"sync"
@@ -49,6 +50,7 @@ func (bg *Background) Run(handler TaskHandler) {
sigs := make(chan os.Signal, 1)
signal.Notify(sigs, os.Interrupt, os.Kill)
<-sigs
fmt.Printf("\nStarting graceful shutdown...\n")
}
// starts the background-task processing.