Procházet zdrojové kódy

fix #55 : now that we have split the code for external shutdown (service) and one-shot, we don't need the 5s sleep anymore (#56)

Thibault "bui" Koechlin před 5 roky
rodič
revize
ea3b9d9de0
1 změnil soubory, kde provedl 0 přidání a 2 odebrání
  1. 0 2
      cmd/crowdsec/serve.go

+ 0 - 2
cmd/crowdsec/serve.go

@@ -26,8 +26,6 @@ func termHandler(sig os.Signal) error {
 		log.Warningf("Acquisition returned error : %s", err)
 	}
 	log.Infof("acquisition is finished, wait for parser/bucket/ouputs.")
-	//let's wait more than enough for in-flight events to be parsed.
-	time.Sleep(5 * time.Second)
 	parsersTomb.Kill(nil)
 	if err := parsersTomb.Wait(); err != nil {
 		log.Warningf("Parsers returned error : %s", err)