summaryrefslogtreecommitdiffstats
path: root/xlators/features
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/features')
-rw-r--r--xlators/features/bit-rot/src/bitd/bit-rot-bitd-messages.h490
-rw-r--r--xlators/features/bit-rot/src/stub/bit-rot-stub-messages.h297
-rw-r--r--xlators/features/changelog/lib/src/changelog-lib-messages.h317
-rw-r--r--xlators/features/changelog/src/changelog-messages.h497
-rw-r--r--xlators/features/changetimerecorder/src/ctr-messages.h562
-rw-r--r--xlators/features/index/src/index-messages.h126
-rw-r--r--xlators/features/leases/src/leases-messages.h135
-rw-r--r--xlators/features/locks/src/pl-messages.h56
-rw-r--r--xlators/features/quota/src/quota-messages.h262
-rw-r--r--xlators/features/selinux/src/selinux-messages.h89
-rw-r--r--xlators/features/shard/src/shard-messages.h197
-rw-r--r--xlators/features/upcall/src/upcall-messages.h53
12 files changed, 433 insertions, 2648 deletions
diff --git a/xlators/features/bit-rot/src/bitd/bit-rot-bitd-messages.h b/xlators/features/bit-rot/src/bitd/bit-rot-bitd-messages.h
index c6b6a4afa05..89a67cc10b1 100644
--- a/xlators/features/bit-rot/src/bitd/bit-rot-bitd-messages.h
+++ b/xlators/features/bit-rot/src/bitd/bit-rot-bitd-messages.h
@@ -13,436 +13,72 @@
#include "glfs-message-id.h"
-/* file bit-rot-bitd-messages.h
- * brief BIT-ROT log-message IDs and their descriptions
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_BITROT_BITD_BASE GLFS_MSGID_COMP_BITROT_BITD
-#define GLFS_BITROT_BITD_NUM_MESSAGES 55
-#define GLFS_MSGID_END (GLFS_BITROT_BITD_BASE + \
- GLFS_BITROT_BITD_NUM_MESSAGES + 1)
-/* Messaged with message IDs */
-#define glfs_msg_start_x GLFS_BITROT_BITD_BASE, "Invalid: Start of messages"
-/*------------*/
-
-
-#define BRB_MSG_FD_CREATE_FAILED (GLFS_BITROT_BITD_BASE + 1)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-
-#define BRB_MSG_READV_FAILED (GLFS_BITROT_BITD_BASE + 2)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-
-#define BRB_MSG_BLOCK_READ_FAILED (GLFS_BITROT_BITD_BASE + 3)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CALC_CHECKSUM_FAILED (GLFS_BITROT_BITD_BASE + 4)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_NO_MEMORY (GLFS_BITROT_BITD_BASE + 5)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_GET_SIGN_FAILED (GLFS_BITROT_BITD_BASE + 6)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SET_SIGN_FAILED (GLFS_BITROT_BITD_BASE + 7)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_OP_FAILED (GLFS_BITROT_BITD_BASE + 8)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_READ_AND_SIGN_FAILED (GLFS_BITROT_BITD_BASE + 9)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SIGN_FAILED (GLFS_BITROT_BITD_BASE + 10)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_GET_SUBVOL_FAILED (GLFS_BITROT_BITD_BASE + 11)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SET_TIMER_FAILED (GLFS_BITROT_BITD_BASE + 12)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_GET_INFO_FAILED (GLFS_BITROT_BITD_BASE + 13)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_PATH_FAILED (GLFS_BITROT_BITD_BASE + 14)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_MARK_BAD_FILE (GLFS_BITROT_BITD_BASE + 15)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_TRIGGER_SIGN (GLFS_BITROT_BITD_BASE + 16)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_REGISTER_FAILED (GLFS_BITROT_BITD_BASE + 17)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CRAWLING_START (GLFS_BITROT_BITD_BASE + 18)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SPAWN_FAILED (GLFS_BITROT_BITD_BASE + 19)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_INVALID_SUBVOL_CHILD (GLFS_BITROT_BITD_BASE + 20)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SKIP_OBJECT (GLFS_BITROT_BITD_BASE + 21)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_NO_CHILD (GLFS_BITROT_BITD_BASE + 22)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CHECKSUM_MISMATCH (GLFS_BITROT_BITD_BASE + 23)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_MARK_CORRUPTED (GLFS_BITROT_BITD_BASE + 24)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CRAWLING_FINISH (GLFS_BITROT_BITD_BASE + 25)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CALC_ERROR (GLFS_BITROT_BITD_BASE + 26)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_LOOKUP_FAILED (GLFS_BITROT_BITD_BASE + 27)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_PARTIAL_VERSION_PRESENCE (GLFS_BITROT_BITD_BASE + 28)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_MEM_ACNT_FAILED (GLFS_BITROT_BITD_BASE + 29)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_TIMER_WHEEL_UNAVAILABLE (GLFS_BITROT_BITD_BASE + 30)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_BITROT_LOADED (GLFS_BITROT_BITD_BASE + 31)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCALE_DOWN_FAILED (GLFS_BITROT_BITD_BASE + 32)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCALE_UP_FAILED (GLFS_BITROT_BITD_BASE + 33)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
+/* To add new message IDs, append new identifiers at the end of the list.
*
- */
-#define BRB_MSG_SCALE_DOWN_SCRUBBER (GLFS_BITROT_BITD_BASE + 34)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCALING_UP_SCRUBBER (GLFS_BITROT_BITD_BASE + 35)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define BRB_MSG_UNKNOWN_THROTTLE (GLFS_BITROT_BITD_BASE + 36)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_RATE_LIMIT_INFO (GLFS_BITROT_BITD_BASE + 37)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCRUB_INFO (GLFS_BITROT_BITD_BASE + 38)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_CONNECTED_TO_BRICK (GLFS_BITROT_BITD_BASE + 39)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_BRICK_INFO (GLFS_BITROT_BITD_BASE + 40)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SUBVOL_CONNECT_FAILED (GLFS_BITROT_BITD_BASE + 41)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_INVALID_SUBVOL (GLFS_BITROT_BITD_BASE + 42)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_RESCHEDULE_SCRUBBER_FAILED (GLFS_BITROT_BITD_BASE + 43)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
*
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-#define BRB_MSG_SCRUB_START (GLFS_BITROT_BITD_BASE + 44)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCRUB_FINISH (GLFS_BITROT_BITD_BASE + 45)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCRUB_RUNNING (GLFS_BITROT_BITD_BASE + 46)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCRUB_RESCHEDULED (GLFS_BITROT_BITD_BASE + 47)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRB_MSG_SCRUB_TUNABLE (GLFS_BITROT_BITD_BASE + 48)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_SCRUB_THREAD_CLEANUP (GLFS_BITROT_BITD_BASE + 49)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_SCRUBBER_CLEANED (GLFS_BITROT_BITD_BASE + 50)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_GENERIC_SSM_INFO (GLFS_BITROT_BITD_BASE + 51)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_ZERO_TIMEOUT_BUG (GLFS_BITROT_BITD_BASE + 52)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_BAD_OBJ_READDIR_FAIL (GLFS_BITROT_BITD_BASE + 53)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_SSM_FAILED (GLFS_BITROT_BITD_BASE + 54)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
-#define BRB_MSG_SCRUB_WAIT_FAILED (GLFS_BITROT_BITD_BASE + 55)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
+GLFS_MSGID(BITROT_BITD,
+ BRB_MSG_FD_CREATE_FAILED,
+ BRB_MSG_READV_FAILED,
+ BRB_MSG_BLOCK_READ_FAILED,
+ BRB_MSG_CALC_CHECKSUM_FAILED,
+ BRB_MSG_NO_MEMORY,
+ BRB_MSG_GET_SIGN_FAILED,
+ BRB_MSG_SET_SIGN_FAILED,
+ BRB_MSG_OP_FAILED,
+ BRB_MSG_READ_AND_SIGN_FAILED,
+ BRB_MSG_SIGN_FAILED,
+ BRB_MSG_GET_SUBVOL_FAILED,
+ BRB_MSG_SET_TIMER_FAILED,
+ BRB_MSG_GET_INFO_FAILED,
+ BRB_MSG_PATH_FAILED,
+ BRB_MSG_MARK_BAD_FILE,
+ BRB_MSG_TRIGGER_SIGN,
+ BRB_MSG_REGISTER_FAILED,
+ BRB_MSG_CRAWLING_START,
+ BRB_MSG_SPAWN_FAILED,
+ BRB_MSG_INVALID_SUBVOL_CHILD,
+ BRB_MSG_SKIP_OBJECT,
+ BRB_MSG_NO_CHILD,
+ BRB_MSG_CHECKSUM_MISMATCH,
+ BRB_MSG_MARK_CORRUPTED,
+ BRB_MSG_CRAWLING_FINISH,
+ BRB_MSG_CALC_ERROR,
+ BRB_MSG_LOOKUP_FAILED,
+ BRB_MSG_PARTIAL_VERSION_PRESENCE,
+ BRB_MSG_MEM_ACNT_FAILED,
+ BRB_MSG_TIMER_WHEEL_UNAVAILABLE,
+ BRB_MSG_BITROT_LOADED,
+ BRB_MSG_SCALE_DOWN_FAILED,
+ BRB_MSG_SCALE_UP_FAILED,
+ BRB_MSG_SCALE_DOWN_SCRUBBER,
+ BRB_MSG_SCALING_UP_SCRUBBER,
+ BRB_MSG_UNKNOWN_THROTTLE,
+ BRB_MSG_RATE_LIMIT_INFO,
+ BRB_MSG_SCRUB_INFO,
+ BRB_MSG_CONNECTED_TO_BRICK,
+ BRB_MSG_BRICK_INFO,
+ BRB_MSG_SUBVOL_CONNECT_FAILED,
+ BRB_MSG_INVALID_SUBVOL,
+ BRB_MSG_RESCHEDULE_SCRUBBER_FAILED,
+ BRB_MSG_SCRUB_START,
+ BRB_MSG_SCRUB_FINISH,
+ BRB_MSG_SCRUB_RUNNING,
+ BRB_MSG_SCRUB_RESCHEDULED,
+ BRB_MSG_SCRUB_TUNABLE,
+ BRB_MSG_SCRUB_THREAD_CLEANUP,
+ BRB_MSG_SCRUBBER_CLEANED,
+ BRB_MSG_GENERIC_SSM_INFO,
+ BRB_MSG_ZERO_TIMEOUT_BUG,
+ BRB_MSG_BAD_OBJ_READDIR_FAIL,
+ BRB_MSG_SSM_FAILED,
+ BRB_MSG_SCRUB_WAIT_FAILED
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_BITROT_BITD_MESSAGES_H_ */
diff --git a/xlators/features/bit-rot/src/stub/bit-rot-stub-messages.h b/xlators/features/bit-rot/src/stub/bit-rot-stub-messages.h
index c0fcfd324a5..42022adb116 100644
--- a/xlators/features/bit-rot/src/stub/bit-rot-stub-messages.h
+++ b/xlators/features/bit-rot/src/stub/bit-rot-stub-messages.h
@@ -13,259 +13,48 @@
#include "glfs-message-id.h"
-/* file bit-rot-stub-messages.h
- * brief BIT-ROT log-message IDs and their descriptions
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_BITROT_STUB_BASE GLFS_MSGID_COMP_BITROT_STUB
-#define GLFS_BITROT_STUB_NUM_MESSAGES 31
-#define GLFS_MSGID_END (GLFS_BITROT_STUB_BASE + \
- GLFS_BITROT_STUB_NUM_MESSAGES + 1)
-/* Messaged with message IDs */
-#define glfs_msg_start_x GLFS_BITROT_STUB_BASE, "Invalid: Start of messages"
-/*------------*/
-
-
-#define BRS_MSG_NO_MEMORY (GLFS_BITROT_STUB_BASE + 1)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_SET_EVENT_FAILED (GLFS_BITROT_STUB_BASE + 2)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_MEM_ACNT_FAILED (GLFS_BITROT_STUB_BASE + 3)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_CREATE_FRAME_FAILED (GLFS_BITROT_STUB_BASE + 4)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_SET_CONTEXT_FAILED (GLFS_BITROT_STUB_BASE + 5)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_CHANGE_VERSION_FAILED (GLFS_BITROT_STUB_BASE + 6)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_ADD_FD_TO_LIST_FAILED (GLFS_BITROT_STUB_BASE + 7)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_SET_FD_CONTEXT_FAILED (GLFS_BITROT_STUB_BASE + 8)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_CREATE_ANONYMOUS_FD_FAILED (GLFS_BITROT_STUB_BASE + 9)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_NO_CHILD (GLFS_BITROT_STUB_BASE + 10)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_STUB_ALLOC_FAILED (GLFS_BITROT_STUB_BASE + 11)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_GET_INODE_CONTEXT_FAILED (GLFS_BITROT_STUB_BASE + 12)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_CANCEL_SIGN_THREAD_FAILED (GLFS_BITROT_STUB_BASE + 13)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_ADD_FD_TO_INODE (GLFS_BITROT_STUB_BASE + 14)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_SIGN_VERSION_ERROR (GLFS_BITROT_STUB_BASE + 15)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJ_MARK_FAIL (GLFS_BITROT_STUB_BASE + 16)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_NON_SCRUB_BAD_OBJ_MARK (GLFS_BITROT_STUB_BASE + 17)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_REMOVE_INTERNAL_XATTR (GLFS_BITROT_STUB_BASE + 18)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_SET_INTERNAL_XATTR (GLFS_BITROT_STUB_BASE + 19)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJECT_ACCESS (GLFS_BITROT_STUB_BASE + 20)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_CONTAINER_FAIL (GLFS_BITROT_STUB_BASE + 21)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJECT_DIR_FAIL (GLFS_BITROT_STUB_BASE + 22)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJECT_DIR_SEEK_FAIL (GLFS_BITROT_STUB_BASE + 23)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJECT_DIR_TELL_FAIL (GLFS_BITROT_STUB_BASE + 24)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJECT_DIR_READ_FAIL (GLFS_BITROT_STUB_BASE + 25)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_GET_FD_CONTEXT_FAILED (GLFS_BITROT_STUB_BASE + 26)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_HANDLE_DIR_NULL (GLFS_BITROT_STUB_BASE + 27)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJ_THREAD_FAIL (GLFS_BITROT_STUB_BASE + 28)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJ_DIR_CLOSE_FAIL (GLFS_BITROT_STUB_BASE + 29)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_LINK_FAIL (GLFS_BITROT_STUB_BASE + 30)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define BRS_MSG_BAD_OBJ_UNLINK_FAIL (GLFS_BITROT_STUB_BASE + 31)
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-/*------------*/
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(BITROT_STUB,
+ BRS_MSG_NO_MEMORY,
+ BRS_MSG_SET_EVENT_FAILED,
+ BRS_MSG_MEM_ACNT_FAILED,
+ BRS_MSG_CREATE_FRAME_FAILED,
+ BRS_MSG_SET_CONTEXT_FAILED,
+ BRS_MSG_CHANGE_VERSION_FAILED,
+ BRS_MSG_ADD_FD_TO_LIST_FAILED,
+ BRS_MSG_SET_FD_CONTEXT_FAILED,
+ BRS_MSG_CREATE_ANONYMOUS_FD_FAILED,
+ BRS_MSG_NO_CHILD,
+ BRS_MSG_STUB_ALLOC_FAILED,
+ BRS_MSG_GET_INODE_CONTEXT_FAILED,
+ BRS_MSG_CANCEL_SIGN_THREAD_FAILED,
+ BRS_MSG_ADD_FD_TO_INODE,
+ BRS_MSG_SIGN_VERSION_ERROR,
+ BRS_MSG_BAD_OBJ_MARK_FAIL,
+ BRS_MSG_NON_SCRUB_BAD_OBJ_MARK,
+ BRS_MSG_REMOVE_INTERNAL_XATTR,
+ BRS_MSG_SET_INTERNAL_XATTR,
+ BRS_MSG_BAD_OBJECT_ACCESS,
+ BRS_MSG_BAD_CONTAINER_FAIL,
+ BRS_MSG_BAD_OBJECT_DIR_FAIL,
+ BRS_MSG_BAD_OBJECT_DIR_SEEK_FAIL,
+ BRS_MSG_BAD_OBJECT_DIR_TELL_FAIL,
+ BRS_MSG_BAD_OBJECT_DIR_READ_FAIL,
+ BRS_MSG_GET_FD_CONTEXT_FAILED,
+ BRS_MSG_BAD_HANDLE_DIR_NULL,
+ BRS_MSG_BAD_OBJ_THREAD_FAIL,
+ BRS_MSG_BAD_OBJ_DIR_CLOSE_FAIL,
+ BRS_MSG_LINK_FAIL,
+ BRS_MSG_BAD_OBJ_UNLINK_FAIL
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_BITROT_STUB_MESSAGES_H_ */
diff --git a/xlators/features/changelog/lib/src/changelog-lib-messages.h b/xlators/features/changelog/lib/src/changelog-lib-messages.h
index a6209af71ee..2061217b801 100644
--- a/xlators/features/changelog/lib/src/changelog-lib-messages.h
+++ b/xlators/features/changelog/lib/src/changelog-lib-messages.h
@@ -11,284 +11,51 @@
#ifndef _CHANGELOG_LIB_MESSAGES_H_
#define _CHANGELOG_LIB_MESSAGES_H_
-#ifndef _CONFIG_H
-#define _CONFIG_H
-#include "config.h"
-#endif
-
#include "glfs-message-id.h"
-/*! \file changelog-lib-messages.h
- * \brief CHANGELOG_LIB log-message IDs and their descriptions.
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for readability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE_CHANGELOG_LIB GLFS_MSGID_COMP_CHANGELOG_LIB
-#define GLFS_NUM_MESSAGES 32
-#define GLFS_MSGID_END (GLFS_COMP_BASE_CHANGELOG_LIB + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x GLFS_COMP_BASE_CHANGELOG_LIB,\
- "Invalid: Start of messages"
-
-/*!
- * @messageid
- * @diagnosis open/opendir failed on a brick.
- * @recommended action Error number in the log should give the reason why it
- * failed. Also observe brick logs for more information.
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-#define CHANGELOG_LIB_MSG_OPEN_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 1)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_FAILED_TO_RMDIR (GLFS_COMP_BASE_CHANGELOG_LIB + 2)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_SCRATCH_DIR_ENTRIES_CREATION_ERROR \
-(GLFS_COMP_BASE_CHANGELOG_LIB + 3)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_THREAD_CREATION_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 4)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_OPENDIR_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 5)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_RENAME_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 6)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_READ_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 7)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_HTIME_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 8)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_GET_TIME_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 9)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_WRITE_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 10)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_PTHREAD_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 11)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_MMAP_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 12)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_MUNMAP_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 13)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_ASCII_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 14)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_STAT_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 15)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_GET_XATTR_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 16)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_PUBLISH_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 17)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_PARSE_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 18)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_TOTAL_LOG_INFO (GLFS_COMP_BASE_CHANGELOG_LIB + 19)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_CLEANUP_ERROR (GLFS_COMP_BASE_CHANGELOG_LIB + 20)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_UNLINK_FAILED (GLFS_COMP_BASE_CHANGELOG_LIB + 21)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_NOTIFY_REGISTER_FAILED\
- (GLFS_COMP_BASE_CHANGELOG_LIB + 22)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_INVOKE_RPC_FAILED\
- (GLFS_COMP_BASE_CHANGELOG_LIB + 23)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_DRAINING_EVENT_INFO\
- (GLFS_COMP_BASE_CHANGELOG_LIB + 24)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_CLEANING_BRICK_ENTRY_INFO \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 25)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_FREEING_ENTRY_INFO \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 26)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_XDR_DECODING_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 27)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_NOTIFY_REGISTER_INFO \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 28)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_THREAD_CLEANUP_WARNING \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 29)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_COPY_FROM_BUFFER_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 30)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_PTHREAD_JOIN_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 31)
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_LIB_MSG_HIST_FAILED \
- (GLFS_COMP_BASE_CHANGELOG_LIB + 32)
+GLFS_MSGID(CHANGELOG_LIB,
+ CHANGELOG_LIB_MSG_OPEN_FAILED,
+ CHANGELOG_LIB_MSG_FAILED_TO_RMDIR,
+ CHANGELOG_LIB_MSG_SCRATCH_DIR_ENTRIES_CREATION_ERROR,
+ CHANGELOG_LIB_MSG_THREAD_CREATION_FAILED,
+ CHANGELOG_LIB_MSG_OPENDIR_ERROR,
+ CHANGELOG_LIB_MSG_RENAME_FAILED,
+ CHANGELOG_LIB_MSG_READ_ERROR,
+ CHANGELOG_LIB_MSG_HTIME_ERROR,
+ CHANGELOG_LIB_MSG_GET_TIME_ERROR,
+ CHANGELOG_LIB_MSG_WRITE_FAILED,
+ CHANGELOG_LIB_MSG_PTHREAD_ERROR,
+ CHANGELOG_LIB_MSG_MMAP_FAILED,
+ CHANGELOG_LIB_MSG_MUNMAP_FAILED,
+ CHANGELOG_LIB_MSG_ASCII_ERROR,
+ CHANGELOG_LIB_MSG_STAT_FAILED,
+ CHANGELOG_LIB_MSG_GET_XATTR_FAILED,
+ CHANGELOG_LIB_MSG_PUBLISH_ERROR,
+ CHANGELOG_LIB_MSG_PARSE_ERROR,
+ CHANGELOG_LIB_MSG_TOTAL_LOG_INFO,
+ CHANGELOG_LIB_MSG_CLEANUP_ERROR,
+ CHANGELOG_LIB_MSG_UNLINK_FAILED,
+ CHANGELOG_LIB_MSG_NOTIFY_REGISTER_FAILED,
+ CHANGELOG_LIB_MSG_INVOKE_RPC_FAILED,
+ CHANGELOG_LIB_MSG_DRAINING_EVENT_INFO,
+ CHANGELOG_LIB_MSG_CLEANING_BRICK_ENTRY_INFO,
+ CHANGELOG_LIB_MSG_FREEING_ENTRY_INFO,
+ CHANGELOG_LIB_MSG_XDR_DECODING_FAILED,
+ CHANGELOG_LIB_MSG_NOTIFY_REGISTER_INFO,
+ CHANGELOG_LIB_MSG_THREAD_CLEANUP_WARNING,
+ CHANGELOG_LIB_MSG_COPY_FROM_BUFFER_FAILED,
+ CHANGELOG_LIB_MSG_PTHREAD_JOIN_FAILED,
+ CHANGELOG_LIB_MSG_HIST_FAILED
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_CHANGELOG_MESSAGES_H_ */
diff --git a/xlators/features/changelog/src/changelog-messages.h b/xlators/features/changelog/src/changelog-messages.h
index e65a457b7c0..bbef2f2bde5 100644
--- a/xlators/features/changelog/src/changelog-messages.h
+++ b/xlators/features/changelog/src/changelog-messages.h
@@ -11,440 +11,75 @@
#ifndef _CHANGELOG_MESSAGES_H_
#define _CHANGELOG_MESSAGES_H_
-#ifndef _CONFIG_H
-#define _CONFIG_H
-#include "config.h"
-#endif
-
#include "glfs-message-id.h"
-/*! \file changelog-messages.h
- * \brief CHANGELOG log-message IDs and their descriptions.
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for readability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE_CHANGELOG GLFS_MSGID_COMP_CHANGELOG
-#define GLFS_NUM_MESSAGES 54
-#define GLFS_MSGID_END (GLFS_COMP_BASE_CHANGELOG + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x GLFS_COMP_BASE_CHANGELOG, "Invalid: Start of messages"
-
-/*!
- * @messageid
- * @diagnosis open/opendir failed on a brick.
- * @recommended action Error number in the log should give the reason why it
- * failed. Also observe brick logs for more information.
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-#define CHANGELOG_MSG_OPEN_FAILED (GLFS_COMP_BASE_CHANGELOG + 1)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_NO_MEMORY (GLFS_COMP_BASE_CHANGELOG + 2)
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_VOL_MISCONFIGURED (GLFS_COMP_BASE_CHANGELOG + 3)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_RENAME_ERROR (GLFS_COMP_BASE_CHANGELOG + 4)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_READ_ERROR (GLFS_COMP_BASE_CHANGELOG + 5)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_HTIME_ERROR (GLFS_COMP_BASE_CHANGELOG + 6)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PTHREAD_MUTEX_INIT_FAILED (GLFS_COMP_BASE_CHANGELOG + 7)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PTHREAD_COND_INIT_FAILED (GLFS_COMP_BASE_CHANGELOG + 8)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_CHILD_MISCONFIGURED (GLFS_COMP_BASE_CHANGELOG + 9)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_DIR_OPTIONS_NOT_SET (GLFS_COMP_BASE_CHANGELOG + 10)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_CLOSE_ERROR (GLFS_COMP_BASE_CHANGELOG + 11)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PIPE_CREATION_ERROR (GLFS_COMP_BASE_CHANGELOG + 12)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_DICT_GET_FAILED (GLFS_COMP_BASE_CHANGELOG + 13)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_BARRIER_INFO (GLFS_COMP_BASE_CHANGELOG + 14)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_BARRIER_ERROR (GLFS_COMP_BASE_CHANGELOG + 15)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_GET_TIME_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 16)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_WRITE_FAILED (GLFS_COMP_BASE_CHANGELOG + 17)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PTHREAD_ERROR (GLFS_COMP_BASE_CHANGELOG + 18)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_INODE_NOT_FOUND (GLFS_COMP_BASE_CHANGELOG + 19)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FSYNC_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 20)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_TOTAL_LOG_INFO (GLFS_COMP_BASE_CHANGELOG + 21)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_SNAP_INFO (GLFS_COMP_BASE_CHANGELOG + 22)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_SELECT_FAILED (GLFS_COMP_BASE_CHANGELOG + 23)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FCNTL_FAILED (GLFS_COMP_BASE_CHANGELOG + 24)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_BNOTIFY_INFO (GLFS_COMP_BASE_CHANGELOG + 25)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_ENTRY_BUF_INFO (GLFS_COMP_BASE_CHANGELOG + 26)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_NOT_ACTIVE (GLFS_COMP_BASE_CHANGELOG + 27)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_LOCAL_INIT_FAILED (GLFS_COMP_BASE_CHANGELOG + 28)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_NOTIFY_REGISTER_FAILED (GLFS_COMP_BASE_CHANGELOG + 28)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PROGRAM_NAME_REG_FAILED (GLFS_COMP_BASE_CHANGELOG + 29)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_HANDLE_PROBE_ERROR (GLFS_COMP_BASE_CHANGELOG + 30)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_SET_FD_CONTEXT (GLFS_COMP_BASE_CHANGELOG + 31)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FREEUP_FAILED (GLFS_COMP_BASE_CHANGELOG + 32)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_HTIME_INFO (GLFS_COMP_BASE_CHANGELOG + 33)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_RPC_SUBMIT_REPLY_FAILED (GLFS_COMP_BASE_CHANGELOG + 34)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_RPC_BUILD_ERROR (GLFS_COMP_BASE_CHANGELOG + 35)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_RPC_CONNECT_ERROR (GLFS_COMP_BASE_CHANGELOG + 36)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_RPC_START_ERROR (GLFS_COMP_BASE_CHANGELOG + 37)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_BUFFER_STARVATION_ERROR (GLFS_COMP_BASE_CHANGELOG + 3)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_SCAN_DIR_FAILED (GLFS_COMP_BASE_CHANGELOG + 39)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FSETXATTR_FAILED (GLFS_COMP_BASE_CHANGELOG + 40)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FGETXATTR_FAILED (GLFS_COMP_BASE_CHANGELOG + 41)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_CLEANUP_ON_ACTIVE_REF \
- (GLFS_COMP_BASE_CHANGELOG + 42)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_DISPATCH_EVENT_FAILED (GLFS_COMP_BASE_CHANGELOG + 43)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PUT_BUFFER_FAILED (GLFS_COMP_BASE_CHANGELOG + 44)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PTHREAD_COND_WAIT_FAILED (GLFS_COMP_BASE_CHANGELOG + 45)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_PTHREAD_CANCEL_FAILED (GLFS_COMP_BASE_CHANGELOG + 46)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_INJECT_FSYNC_FAILED (GLFS_COMP_BASE_CHANGELOG + 47)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_CREATE_FRAME_FAILED (GLFS_COMP_BASE_CHANGELOG + 48)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_FSTAT_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 49)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_LSEEK_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 50)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_STRSTR_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 51)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_UNLINK_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 52)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_DETECT_EMPTY_CHANGELOG_FAILED \
- (GLFS_COMP_BASE_CHANGELOG + 53)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_READLINK_OP_FAILED (GLFS_COMP_BASE_CHANGELOG + 54)
-
-/*!
- @messageid
- * @diagnosis
- * @recommended action
-*/
-#define CHANGELOG_MSG_EXPLICIT_ROLLOVER_FAILED (GLFS_COMP_BASE_CHANGELOG + 55)
-
+GLFS_MSGID(CHANGELOG,
+ CHANGELOG_MSG_OPEN_FAILED,
+ CHANGELOG_MSG_NO_MEMORY,
+ CHANGELOG_MSG_VOL_MISCONFIGURED,
+ CHANGELOG_MSG_RENAME_ERROR,
+ CHANGELOG_MSG_READ_ERROR,
+ CHANGELOG_MSG_HTIME_ERROR,
+ CHANGELOG_MSG_PTHREAD_MUTEX_INIT_FAILED,
+ CHANGELOG_MSG_PTHREAD_COND_INIT_FAILED,
+ CHANGELOG_MSG_CHILD_MISCONFIGURED,
+ CHANGELOG_MSG_DIR_OPTIONS_NOT_SET,
+ CHANGELOG_MSG_CLOSE_ERROR,
+ CHANGELOG_MSG_PIPE_CREATION_ERROR,
+ CHANGELOG_MSG_DICT_GET_FAILED,
+ CHANGELOG_MSG_BARRIER_INFO,
+ CHANGELOG_MSG_BARRIER_ERROR,
+ CHANGELOG_MSG_GET_TIME_OP_FAILED,
+ CHANGELOG_MSG_WRITE_FAILED,
+ CHANGELOG_MSG_PTHREAD_ERROR,
+ CHANGELOG_MSG_INODE_NOT_FOUND,
+ CHANGELOG_MSG_FSYNC_OP_FAILED,
+ CHANGELOG_MSG_TOTAL_LOG_INFO,
+ CHANGELOG_MSG_SNAP_INFO,
+ CHANGELOG_MSG_SELECT_FAILED,
+ CHANGELOG_MSG_FCNTL_FAILED,
+ CHANGELOG_MSG_BNOTIFY_INFO,
+ CHANGELOG_MSG_ENTRY_BUF_INFO,
+ CHANGELOG_MSG_NOT_ACTIVE,
+ CHANGELOG_MSG_LOCAL_INIT_FAILED,
+ CHANGELOG_MSG_NOTIFY_REGISTER_FAILED,
+ CHANGELOG_MSG_PROGRAM_NAME_REG_FAILED,
+ CHANGELOG_MSG_HANDLE_PROBE_ERROR,
+ CHANGELOG_MSG_SET_FD_CONTEXT,
+ CHANGELOG_MSG_FREEUP_FAILED,
+ CHANGELOG_MSG_HTIME_INFO,
+ CHANGELOG_MSG_RPC_SUBMIT_REPLY_FAILED,
+ CHANGELOG_MSG_RPC_BUILD_ERROR,
+ CHANGELOG_MSG_RPC_CONNECT_ERROR,
+ CHANGELOG_MSG_RPC_START_ERROR,
+ CHANGELOG_MSG_BUFFER_STARVATION_ERROR,
+ CHANGELOG_MSG_SCAN_DIR_FAILED,
+ CHANGELOG_MSG_FSETXATTR_FAILED,
+ CHANGELOG_MSG_FGETXATTR_FAILED,
+ CHANGELOG_MSG_CLEANUP_ON_ACTIVE_REF,
+ CHANGELOG_MSG_DISPATCH_EVENT_FAILED,
+ CHANGELOG_MSG_PUT_BUFFER_FAILED,
+ CHANGELOG_MSG_PTHREAD_COND_WAIT_FAILED,
+ CHANGELOG_MSG_PTHREAD_CANCEL_FAILED,
+ CHANGELOG_MSG_INJECT_FSYNC_FAILED,
+ CHANGELOG_MSG_CREATE_FRAME_FAILED,
+ CHANGELOG_MSG_FSTAT_OP_FAILED,
+ CHANGELOG_MSG_LSEEK_OP_FAILED,
+ CHANGELOG_MSG_STRSTR_OP_FAILED,
+ CHANGELOG_MSG_UNLINK_OP_FAILED,
+ CHANGELOG_MSG_DETECT_EMPTY_CHANGELOG_FAILED,
+ CHANGELOG_MSG_READLINK_OP_FAILED,
+ CHANGELOG_MSG_EXPLICIT_ROLLOVER_FAILED
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_CHANGELOG_MESSAGES_H_ */
diff --git a/xlators/features/changetimerecorder/src/ctr-messages.h b/xlators/features/changetimerecorder/src/ctr-messages.h
index 25532145fe8..bc9a9e0f3ab 100644
--- a/xlators/features/changetimerecorder/src/ctr-messages.h
+++ b/xlators/features/changetimerecorder/src/ctr-messages.h
@@ -8,495 +8,79 @@
cases as published by the Free Software Foundation.
*/
-#ifndef _component_MESSAGES_H_
-#define _component_MESSAGES_H_
-
-#ifndef _CONFIG_H
-#define _CONFIG_H
-#include "config.h"
-#endif
+#ifndef _CTR_MESSAGES_H_
+#define _CTR_MESSAGES_H_
#include "glfs-message-id.h"
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE GLFS_MSGID_COMP_CTR
-#define GLFS_NUM_MESSAGES 57
-#define GLFS_MSGID_END (GLFS_COMP_BASE + GLFS_NUM_MESSAGES + 1)
-/* Messaged with message IDs */
-#define glfs_msg_start_x GLFS_COMP_BASE, "Invalid: Start of messages"
-/*------------*/
-
-#define CTR_MSG_CREATE_CTR_LOCAL_ERROR_WIND (GLFS_COMP_BASE + 1)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_FILL_CTR_LOCAL_ERROR_UNWIND (GLFS_COMP_BASE + 2)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_FILL_CTR_LOCAL_ERROR_WIND (GLFS_COMP_BASE + 3)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_LINK_WIND_FAILED (GLFS_COMP_BASE + 4)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_WRITEV_WIND_FAILED (GLFS_COMP_BASE + 5)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_WRITEV_UNWIND_FAILED (GLFS_COMP_BASE + 6)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_SETATTR_WIND_FAILED (GLFS_COMP_BASE + 7)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_SETATTR_UNWIND_FAILED (GLFS_COMP_BASE + 8)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FREMOVEXATTR_UNWIND_FAILED (GLFS_COMP_BASE + 9)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FREMOVEXATTR_WIND_FAILED (GLFS_COMP_BASE + 10)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_REMOVEXATTR_WIND_FAILED (GLFS_COMP_BASE + 11)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_REMOVEXATTR_UNWIND_FAILED (GLFS_COMP_BASE + 12)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_TRUNCATE_WIND_FAILED (GLFS_COMP_BASE + 13)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_TRUNCATE_UNWIND_FAILED (GLFS_COMP_BASE + 14)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FTRUNCATE_UNWIND_FAILED (GLFS_COMP_BASE + 15)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FTRUNCATE_WIND_FAILED (GLFS_COMP_BASE + 16)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_RENAME_WIND_FAILED (GLFS_COMP_BASE + 17)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_RENAME_UNWIND_FAILED (GLFS_COMP_BASE + 18)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_ACCESS_CTR_INODE_CONTEXT_FAILED (GLFS_COMP_BASE + 19)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_ADD_HARDLINK_FAILED (GLFS_COMP_BASE + 20)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_DELETE_HARDLINK_FAILED (GLFS_COMP_BASE + 21)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_UPDATE_HARDLINK_FAILED (GLFS_COMP_BASE + 22)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_GET_CTR_RESPONSE_LINK_COUNT_XDATA_FAILED (GLFS_COMP_BASE + 23)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_SET_CTR_RESPONSE_LINK_COUNT_XDATA_FAILED (GLFS_COMP_BASE + 24)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_UNLINK_UNWIND_FAILED (GLFS_COMP_BASE + 25)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_UNLINK_WIND_FAILED (GLFS_COMP_BASE + 26)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_XDATA_NULL (GLFS_COMP_BASE + 27)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FSYNC_WIND_FAILED (GLFS_COMP_BASE + 28)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_FSYNC_UNWIND_FAILED (GLFS_COMP_BASE + 29)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_MKNOD_UNWIND_FAILED (GLFS_COMP_BASE + 30)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_MKNOD_WIND_FAILED (GLFS_COMP_BASE + 31)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_CREATE_WIND_FAILED (GLFS_COMP_BASE + 32)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_CREATE_UNWIND_FAILED (GLFS_COMP_BASE + 33)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_RECORD_WIND_FAILED (GLFS_COMP_BASE + 34)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INSERT_READV_WIND_FAILED (GLFS_COMP_BASE + 35)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_GET_GFID_FROM_DICT_FAILED (GLFS_COMP_BASE + 36)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_SET (GLFS_COMP_BASE + 37)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_FATAL_ERROR (GLFS_COMP_BASE + 38)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_DANGLING_VOLUME (GLFS_COMP_BASE + 39)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_CALLOC_FAILED (GLFS_COMP_BASE + 40)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_EXTRACT_CTR_XLATOR_OPTIONS_FAILED (GLFS_COMP_BASE + 41)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INIT_DB_PARAMS_FAILED (GLFS_COMP_BASE + 42)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_CREATE_LOCAL_MEMORY_POOL_FAILED (GLFS_COMP_BASE + 43)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_MEM_ACC_INIT_FAILED (GLFS_COMP_BASE + 44)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_CLOSE_DB_CONN_FAILED (GLFS_COMP_BASE + 45)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_FILL_UNWIND_TIME_REC_ERROR (GLFS_COMP_BASE + 46)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_WRONG_FOP_PATH (GLFS_COMP_BASE + 47)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_CONSTRUCT_DB_PATH_FAILED (GLFS_COMP_BASE + 48)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_SET_VALUE_TO_SQL_PARAM_FAILED (GLFS_COMP_BASE + 49)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_XLATOR_DISABLED (GLFS_COMP_BASE + 50)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_HARDLINK_MISSING_IN_LIST (GLFS_COMP_BASE + 51)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_ADD_HARDLINK_TO_LIST_FAILED (GLFS_COMP_BASE + 52)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_INIT_LOCK_FAILED (GLFS_COMP_BASE + 53)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_COPY_FAILED (GLFS_COMP_BASE + 54)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_EXTRACT_DB_PARAM_OPTIONS_FAILED (GLFS_COMP_BASE + 55)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_ADD_HARDLINK_TO_CTR_INODE_CONTEXT_FAILED (GLFS_COMP_BASE + 56)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-#define CTR_MSG_NULL_LOCAL (GLFS_COMP_BASE + 57)
-/*------------*/
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
-
-#endif /* !_component_MESSAGES_H_ */
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(CTR,
+ CTR_MSG_CREATE_CTR_LOCAL_ERROR_WIND,
+ CTR_MSG_FILL_CTR_LOCAL_ERROR_UNWIND,
+ CTR_MSG_FILL_CTR_LOCAL_ERROR_WIND,
+ CTR_MSG_INSERT_LINK_WIND_FAILED,
+ CTR_MSG_INSERT_WRITEV_WIND_FAILED,
+ CTR_MSG_INSERT_WRITEV_UNWIND_FAILED,
+ CTR_MSG_INSERT_SETATTR_WIND_FAILED,
+ CTR_MSG_INSERT_SETATTR_UNWIND_FAILED,
+ CTR_MSG_INSERT_FREMOVEXATTR_UNWIND_FAILED,
+ CTR_MSG_INSERT_FREMOVEXATTR_WIND_FAILED,
+ CTR_MSG_INSERT_REMOVEXATTR_WIND_FAILED,
+ CTR_MSG_INSERT_REMOVEXATTR_UNWIND_FAILED,
+ CTR_MSG_INSERT_TRUNCATE_WIND_FAILED,
+ CTR_MSG_INSERT_TRUNCATE_UNWIND_FAILED,
+ CTR_MSG_INSERT_FTRUNCATE_UNWIND_FAILED,
+ CTR_MSG_INSERT_FTRUNCATE_WIND_FAILED,
+ CTR_MSG_INSERT_RENAME_WIND_FAILED,
+ CTR_MSG_INSERT_RENAME_UNWIND_FAILED,
+ CTR_MSG_ACCESS_CTR_INODE_CONTEXT_FAILED,
+ CTR_MSG_ADD_HARDLINK_FAILED,
+ CTR_MSG_DELETE_HARDLINK_FAILED,
+ CTR_MSG_UPDATE_HARDLINK_FAILED,
+ CTR_MSG_GET_CTR_RESPONSE_LINK_COUNT_XDATA_FAILED,
+ CTR_MSG_SET_CTR_RESPONSE_LINK_COUNT_XDATA_FAILED,
+ CTR_MSG_INSERT_UNLINK_UNWIND_FAILED,
+ CTR_MSG_INSERT_UNLINK_WIND_FAILED,
+ CTR_MSG_XDATA_NULL,
+ CTR_MSG_INSERT_FSYNC_WIND_FAILED,
+ CTR_MSG_INSERT_FSYNC_UNWIND_FAILED,
+ CTR_MSG_INSERT_MKNOD_UNWIND_FAILED,
+ CTR_MSG_INSERT_MKNOD_WIND_FAILED,
+ CTR_MSG_INSERT_CREATE_WIND_FAILED,
+ CTR_MSG_INSERT_CREATE_UNWIND_FAILED,
+ CTR_MSG_INSERT_RECORD_WIND_FAILED,
+ CTR_MSG_INSERT_READV_WIND_FAILED,
+ CTR_MSG_GET_GFID_FROM_DICT_FAILED,
+ CTR_MSG_SET,
+ CTR_MSG_FATAL_ERROR,
+ CTR_MSG_DANGLING_VOLUME,
+ CTR_MSG_CALLOC_FAILED,
+ CTR_MSG_EXTRACT_CTR_XLATOR_OPTIONS_FAILED,
+ CTR_MSG_INIT_DB_PARAMS_FAILED,
+ CTR_MSG_CREATE_LOCAL_MEMORY_POOL_FAILED,
+ CTR_MSG_MEM_ACC_INIT_FAILED,
+ CTR_MSG_CLOSE_DB_CONN_FAILED,
+ CTR_MSG_FILL_UNWIND_TIME_REC_ERROR,
+ CTR_MSG_WRONG_FOP_PATH,
+ CTR_MSG_CONSTRUCT_DB_PATH_FAILED,
+ CTR_MSG_SET_VALUE_TO_SQL_PARAM_FAILED,
+ CTR_MSG_XLATOR_DISABLED,
+ CTR_MSG_HARDLINK_MISSING_IN_LIST,
+ CTR_MSG_ADD_HARDLINK_TO_LIST_FAILED,
+ CTR_MSG_INIT_LOCK_FAILED,
+ CTR_MSG_COPY_FAILED,
+ CTR_MSG_EXTRACT_DB_PARAM_OPTIONS_FAILED,
+ CTR_MSG_ADD_HARDLINK_TO_CTR_INODE_CONTEXT_FAILED,
+ CTR_MSG_NULL_LOCAL
+);
+
+#endif /* !_CTR_MESSAGES_H_ */
diff --git a/xlators/features/index/src/index-messages.h b/xlators/features/index/src/index-messages.h
index 91f17555d62..7ab2bb0ad4b 100644
--- a/xlators/features/index/src/index-messages.h
+++ b/xlators/features/index/src/index-messages.h
@@ -13,109 +13,27 @@
#include "glfs-message-id.h"
-/*! \file index-messages.h
- * \brief INDEX log-message IDs and their descriptions.
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE_INDEX GLFS_MSGID_COMP_INDEX
-#define GLFS_NUM_MESSAGES 10
-#define GLFS_MSGID_END (GLFS_COMP_BASE_INDEX + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x GLFS_COMP_BASE_INDEX, "Invalid: Start of messages"
-
-/*!
- * @messageid 138001
- * @diagnosis Index directory creation failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_INDEX_DIR_CREATE_FAILED (GLFS_COMP_BASE_INDEX + 1)
-
-/*!
- * @messageid 138002
- * @diagnosis Index directory readdir failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_INDEX_READDIR_FAILED (GLFS_COMP_BASE_INDEX + 2)
-
-/*!
- * @messageid 138003
- * @diagnosis Index addition failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_INDEX_ADD_FAILED (GLFS_COMP_BASE_INDEX + 3)
-
-/*!
- * @messageid 138004
- * @diagnosis Index deletion failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_INDEX_DEL_FAILED (GLFS_COMP_BASE_INDEX + 4)
-
-/*!
- * @messageid 138005
- * @diagnosis Setting option in dictionary failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_DICT_SET_FAILED (GLFS_COMP_BASE_INDEX + 5)
-
-/*!
- * @messageid 138006
- * @diagnosis Setting/Getting inode data failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_INODE_CTX_GET_SET_FAILED (GLFS_COMP_BASE_INDEX + 6)
-
-/*!
- * @messageid 138007
- * @diagnosis Invalid argments lead to the failure.
- * @recommendedaction Brick log should give more context where it failed.
- */
-#define INDEX_MSG_INVALID_ARGS (GLFS_COMP_BASE_INDEX + 7)
-
-/*!
- * @messageid 138008
- * @diagnosis Operations on an opened file/directory failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_FD_OP_FAILED (GLFS_COMP_BASE_INDEX + 8)
-
-/*!
- * @messageid 138009
- * @diagnosis Worker thread creation for index xlator failed.
- * @recommendedaction Brick log should give the reason why it failed.
- */
-#define INDEX_MSG_WORKER_THREAD_CREATE_FAILED (GLFS_COMP_BASE_INDEX + 9)
-
-/*!
- * @messageid 138010
- * @diagnosis Index xlator needs to have single subvolume and at least one
- * parent subvolume, otherwise this message will come.
- * @recommendedaction Please check brick log file to find which of the above
- * two conditions failed.
- */
-#define INDEX_MSG_INVALID_GRAPH (GLFS_COMP_BASE_INDEX + 10)
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(INDEX,
+ INDEX_MSG_INDEX_DIR_CREATE_FAILED,
+ INDEX_MSG_INDEX_READDIR_FAILED,
+ INDEX_MSG_INDEX_ADD_FAILED,
+ INDEX_MSG_INDEX_DEL_FAILED,
+ INDEX_MSG_DICT_SET_FAILED,
+ INDEX_MSG_INODE_CTX_GET_SET_FAILED,
+ INDEX_MSG_INVALID_ARGS,
+ INDEX_MSG_FD_OP_FAILED,
+ INDEX_MSG_WORKER_THREAD_CREATE_FAILED,
+ INDEX_MSG_INVALID_GRAPH
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_INDEX_MESSAGES_H_ */
diff --git a/xlators/features/leases/src/leases-messages.h b/xlators/features/leases/src/leases-messages.h
index 62df4395a59..f4dc169b8d6 100644
--- a/xlators/features/leases/src/leases-messages.h
+++ b/xlators/features/leases/src/leases-messages.h
@@ -13,117 +13,28 @@
#include "glfs-message-id.h"
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check across the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define LEASES_COMP_BASE GLFS_MSGID_COMP_LEASES
-#define GLFS_NUM_MESSAGES 11
-#define GLFS_MSGID_END (LEASES_COMP_BASE + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x LEASES_COMP_BASE, "Invalid: Start of messages"
-/*------------*/
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_NO_MEM (LEASES_COMP_BASE + 1)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_RECALL_FAIL (LEASES_COMP_BASE + 2)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INVAL_LEASE_ID (LEASES_COMP_BASE + 3)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INVAL_UNLK_LEASE (LEASES_COMP_BASE + 4)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INVAL_INODE_CTX (LEASES_COMP_BASE + 5)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_NOT_ENABLED (LEASES_COMP_BASE + 6)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_NO_TIMER_WHEEL (LEASES_COMP_BASE + 7)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_CLNT_NOTFOUND (LEASES_COMP_BASE + 8)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INODE_NOTFOUND (LEASES_COMP_BASE + 9)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INVAL_FD_CTX (LEASES_COMP_BASE + 10)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define LEASE_MSG_INVAL_LEASE_TYPE (LEASES_COMP_BASE + 11)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- */
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(LEASES,
+ LEASE_MSG_NO_MEM,
+ LEASE_MSG_RECALL_FAIL,
+ LEASE_MSG_INVAL_LEASE_ID,
+ LEASE_MSG_INVAL_UNLK_LEASE,
+ LEASE_MSG_INVAL_INODE_CTX,
+ LEASE_MSG_NOT_ENABLED,
+ LEASE_MSG_NO_TIMER_WHEEL,
+ LEASE_MSG_CLNT_NOTFOUND,
+ LEASE_MSG_INODE_NOTFOUND,
+ LEASE_MSG_INVAL_FD_CTX,
+ LEASE_MSG_INVAL_LEASE_TYPE
+);
#endif /* !_LEASES_MESSAGES_H_ */
diff --git a/xlators/features/locks/src/pl-messages.h b/xlators/features/locks/src/pl-messages.h
index 45c8873ecb4..7a1e3f488e7 100644
--- a/xlators/features/locks/src/pl-messages.h
+++ b/xlators/features/locks/src/pl-messages.h
@@ -11,54 +11,20 @@
#ifndef _PL_MESSAGES_H_
#define _PL_MESSAGES_H_
-#ifndef _CONFIG_H
-#define _CONFIG_H
-#include "config.h"
-#endif
-
#include "glfs-message-id.h"
-/*! \file pl-messages.h
- * \brief Locks log-message IDs and their descriptions
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_PL_COMP_BASE GLFS_MSGID_COMP_PL
-#define GLFS_NUM_MESSAGES 1
-#define GLFS_MSGID_END (GLFS_PL_COMP_BASE + GLFS_NUM_MESSAGES + 1)
-/* Messaged with message IDs */
-#define glfs_msg_start_x GLFS_PL_COMP_BASE, "Invalid: Start of messages"
-/*------------*/
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-#define PL_MSG_LOCK_NUMBER (GLFS_PL_COMP_BASE + 1)
-/*------------*/
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
+GLFS_MSGID(PL,
+ PL_MSG_LOCK_NUMBER
+);
#endif /* !_PL_MESSAGES_H_ */
diff --git a/xlators/features/quota/src/quota-messages.h b/xlators/features/quota/src/quota-messages.h
index b01fe98e908..4292c5b4dcc 100644
--- a/xlators/features/quota/src/quota-messages.h
+++ b/xlators/features/quota/src/quota-messages.h
@@ -11,237 +11,43 @@
#ifndef _QUOTA_MESSAGES_H_
#define _QUOTA_MESSAGES_H_
-#ifndef _CONFIG_H
-#define _CONFIG_H
-#include "config.h"
-#endif
-
#include "glfs-message-id.h"
-/*! \file quota-messages.h
- * \brief Quota log-message IDs and their descriptions
+/* To add new message IDs, append new identifiers at the end of the list.
*
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check across the code if the message ID macro in question is reused
- * anywhere. If reused then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_QUOTA_BASE GLFS_MSGID_COMP_QUOTA
-#define GLFS_NUM_MESSAGES 23
-#define GLFS_MSGID_END (GLFS_QUOTA_BASE + GLFS_NUM_MESSAGES + 1)
-/* Messaged with message IDs */
-#define glfs_msg_start_x GLFS_QUOTA_BASE, "Invalid: Start of messages"
-/*------------*/
-
-/*!
- * @messageid 120001
- * @diagnosis Quota enforcement has failed.
- * @recommendedaction None
- */
-#define Q_MSG_ENFORCEMENT_FAILED (GLFS_QUOTA_BASE + 1)
-
-
-/*!
-* @messageid 120002
-* @diagnosis system is out of memory
-* @recommendedaction None
-*/
-#define Q_MSG_ENOMEM (GLFS_QUOTA_BASE + 2)
-
-/*!
- * @messageid 120003
- * @diagnosis Parent inode is not present in the inode table due to the
- * inode table limits or the brick was restarted recently.
- * @recommendedaction If it is a brick restart then perform a crawl on the
- * file system or the specific directory in which the problem is observed.
- * If inode table limit has been reached,please increase the limit of
- * network.inode-lru-limit to a higher value(can be set through CLI).
- */
-#define Q_MSG_PARENT_NULL (GLFS_QUOTA_BASE + 3)
-
-/*!
- * @messageid 120004
- * @diagnosis This is to inform the admin that the user has crossed the soft limit
- * of the quota configured on the directory and expected to cross the hard limit soon.
- * @recommendedaction You may reconfigure your quota limits.
- */
-#define Q_MSG_CROSSED_SOFT_LIMIT (GLFS_QUOTA_BASE + 4)
-
-/*!
- * @messageid 120005
- * @diagnosis Quota translator failed to connect to quotad. This could be
- * due to one or more of the following reasons, (1) Quotad is not running.
- * (2) Brick process has run out of memory.
- * @recommendedaction If quotad is not running, consider starting quotad.
- * else check system memory consumption.
- */
-#define Q_MSG_QUOTA_ENFORCER_RPC_INIT_FAILED (GLFS_QUOTA_BASE + 5)
-
-/*!
- * @messageid 120006
- * @diagnosis Getting cluster-wide size failed
- * @recommendedaction Restart quotad. Kill quotad by searching
- * "ps ax | grep quotad" and use volume start force to restart it.
- */
-
-#define Q_MSG_REMOTE_OPERATION_FAILED (GLFS_QUOTA_BASE + 6)
-
-/*!
- * @messageid 120007
- * @diagnosis Updation of global quota size failed. This may be due to quotad
- * is down or lost connection with quotad.
- * @recommendedaction Please restart quotad.
- */
-
-#define Q_MSG_FAILED_TO_SEND_FOP (GLFS_QUOTA_BASE + 7)
-
-/*!
- * @messageid 120008
- * @diagnosis
- * @recommendedaction Check volfile for correctness
- */
-
-#define Q_MSG_INVALID_VOLFILE (GLFS_QUOTA_BASE + 8)
-
-/*!
- * @messageid 120009
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_INODE_PARENT_NOT_FOUND (GLFS_QUOTA_BASE + 9)
-
-/*!
- * @messageid 120010
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_XDR_DECODE_ERROR (GLFS_QUOTA_BASE + 10)
-
-/*!
- * @messageid 120011
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_DICT_UNSERIALIZE_FAIL (GLFS_QUOTA_BASE + 11)
-
-/*!
- * @messageid 120012
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_DICT_SERIALIZE_FAIL (GLFS_QUOTA_BASE + 12)
-
-/*!
- * @messageid 120013
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_RPCSVC_INIT_FAILED (GLFS_QUOTA_BASE + 13)
-
-/*!
- * @messageid 120014
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_RPCSVC_LISTENER_CREATION_FAILED (GLFS_QUOTA_BASE + 14)
-
-/*!
- * @messageid 120015
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_RPCSVC_REGISTER_FAILED (GLFS_QUOTA_BASE + 15)
-
-/*!
- * @messageid 120016
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_XDR_DECODING_FAILED (GLFS_QUOTA_BASE + 16)
-/*!
- * @messageid 120017
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_RPCCLNT_REGISTER_NOTIFY_FAILED (GLFS_QUOTA_BASE + 17)
-/*!
- * @messageid 120018
- * @diagnosis
- * @recommendedaction Umount and mount the corresponing volume
- */
-
-#define Q_MSG_ANCESTRY_BUILD_FAILED (GLFS_QUOTA_BASE + 18)
-
-/*!
- * @messageid 120019
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_SIZE_KEY_MISSING (GLFS_QUOTA_BASE + 19)
-
-/*!
- * @messageid 120020
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_INODE_CTX_GET_FAILED (GLFS_QUOTA_BASE + 20)
-
-/*!
- * @messageid 120021
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_INODE_CTX_SET_FAILED (GLFS_QUOTA_BASE + 21)
-
-/*!
- * @messageid 120022
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_LOOKUP_FAILED (GLFS_QUOTA_BASE + 22)
-
-/*!
- * @messageid 120023
- * @diagnosis
- * @recommendedaction
- */
-
-#define Q_MSG_RPC_SUBMIT_FAILED (GLFS_QUOTA_BASE + 23)
-
-/*------------*/
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(QUOTA,
+ Q_MSG_ENFORCEMENT_FAILED,
+ Q_MSG_ENOMEM,
+ Q_MSG_PARENT_NULL,
+ Q_MSG_CROSSED_SOFT_LIMIT,
+ Q_MSG_QUOTA_ENFORCER_RPC_INIT_FAILED,
+ Q_MSG_REMOTE_OPERATION_FAILED,
+ Q_MSG_FAILED_TO_SEND_FOP,
+ Q_MSG_INVALID_VOLFILE,
+ Q_MSG_INODE_PARENT_NOT_FOUND,
+ Q_MSG_XDR_DECODE_ERROR,
+ Q_MSG_DICT_UNSERIALIZE_FAIL,
+ Q_MSG_DICT_SERIALIZE_FAIL,
+ Q_MSG_RPCSVC_INIT_FAILED,
+ Q_MSG_RPCSVC_LISTENER_CREATION_FAILED,
+ Q_MSG_RPCSVC_REGISTER_FAILED,
+ Q_MSG_XDR_DECODING_FAILED,
+ Q_MSG_RPCCLNT_REGISTER_NOTIFY_FAILED,
+ Q_MSG_ANCESTRY_BUILD_FAILED,
+ Q_MSG_SIZE_KEY_MISSING,
+ Q_MSG_INODE_CTX_GET_FAILED,
+ Q_MSG_INODE_CTX_SET_FAILED,
+ Q_MSG_LOOKUP_FAILED,
+ Q_MSG_RPC_SUBMIT_FAILED
+);
#endif /* !_QUOTA_MESSAGES_H_ */
diff --git a/xlators/features/selinux/src/selinux-messages.h b/xlators/features/selinux/src/selinux-messages.h
index a498dc21471..3a1663433ab 100644
--- a/xlators/features/selinux/src/selinux-messages.h
+++ b/xlators/features/selinux/src/selinux-messages.h
@@ -13,86 +13,23 @@
#include "glfs-message-id.h"
-/*! \file selinux-messages.h
- * \brief Selinux log-message IDs and their descriptions
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for readability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check acorss the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_SL_BASE GLFS_MSGID_COMP_SL
-#define GLFS_SL_NUM_MESSAGES 5
-#define GLFS_SL_MSGID_END (GLFS_SL_BASE + GLFS_NUM_MESSAGES + 1)
-/* Messages with message IDs */
-#define glfs_msg_start_x GLFS_SL_BASE, "Invalid: Start of messages"
-/*------------*/
-
-#define SL_MSG_INVALID_VOLFILE (GLFS_SL_BASE + 1)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
+/* To add new message IDs, append new identifiers at the end of the list.
*
- */
-
-#define SL_MSG_ENOMEM (GLFS_SL_BASE + 2)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-
-#define SL_MSG_MEM_ACCT_INIT_FAILED (GLFS_SL_BASE + 3)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-
-#define SL_MSG_SELINUX_GLUSTER_XATTR_MISSING (GLFS_SL_BASE + 4)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
- *
- */
-
-#define SL_MSG_SELINUX_XATTR_MISSING (GLFS_SL_BASE + 5)
-
-/*!
- * @messageid
- * @diagnosis
- * @recommendedaction
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
*
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-/*-----------*/
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
+GLFS_MSGID(SL,
+ SL_MSG_INVALID_VOLFILE,
+ SL_MSG_ENOMEM,
+ SL_MSG_MEM_ACCT_INIT_FAILED,
+ SL_MSG_SELINUX_GLUSTER_XATTR_MISSING,
+ SL_MSG_SELINUX_XATTR_MISSING
+);
#endif /*_SELINUX_MESSAGES_H */
diff --git a/xlators/features/shard/src/shard-messages.h b/xlators/features/shard/src/shard-messages.h
index 588cb687d5d..9a232a8e7ff 100644
--- a/xlators/features/shard/src/shard-messages.h
+++ b/xlators/features/shard/src/shard-messages.h
@@ -13,172 +13,35 @@
#include "glfs-message-id.h"
-/*! \file shard-messages.h
- * \brief shard log-message IDs and their descriptions.
- */
-
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check across the code if the message ID macro in question is reused
- * anywhere. If reused then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE_SHARD GLFS_MSGID_COMP_SHARD
-#define GLFS_NUM_MESSAGES 18
-#define GLFS_MSGID_END (GLFS_COMP_BASE_SHARD + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x GLFS_COMP_BASE_SHARD, "Invalid: Start of messages"
-
-/*!
- * @messageid 133001
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_BASE_FILE_LOOKUP_FAILED (GLFS_COMP_BASE_SHARD + 1)
-
-
-/*!
- * @messageid 133002
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_DICT_SET_FAILED (GLFS_COMP_BASE_SHARD + 2)
-
-
-/*!
- * @messageid 133003
- * @diagnosis /.shard already exists and is not a directory.
- * @recommendedaction Delete the /.shard file from the backend and try again.
- */
-#define SHARD_MSG_DOT_SHARD_NODIR (GLFS_COMP_BASE_SHARD + 3)
-
-
-/*!
- * @messageid 133004
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_FD_CTX_SET_FAILED (GLFS_COMP_BASE_SHARD + 4)
-
-
-/*!
- * @messageid 133005
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_INODE_CTX_GET_FAILED (GLFS_COMP_BASE_SHARD + 5)
-
-
-/*!
- * @messageid 133006
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_INODE_CTX_SET_FAILED (GLFS_COMP_BASE_SHARD + 6)
-
-
-/*!
- * @messageid 133007
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_INODE_PATH_FAILED (GLFS_COMP_BASE_SHARD + 7)
-
-
-/*!
- * @messageid 133008
- * @diagnosis
- * @recommendedaction
- */
-#define SHARD_MSG_INTERNAL_XATTR_MISSING (GLFS_COMP_BASE_SHARD + 8)
-
-
-/*!
- * @messageid 133009
- * @diagnosis The client process did not get launched due to incorrect volfile.
- * @recommendedaction Possibly check to see if the volfile is correct.
- */
-#define SHARD_MSG_INVALID_VOLFILE (GLFS_COMP_BASE_SHARD + 9)
-
-
-/*!
- * @messageid 133010
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_LOOKUP_SHARD_FAILED (GLFS_COMP_BASE_SHARD + 10)
-
-/*!
- * @messageid 133011
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_MEM_ACCT_INIT_FAILED (GLFS_COMP_BASE_SHARD + 11)
-
-/*!
- * @messageid 133012
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_NULL_THIS (GLFS_COMP_BASE_SHARD + 12)
-
-/*!
- * @messageid 133013
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_SIZE_SET_FAILED (GLFS_COMP_BASE_SHARD + 13)
-
-/*!
- * @messageid 133014
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_STAT_FAILED (GLFS_COMP_BASE_SHARD + 14)
-
-/*!
- * @messageid 133015
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_TRUNCATE_LAST_SHARD_FAILED (GLFS_COMP_BASE_SHARD + 15)
-
-/*!
- * @messageid 133016
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_UPDATE_FILE_SIZE_FAILED (GLFS_COMP_BASE_SHARD + 16)
-
-/*!
- * @messageid 133017
- * @diagnosis The operation invoked is not supported.
- * @recommendedaction Use other syscalls to write to the file.
-*/
-#define SHARD_MSG_FOP_NOT_SUPPORTED (GLFS_COMP_BASE_SHARD + 17)
-
-/*!
- * @messageid 133018
- * @diagnosis
- * @recommendedaction
-*/
-#define SHARD_MSG_INVALID_FOP (GLFS_COMP_BASE_SHARD + 18)
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
+ */
+
+GLFS_MSGID(SHARD,
+ SHARD_MSG_BASE_FILE_LOOKUP_FAILED,
+ SHARD_MSG_DICT_SET_FAILED,
+ SHARD_MSG_DOT_SHARD_NODIR,
+ SHARD_MSG_FD_CTX_SET_FAILED,
+ SHARD_MSG_INODE_CTX_GET_FAILED,
+ SHARD_MSG_INODE_CTX_SET_FAILED,
+ SHARD_MSG_INODE_PATH_FAILED,
+ SHARD_MSG_INTERNAL_XATTR_MISSING,
+ SHARD_MSG_INVALID_VOLFILE,
+ SHARD_MSG_LOOKUP_SHARD_FAILED,
+ SHARD_MSG_MEM_ACCT_INIT_FAILED,
+ SHARD_MSG_NULL_THIS,
+ SHARD_MSG_SIZE_SET_FAILED,
+ SHARD_MSG_STAT_FAILED,
+ SHARD_MSG_TRUNCATE_LAST_SHARD_FAILED,
+ SHARD_MSG_UPDATE_FILE_SIZE_FAILED,
+ SHARD_MSG_FOP_NOT_SUPPORTED,
+ SHARD_MSG_INVALID_FOP
+);
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
#endif /* !_SHARD_MESSAGES_H_ */
diff --git a/xlators/features/upcall/src/upcall-messages.h b/xlators/features/upcall/src/upcall-messages.h
index 0cfdfd68b77..b60a3ed7371 100644
--- a/xlators/features/upcall/src/upcall-messages.h
+++ b/xlators/features/upcall/src/upcall-messages.h
@@ -13,47 +13,20 @@
#include "glfs-message-id.h"
-/*! \file upcall-messages.h
- * \brief UPCALL log-message IDs and their descriptions.
+/* To add new message IDs, append new identifiers at the end of the list.
+ *
+ * Never remove a message ID. If it's not used anymore, you can rename it or
+ * leave it as it is, but not delete it. This is to prevent reutilization of
+ * IDs by other messages.
+ *
+ * The component name must match one of the entries defined in
+ * glfs-message-id.h.
*/
-/* NOTE: Rules for message additions
- * 1) Each instance of a message is _better_ left with a unique message ID, even
- * if the message format is the same. Reasoning is that, if the message
- * format needs to change in one instance, the other instances are not
- * impacted or the new change does not change the ID of the instance being
- * modified.
- * 2) Addition of a message,
- * - Should increment the GLFS_NUM_MESSAGES
- * - Append to the list of messages defined, towards the end
- * - Retain macro naming as glfs_msg_X (for redability across developers)
- * NOTE: Rules for message format modifications
- * 3) Check across the code if the message ID macro in question is reused
- * anywhere. If reused then then the modifications should ensure correctness
- * everywhere, or needs a new message ID as (1) above was not adhered to. If
- * not used anywhere, proceed with the required modification.
- * NOTE: Rules for message deletion
- * 4) Check (3) and if used anywhere else, then cannot be deleted. If not used
- * anywhere, then can be deleted, but will leave a hole by design, as
- * addition rules specify modification to the end of the list and not filling
- * holes.
- */
-
-#define GLFS_COMP_BASE_UPCALL GLFS_MSGID_COMP_UPCALL
-#define GLFS_NUM_MESSAGES 1
-#define GLFS_MSGID_END (GLFS_COMP_BASE_UPCALL + GLFS_NUM_MESSAGES + 1)
-
-#define glfs_msg_start_x GLFS_COMP_BASE_UPCALL, "Invalid: Start of messages"
-
-/*!
- * @messageid 110001
- * @diagnosis Out of Memory
- * @recommendedaction None
- */
-#define UPCALL_MSG_NO_MEMORY (GLFS_COMP_BASE_UPCALL + 1)
-#define UPCALL_MSG_INTERNAL_ERROR (GLFS_COMP_BASE_UPCALL + 2)
-#define UPCALL_MSG_NOTIFY_FAILED (GLFS_COMP_BASE_UPCALL + 3)
-
-#define glfs_msg_end_x GLFS_MSGID_END, "Invalid: End of messages"
+GLFS_MSGID(UPCALL,
+ UPCALL_MSG_NO_MEMORY,
+ UPCALL_MSG_INTERNAL_ERROR,
+ UPCALL_MSG_NOTIFY_FAILED
+);
#endif /* !_UPCALL_MESSAGES_H_ */