diff options
author | Nandaja Varma <nandaja.varma@gmail.com> | 2015-03-05 13:41:10 +0530 |
---|---|---|
committer | Kaushal M <kaushal@redhat.com> | 2015-05-04 22:14:29 -0700 |
commit | 6d7428d2018c061ca2791443bd90980f9755ded3 (patch) | |
tree | 9d705ed391ab0e546528b21a2c48c1f0a7df9d2f /xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c | |
parent | e6f2472d2434ab43a30720ef4de2e0abc0a3f4ac (diff) |
mgmt/glusterd: Porting messages to new logging framework
Change-Id: I25f3536446798ea1cffd6b5dfbb3d2398766fcf3
BUG: 1194640
Signed-off-by: Nandaja Varma <nandaja.varma@gmail.com>
Reviewed-on: http://review.gluster.org/9808
Tested-by: NetBSD Build System
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c | 158 |
1 files changed, 101 insertions, 57 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c b/xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c index 859690eee65..db5a19bf675 100644 --- a/xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c +++ b/xlators/mgmt/glusterd/src/glusterd-mgmt-handler.c @@ -19,6 +19,7 @@ #include "glusterd-locks.h" #include "glusterd-mgmt.h" #include "glusterd-op-sm.h" +#include "glusterd-messages.h" static int glusterd_mgmt_v3_null (rpcsvc_request_t *req) @@ -47,7 +48,7 @@ glusterd_mgmt_v3_lock_send_resp (rpcsvc_request_t *req, int32_t status) ret = glusterd_submit_reply (req, &rsp, NULL, 0, NULL, (xdrproc_t)xdr_gd1_mgmt_v3_lock_rsp); - gf_log (this->name, GF_LOG_DEBUG, + gf_msg_debug (this->name, 0, "Responded to mgmt_v3 lock, ret: %d", ret); return ret; @@ -70,13 +71,14 @@ glusterd_synctasked_mgmt_v3_lock (rpcsvc_request_t *req, /* Trying to acquire multiple mgmt_v3 locks */ ret = glusterd_multiple_mgmt_v3_lock (ctx->dict, ctx->uuid); if (ret) - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_LOCK_GET_FAIL, "Failed to acquire mgmt_v3 locks for %s", uuid_utoa (ctx->uuid)); ret = glusterd_mgmt_v3_lock_send_resp (req, ret); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } @@ -98,7 +100,8 @@ glusterd_op_state_machine_mgmt_v3_lock (rpcsvc_request_t *req, ret = glusterd_set_txn_opinfo (&lock_req->txn_id, &txn_op_info); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_OPINFO_SET_FAIL, "Unable to set transaction's opinfo"); goto out; } @@ -106,14 +109,15 @@ glusterd_op_state_machine_mgmt_v3_lock (rpcsvc_request_t *req, ret = glusterd_op_sm_inject_event (GD_OP_EVENT_LOCK, &lock_req->txn_id, ctx); if (ret) - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_OP_EVENT_LOCK_FAIL, "Failed to inject event GD_OP_EVENT_LOCK"); out: glusterd_friend_sm (); glusterd_op_sm (); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } @@ -134,17 +138,19 @@ glusterd_handle_mgmt_v3_lock_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &lock_req, (xdrproc_t)xdr_gd1_mgmt_v3_lock_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, "Failed to decode lock " + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode lock " "request received from peer"); req->rpc_err = GARBAGE_ARGS; goto out; } - gf_log (this->name, GF_LOG_DEBUG, "Received mgmt_v3 lock req " + gf_msg_debug (this->name, 0, "Received mgmt_v3 lock req " "from uuid: %s", uuid_utoa (lock_req.uuid)); if (glusterd_peerinfo_find_by_uuid (lock_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (lock_req.uuid)); ret = -1; @@ -169,7 +175,8 @@ glusterd_handle_mgmt_v3_lock_fn (rpcsvc_request_t *req) ret = dict_unserialize (lock_req.dict.dict_val, lock_req.dict.dict_len, &ctx->dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } @@ -179,7 +186,8 @@ glusterd_handle_mgmt_v3_lock_fn (rpcsvc_request_t *req) if (is_synctasked) { ret = glusterd_synctasked_mgmt_v3_lock (req, &lock_req, ctx); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_LOCK_GET_FAIL, "Failed to acquire mgmt_v3_locks"); /* Ignore the return code, as it shouldn't be propagated * from the handler function so as to avoid double @@ -200,7 +208,8 @@ glusterd_handle_mgmt_v3_lock_fn (rpcsvc_request_t *req) ret = glusterd_op_state_machine_mgmt_v3_lock (req, &lock_req, ctx); if (ret) - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_LOCK_GET_FAIL, "Failed to acquire mgmt_v3_locks"); } @@ -215,7 +224,7 @@ out: free (lock_req.dict.dict_val); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } @@ -243,7 +252,8 @@ glusterd_mgmt_v3_pre_validate_send_resp (rpcsvc_request_t *req, ret = dict_allocate_and_serialize (rsp_dict, &rsp.dict.dict_val, &rsp.dict.dict_len); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_SERL_LENGTH_GET_FAIL, "failed to get serialized length of dict"); goto out; } @@ -253,7 +263,7 @@ glusterd_mgmt_v3_pre_validate_send_resp (rpcsvc_request_t *req, GF_FREE (rsp.dict.dict_val); out: - gf_log (this->name, GF_LOG_DEBUG, + gf_msg_debug (this->name, 0, "Responded to pre validation, ret: %d", ret); return ret; } @@ -275,7 +285,8 @@ glusterd_handle_pre_validate_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &op_req, (xdrproc_t)xdr_gd1_mgmt_v3_pre_val_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode pre validation " "request received from peer"); req->rpc_err = GARBAGE_ARGS; @@ -283,7 +294,8 @@ glusterd_handle_pre_validate_fn (rpcsvc_request_t *req) } if (glusterd_peerinfo_find_by_uuid (op_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (op_req.uuid)); ret = -1; @@ -297,14 +309,16 @@ glusterd_handle_pre_validate_fn (rpcsvc_request_t *req) ret = dict_unserialize (op_req.dict.dict_val, op_req.dict.dict_len, &dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } rsp_dict = dict_new (); if (!rsp_dict) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_CREATE_FAIL, "Failed to get new dictionary"); return -1; } @@ -313,7 +327,8 @@ glusterd_handle_pre_validate_fn (rpcsvc_request_t *req) rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_PRE_VALIDATION_FAIL, "Pre Validation failed on operation %s", gd_op_list[op_req.op]); } @@ -322,7 +337,8 @@ glusterd_handle_pre_validate_fn (rpcsvc_request_t *req) ret, op_errstr, rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_OP_RESP_FAIL, "Failed to send Pre Validation " "response for operation %s", gd_op_list[op_req.op]); @@ -369,7 +385,8 @@ glusterd_mgmt_v3_brick_op_send_resp (rpcsvc_request_t *req, ret = dict_allocate_and_serialize (rsp_dict, &rsp.dict.dict_val, &rsp.dict.dict_len); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_SERL_LENGTH_GET_FAIL, "failed to get serialized length of dict"); goto out; } @@ -379,7 +396,7 @@ glusterd_mgmt_v3_brick_op_send_resp (rpcsvc_request_t *req, GF_FREE (rsp.dict.dict_val); out: - gf_log (this->name, GF_LOG_DEBUG, + gf_msg_debug (this->name, 0, "Responded to brick op, ret: %d", ret); return ret; } @@ -401,14 +418,16 @@ glusterd_handle_brick_op_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &op_req, (xdrproc_t)xdr_gd1_mgmt_v3_brick_op_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, "Failed to decode brick op " + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode brick op " "request received from peer"); req->rpc_err = GARBAGE_ARGS; goto out; } if (glusterd_peerinfo_find_by_uuid (op_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (op_req.uuid)); ret = -1; @@ -422,14 +441,16 @@ glusterd_handle_brick_op_fn (rpcsvc_request_t *req) ret = dict_unserialize (op_req.dict.dict_val, op_req.dict.dict_len, &dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } rsp_dict = dict_new (); if (!rsp_dict) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_CREATE_FAIL, "Failed to get new dictionary"); return -1; } @@ -438,7 +459,8 @@ glusterd_handle_brick_op_fn (rpcsvc_request_t *req) rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_BRICK_OP_FAIL, "Brick Op failed on operation %s", gd_op_list[op_req.op]); } @@ -447,7 +469,8 @@ glusterd_handle_brick_op_fn (rpcsvc_request_t *req) ret, op_errstr, rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_PRE_VALD_RESP_FAIL, "Failed to send brick op " "response for operation %s", gd_op_list[op_req.op]); @@ -494,7 +517,8 @@ glusterd_mgmt_v3_commit_send_resp (rpcsvc_request_t *req, ret = dict_allocate_and_serialize (rsp_dict, &rsp.dict.dict_val, &rsp.dict.dict_len); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_SERL_LENGTH_GET_FAIL, "failed to get serialized length of dict"); goto out; } @@ -504,7 +528,7 @@ glusterd_mgmt_v3_commit_send_resp (rpcsvc_request_t *req, GF_FREE (rsp.dict.dict_val); out: - gf_log (this->name, GF_LOG_DEBUG, "Responded to commit, ret: %d", ret); + gf_msg_debug (this->name, 0, "Responded to commit, ret: %d", ret); return ret; } @@ -525,14 +549,16 @@ glusterd_handle_commit_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &op_req, (xdrproc_t)xdr_gd1_mgmt_v3_commit_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, "Failed to decode commit " + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode commit " "request received from peer"); req->rpc_err = GARBAGE_ARGS; goto out; } if (glusterd_peerinfo_find_by_uuid (op_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (op_req.uuid)); ret = -1; @@ -546,14 +572,16 @@ glusterd_handle_commit_fn (rpcsvc_request_t *req) ret = dict_unserialize (op_req.dict.dict_val, op_req.dict.dict_len, &dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } rsp_dict = dict_new (); if (!rsp_dict) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_CREATE_FAIL, "Failed to get new dictionary"); return -1; } @@ -562,7 +590,8 @@ glusterd_handle_commit_fn (rpcsvc_request_t *req) rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_COMMIT_OP_FAIL, "commit failed on operation %s", gd_op_list[op_req.op]); } @@ -571,7 +600,8 @@ glusterd_handle_commit_fn (rpcsvc_request_t *req) ret, op_errstr, rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_OP_RESP_FAIL, "Failed to send commit " "response for operation %s", gd_op_list[op_req.op]); @@ -618,7 +648,8 @@ glusterd_mgmt_v3_post_validate_send_resp (rpcsvc_request_t *req, ret = dict_allocate_and_serialize (rsp_dict, &rsp.dict.dict_val, &rsp.dict.dict_len); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_SERL_LENGTH_GET_FAIL, "failed to get serialized length of dict"); goto out; } @@ -628,7 +659,7 @@ glusterd_mgmt_v3_post_validate_send_resp (rpcsvc_request_t *req, GF_FREE (rsp.dict.dict_val); out: - gf_log (this->name, GF_LOG_DEBUG, + gf_msg_debug (this->name, 0, "Responded to post validation, ret: %d", ret); return ret; } @@ -650,7 +681,8 @@ glusterd_handle_post_validate_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &op_req, (xdrproc_t)xdr_gd1_mgmt_v3_post_val_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode post validation " "request received from peer"); req->rpc_err = GARBAGE_ARGS; @@ -658,7 +690,8 @@ glusterd_handle_post_validate_fn (rpcsvc_request_t *req) } if (glusterd_peerinfo_find_by_uuid (op_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (op_req.uuid)); ret = -1; @@ -672,14 +705,16 @@ glusterd_handle_post_validate_fn (rpcsvc_request_t *req) ret = dict_unserialize (op_req.dict.dict_val, op_req.dict.dict_len, &dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } rsp_dict = dict_new (); if (!rsp_dict) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_DICT_CREATE_FAIL, "Failed to get new dictionary"); return -1; } @@ -688,7 +723,8 @@ glusterd_handle_post_validate_fn (rpcsvc_request_t *req) &op_errstr, rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_POST_VALIDATION_FAIL, "Post Validation failed on operation %s", gd_op_list[op_req.op]); } @@ -697,7 +733,8 @@ glusterd_handle_post_validate_fn (rpcsvc_request_t *req) ret, op_errstr, rsp_dict); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_OP_RESP_FAIL, "Failed to send Post Validation " "response for operation %s", gd_op_list[op_req.op]); @@ -741,7 +778,7 @@ glusterd_mgmt_v3_unlock_send_resp (rpcsvc_request_t *req, int32_t status) ret = glusterd_submit_reply (req, &rsp, NULL, 0, NULL, (xdrproc_t)xdr_gd1_mgmt_v3_unlock_rsp); - gf_log (this->name, GF_LOG_DEBUG, + gf_msg_debug (this->name, 0, "Responded to mgmt_v3 unlock, ret: %d", ret); return ret; @@ -763,14 +800,15 @@ glusterd_syctasked_mgmt_v3_unlock (rpcsvc_request_t *req, /* Trying to release multiple mgmt_v3 locks */ ret = glusterd_multiple_mgmt_v3_unlock (ctx->dict, ctx->uuid); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_UNLOCK_FAIL, "Failed to release mgmt_v3 locks for %s", uuid_utoa(ctx->uuid)); } ret = glusterd_mgmt_v3_unlock_send_resp (req, ret); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } @@ -790,13 +828,14 @@ glusterd_op_state_machine_mgmt_v3_unlock (rpcsvc_request_t *req, ret = glusterd_op_sm_inject_event (GD_OP_EVENT_UNLOCK, &lock_req->txn_id, ctx); if (ret) - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_OP_EVENT_UNLOCK_FAIL, "Failed to inject event GD_OP_EVENT_UNLOCK"); glusterd_friend_sm (); glusterd_op_sm (); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } @@ -817,17 +856,19 @@ glusterd_handle_mgmt_v3_unlock_fn (rpcsvc_request_t *req) ret = xdr_to_generic (req->msg[0], &lock_req, (xdrproc_t)xdr_gd1_mgmt_v3_unlock_req); if (ret < 0) { - gf_log (this->name, GF_LOG_ERROR, "Failed to decode unlock " + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_REQ_DECODE_FAIL, "Failed to decode unlock " "request received from peer"); req->rpc_err = GARBAGE_ARGS; goto out; } - gf_log (this->name, GF_LOG_DEBUG, "Received volume unlock req " + gf_msg_debug (this->name, 0, "Received volume unlock req " "from uuid: %s", uuid_utoa (lock_req.uuid)); if (glusterd_peerinfo_find_by_uuid (lock_req.uuid) == NULL) { - gf_log (this->name, GF_LOG_WARNING, "%s doesn't " + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_PEER_NOT_FOUND, "%s doesn't " "belong to the cluster. Ignoring request.", uuid_utoa (lock_req.uuid)); ret = -1; @@ -852,7 +893,8 @@ glusterd_handle_mgmt_v3_unlock_fn (rpcsvc_request_t *req) ret = dict_unserialize (lock_req.dict.dict_val, lock_req.dict.dict_len, &ctx->dict); if (ret) { - gf_log (this->name, GF_LOG_WARNING, + gf_msg (this->name, GF_LOG_WARNING, 0, + GD_MSG_DICT_UNSERIALIZE_FAIL, "failed to unserialize the dictionary"); goto out; } @@ -862,7 +904,8 @@ glusterd_handle_mgmt_v3_unlock_fn (rpcsvc_request_t *req) if (is_synctasked) { ret = glusterd_syctasked_mgmt_v3_unlock (req, &lock_req, ctx); if (ret) { - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_UNLOCK_FAIL, "Failed to release mgmt_v3_locks"); /* Ignore the return code, as it shouldn't be propagated * from the handler function so as to avoid double @@ -883,7 +926,8 @@ glusterd_handle_mgmt_v3_unlock_fn (rpcsvc_request_t *req) ret = glusterd_op_state_machine_mgmt_v3_unlock (req, &lock_req, ctx); if (ret) - gf_log (this->name, GF_LOG_ERROR, + gf_msg (this->name, GF_LOG_ERROR, 0, + GD_MSG_MGMTV3_UNLOCK_FAIL, "Failed to release mgmt_v3_locks"); } @@ -898,7 +942,7 @@ out: free (lock_req.dict.dict_val); - gf_log (this->name, GF_LOG_TRACE, "Returning %d", ret); + gf_msg_trace (this->name, 0, "Returning %d", ret); return ret; } |