mirror of
https://github.com/MariaDB/server.git
synced 2025-07-21 23:50:01 +00:00
Fix rocksdb_sys_vars.rocksdb_stats_level_basic test
The minimum statistics level now is rocksdb::StatsLevel::kDisableAll. The default remains rocksdb::StatsLevel::kExceptHistogramOrTimers which is now 1 (it used to be 0).
This commit is contained in:
@ -1250,7 +1250,7 @@ static MYSQL_SYSVAR_UINT(
|
||||
"Statistics Level for RocksDB. Default is 0 (kExceptHistogramOrTimers)",
|
||||
nullptr, rocksdb_set_rocksdb_stats_level,
|
||||
/* default */ (uint)rocksdb::StatsLevel::kExceptHistogramOrTimers,
|
||||
/* min */ (uint)rocksdb::StatsLevel::kExceptHistogramOrTimers,
|
||||
/* min */ (uint)rocksdb::StatsLevel::kDisableAll,
|
||||
/* max */ (uint)rocksdb::StatsLevel::kAll, 0);
|
||||
|
||||
static MYSQL_SYSVAR_SIZE_T(compaction_readahead_size,
|
||||
|
@ -11,7 +11,7 @@ INSERT INTO invalid_values VALUES('\'484436\'');
|
||||
SET @start_global_value = @@global.ROCKSDB_STATS_LEVEL;
|
||||
SELECT @start_global_value;
|
||||
@start_global_value
|
||||
0
|
||||
1
|
||||
'# Setting to valid values in global scope#'
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to 0"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = 0;
|
||||
@ -22,7 +22,7 @@ SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = DEFAULT;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to 4"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = 4;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@ -32,7 +32,7 @@ SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = DEFAULT;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to 2"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = 2;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@ -42,7 +42,7 @@ SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = DEFAULT;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@session.ROCKSDB_STATS_LEVEL to 444. It should fail because it is not session."
|
||||
SET @@session.ROCKSDB_STATS_LEVEL = 444;
|
||||
ERROR HY000: Variable 'rocksdb_stats_level' is a GLOBAL variable and should be set with SET GLOBAL
|
||||
@ -52,34 +52,34 @@ SET @@global.ROCKSDB_STATS_LEVEL = 'aaa';
|
||||
Got one of the listed errors
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to 'bbb'"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = 'bbb';
|
||||
Got one of the listed errors
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to '-1'"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = '-1';
|
||||
Got one of the listed errors
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to '101'"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = '101';
|
||||
Got one of the listed errors
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
"Trying to set variable @@global.ROCKSDB_STATS_LEVEL to '484436'"
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = '484436';
|
||||
Got one of the listed errors
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
SET @@global.ROCKSDB_STATS_LEVEL = @start_global_value;
|
||||
SELECT @@global.ROCKSDB_STATS_LEVEL;
|
||||
@@global.ROCKSDB_STATS_LEVEL
|
||||
0
|
||||
1
|
||||
DROP TABLE valid_values;
|
||||
DROP TABLE invalid_values;
|
||||
|
Reference in New Issue
Block a user