(fix): Change log messages depending on signals being handled

This commit is contained in:
Ken Hibino
2020-04-10 08:47:43 -07:00
parent 84b0c76c8b
commit 7e96e893fe
3 changed files with 4 additions and 3 deletions

View File

@@ -16,6 +16,9 @@ import (
// SIGTERM and SIGINT will signal the process to exit.
// SIGTSTP will signal the process to stop processing new tasks.
func (bg *Background) waitForSignals() {
bg.logger.Info("Send signal TSTP to stop processing new tasks")
bg.logger.Info("Send signal TERM or INT to terminate the process")
sigs := make(chan os.Signal, 1)
signal.Notify(sigs, unix.SIGTERM, unix.SIGINT, unix.SIGTSTP)
for {