Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CBRD-25376] revise error message that may occur when loading ha_node_list and ha_replica_list #5231

Merged
merged 6 commits into from
Jun 30, 2024

Conversation

mhoh3963
Copy link
Contributor

@mhoh3963 mhoh3963 commented May 27, 2024

http://jira.cubrid.org/browse/CBRD-25376

Description

If incorrect information is used in ha_node_list or ha_replica_list, the error message("ha_node_list": Unknown system parameter or bad value.) is displayed in master.err, and it is hard to find the cause of the error based on this message and fix this error.
So, it need to be modified so that the error message is output differently depending on the error type.
Please refer to the issue for the changed error message.

…_list and ha_replica_list

http://jira.cubrid.org/browse/CBRD-25376

**Description**

If incorrect information is used in ha_node_list or ha_replica_list, the following error message is displayed in master.err, and it is hard to find the cause of the error based on this message and fix this error.
So, it need to be modified so that the error message is output differently depending on the error type.
Please refer to the issue for the changed error message.
@mhoh3963 mhoh3963 requested review from hornetmj and joohok May 27, 2024 01:22
@mhoh3963 mhoh3963 self-assigned this May 27, 2024
src/executables/master_heartbeat.c Show resolved Hide resolved
src/executables/master_heartbeat.c Outdated Show resolved Hide resolved
src/executables/master_heartbeat.c Outdated Show resolved Hide resolved
src/executables/master_heartbeat.c Outdated Show resolved Hide resolved
src/executables/master_heartbeat.c Outdated Show resolved Hide resolved
src/executables/master_heartbeat.c Outdated Show resolved Hide resolved
@@ -4893,7 +4920,6 @@ hb_cluster_initialize (const char *nodes, const char *replicas)
hb_Cluster->num_nodes);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that this debugging log information is not useful. How about removing it together? Below is the remaining master error log from my tests.

Time: 05/30/24 11:37:38.472 - ERROR *** file ../src/executables/master_heartbeat.c, line 2779 ERROR CODE = -839, Tran = -1, EID = 2
"ha_node_list is empty.": Unknown system parameter or bad value.

Time: 05/30/24 11:37:38.472 - DEBUG *** file ../src/executables/master_heartbeat.c, line 4920
hb_Cluster->num_nodes is smaller than '1'. (num_nodes=-1).

Time: 05/30/24 11:37:38.472 - DEBUG *** file ../src/executables/master_heartbeat.c, line 5185
hb_cluster_initialize failed. (error=-839).
Time: 05/30/24 11:42:45.109 - ERROR *** file ../src/executables/master_heartbeat.c, line 2779 ERROR CODE = -839, Tran = -1, EID = 2
"cannot find (hornetmj1) in the ha_node_list.": Unknown system parameter or bad value.

Time: 05/30/24 11:42:45.109 - DEBUG *** file ../src/executables/master_heartbeat.c, line 4920
hb_Cluster->num_nodes is smaller than '1'. (num_nodes=-1).

Time: 05/30/24 11:42:45.109 - DEBUG *** file ../src/executables/master_heartbeat.c, line 5185
hb_cluster_initialize failed. (error=-839).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got it, I will remove debug log that is "hb_Cluster->num_nodes is smaller than '1'. (num_nodes=-1)"

@mhoh3963 mhoh3963 merged commit 2b93d75 into CUBRID:develop Jun 30, 2024
8 of 9 checks passed
@mhoh3963 mhoh3963 deleted the cbrd-25376 branch June 30, 2024 23:52
mhoh3963 added a commit to mhoh3963/cubrid that referenced this pull request Aug 6, 2024
…_list and ha_replica_list (CUBRID#5231)

* [CBRD-25376] revise error message that may occur when loading ha_node_list and ha_replica_list

http://jira.cubrid.org/browse/CBRD-25376

**Description**

If incorrect information is used in ha_node_list or ha_replica_list, the following error message is displayed in master.err, and it is hard to find the cause of the error based on this message and fix this error.
So, it need to be modified so that the error message is output differently depending on the error type.
Please refer to the issue for the changed error message.
mhoh3963 added a commit to mhoh3963/cubrid that referenced this pull request Aug 6, 2024
…_list and ha_replica_list (CUBRID#5231)

* [CBRD-25376] revise error message that may occur when loading ha_node_list and ha_replica_list

http://jira.cubrid.org/browse/CBRD-25376

**Description**

If incorrect information is used in ha_node_list or ha_replica_list, the following error message is displayed in master.err, and it is hard to find the cause of the error based on this message and fix this error.
So, it need to be modified so that the error message is output differently depending on the error type.
Please refer to the issue for the changed error message.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants