mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Merged sys_vars.wsrep_* tests from maria-10.0-galera tree.
This commit is contained in:
@ -1,12 +1,60 @@
|
||||
set @start_value = @@wsrep_osu_method;
|
||||
set @@global.wsrep_osu_method='TOI';
|
||||
set @@global.wsrep_osu_method='RSU';
|
||||
set @@global.wsrep_osu_method=TOI;
|
||||
set @@global.wsrep_osu_method=RSU;
|
||||
set @@global.wsrep_osu_method=TSU;
|
||||
ERROR 42000: Variable 'wsrep_OSU_method' can't be set to the value of 'TSU'
|
||||
set @@global.wsrep_osu_method='TSU';
|
||||
ERROR 42000: Variable 'wsrep_OSU_method' can't be set to the value of 'TSU'
|
||||
SET @@global.wsrep_on = -1;
|
||||
ERROR 42000: Variable 'wsrep_on' can't be set to the value of '-1'
|
||||
set @@global.wsrep_osu_method = @start_value;
|
||||
#
|
||||
# wsrep_osu_method
|
||||
#
|
||||
# save the initial value
|
||||
SET @wsrep_osu_method_global_saved = @@global.wsrep_osu_method;
|
||||
# default
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
TOI
|
||||
|
||||
# scope
|
||||
SELECT @@session.wsrep_osu_method;
|
||||
ERROR HY000: Variable 'wsrep_OSU_method' is a GLOBAL variable
|
||||
SET @@global.wsrep_osu_method=TOI;
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
TOI
|
||||
|
||||
# valid values
|
||||
SET @@global.wsrep_osu_method=TOI;
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
TOI
|
||||
SET @@global.wsrep_osu_method=RSU;
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
SET @@global.wsrep_osu_method="RSU";
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
SET @@global.wsrep_osu_method=default;
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
TOI
|
||||
SET @@global.wsrep_osu_method=1;
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
|
||||
# invalid values
|
||||
SET @@global.wsrep_osu_method=4;
|
||||
ERROR 42000: Variable 'wsrep_OSU_method' can't be set to the value of '4'
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
SET @@global.wsrep_osu_method=NULL;
|
||||
ERROR 42000: Variable 'wsrep_OSU_method' can't be set to the value of 'NULL'
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
SET @@global.wsrep_osu_method='junk';
|
||||
ERROR 42000: Variable 'wsrep_OSU_method' can't be set to the value of 'junk'
|
||||
SELECT @@global.wsrep_osu_method;
|
||||
@@global.wsrep_osu_method
|
||||
RSU
|
||||
|
||||
# restore the initial value
|
||||
SET @@global.wsrep_osu_method = @wsrep_osu_method_global_saved;
|
||||
# End of test
|
||||
|
Reference in New Issue
Block a user