summaryrefslogtreecommitdiff
path: root/sql/sys_vars.cc
diff options
context:
space:
mode:
authorAlexey Yurchenko <alexey.yurchenko@galeracluster.com>2021-09-05 17:07:05 +0300
committerJan Lindström <jan.lindstrom@mariadb.com>2021-11-04 12:07:44 +0200
commita8017ecaefe9152302111101405b5186a124cd4a (patch)
tree0ffbe3df0832e6ce6d821293f4a3ead2fca68bd9 /sql/sys_vars.cc
parentccb345e2a3616590ea741830ded1b7f645639de0 (diff)
downloadmariadb-git-bb-10.8-MDEV-26971.tar.gz
MENT-1626: JSON file interface to wsrep node state.bb-10.8-MDEV-26971
Integration with status reporter in wsrep-lib. Status reporter reports changes in wsrep state and logged errors/ warnings to a json file which then can be read and interpreted by an external monitoring tool. Rationale: until the server is fully initialized it is unaccessible by client and the only source of information is an error log which is not machine-friendly. Since wsrep node can spend a very long time in initialization phase (state transfer), it may be a very long time that automatic tools can't easily monitor its liveness and progression. New variable: wsrep_status_file specifies the output file name. If not set, no file is created and no reporting is done. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
Diffstat (limited to 'sql/sys_vars.cc')
-rw-r--r--sql/sys_vars.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sys_vars.cc b/sql/sys_vars.cc
index e18ca6392d8..fe9559ec843 100644
--- a/sql/sys_vars.cc
+++ b/sql/sys_vars.cc
@@ -5961,6 +5961,11 @@ static Sys_var_charptr Sys_wsrep_notify_cmd(
READ_ONLY GLOBAL_VAR(wsrep_notify_cmd), CMD_LINE(REQUIRED_ARG),
DEFAULT(""));
+static Sys_var_charptr_fscs Sys_wsrep_status_file(
+ "wsrep_status_file", "wsrep status output filename",
+ READ_ONLY GLOBAL_VAR(wsrep_status_file), CMD_LINE(REQUIRED_ARG),
+ DEFAULT(""));
+
static Sys_var_mybool Sys_wsrep_certify_nonPK(
"wsrep_certify_nonPK", "Certify tables with no primary key",
GLOBAL_VAR(wsrep_certify_nonPK),