phobos-storage / phobos

This repository holds the source code for Phobos, a Parallel Heterogeneous Object Store.
GNU Lesser General Public License v2.1
3 stars 2 forks source link

change log level for "dss_object_get failed for objid" to debug? #15

Open thiell opened 2 weeks ago

thiell commented 2 weeks ago

Super minor but would it be possible to change the log level for the message "dss_object_get failed for objid" from verbose to debug? I like to run phobosd in verbose mode but this one is printed for each new object (so it is normal that it cannot find the object). Also the "failed" in the message seems to flag it as error (in red) by journald, as shown on this screenshot, which could be confusing for new phobos users:

Screenshot 2024-09-14 at 11 17 24 AM

I personnally use the following change but would be nice if it could be added upstream (if you agree):

diff --git a/src/store/store.c b/src/store/store.c
index 48dd8b8..fe10227 100644
--- a/src/store/store.c
+++ b/src/store/store.c
@@ -359,7 +359,7 @@ int object_md_save(struct dss_handle *dss, struct pho_xfer_desc *xfer)
         rc = dss_object_get(dss, &filter, &obj_res, &obj_cnt, NULL);
         dss_filter_free(&filter);
         if (rc || obj_cnt == 0) {
-            pho_verb("dss_object_get failed for objid:'%s'", xfer->xd_objid);
+            pho_debug("dss_object_get failed for objid:'%s'", xfer->xd_objid);

             /**
              * If we try overwritting an object that doesn't exist in the