From 30376deb94f98ca8c3f124ceac53bcccc9ba4360 Mon Sep 17 00:00:00 2001 From: kanoi Date: Sat, 22 Aug 2015 22:36:20 +1000 Subject: [PATCH] ckdb - demote successful missing workerstatus/worker messages to notice --- src/ckdb.h | 2 +- src/ckdb_data.c | 15 ++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/ckdb.h b/src/ckdb.h index 1038b5a0..c0f1eaec 100644 --- a/src/ckdb.h +++ b/src/ckdb.h @@ -55,7 +55,7 @@ #define DB_VLOCK "1" #define DB_VERSION "1.0.2" -#define CKDB_VERSION DB_VERSION"-1.225" +#define CKDB_VERSION DB_VERSION"-1.226" #define WHERE_FFL " - from %s %s() line %d" #define WHERE_FFL_HERE __FILE__, __func__, __LINE__ diff --git a/src/ckdb_data.c b/src/ckdb_data.c index 51ab0396..ab3f5913 100644 --- a/src/ckdb_data.c +++ b/src/ckdb_data.c @@ -882,12 +882,17 @@ K_ITEM *_find_create_workerstatus(int64_t userid, char *workername, K_WUNLOCK(workerstatus_free); if (ws_err) { - LOGERR("%s(): CREATED Missing workerstatus %"PRId64"/%s" - WHERE_FFL WHERE_FFL, - __func__, userid, workername, - file2, func2, line2, WHERE_FFL_PASS); + LOGNOTICE("%s(): CREATED Missing workerstatus" + " %"PRId64"/%s" + WHERE_FFL WHERE_FFL, + __func__, userid, workername, + file2, func2, line2, WHERE_FFL_PASS); if (w_err) { - LOGERR("%s(): %s Missing worker %"PRId64"/%s", + int sta = LOG_ERR; + if (w_item) + sta = LOG_NOTICE; + LOGMSG(sta, + "%s(): %s Missing worker %"PRId64"/%s", __func__, w_item ? "CREATED" : "FAILED TO CREATE", userid, workername);