chg: [exit] sleep for 30 seconds instead of exiting on emtpy queue

master
Jean-Louis Huynen 2019-06-12 15:59:28 +02:00
parent 46dbd20e4b
commit 110cc29d18
No known key found for this signature in database
GPG Key ID: 64799157F4BD6B93
1 changed files with 2 additions and 2 deletions

View File

@ -177,7 +177,7 @@ func main() {
err := errors.New("")
jsonPath, err = redis.String(cr.Do("LPOP", "analyzer:"+c.redisQueue))
if err != nil {
log.Fatal("Queue processed")
time.Sleep(30 * time.Second)
}
processFile(c.certPath, jsonPath)
@ -452,7 +452,7 @@ func insertCertificate(fp string, c certMapElm) (string, error) {
// getFullPath takes a certificate's hash and return the full path to
// its location on disk
func getFullPath(c string, h string) string {
return c+h
return c + h
}
func insertCertificates(fp string, s *sessionRecord) ([]string, error) {