summaryrefslogtreecommitdiff
path: root/storage/spider/mysql-test/spider/bugfix/t/mdev_26541.test
blob: ffd993907485e2b4b6f8a9606f3bb81c475f1c54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
--echo #
--echo # MDEV-26541 Undefined symbol: _ZTI12ha_partition when attempting to use ha_spider.so in UBSAN builds
--echo #

if (`select not(count(*)) from information_schema.system_variables where variable_name='have_sanitizer' and global_value="UBSAN"`)
{
--skip test needs to be run with UBSAN
}

# init spider

INSTALL PLUGIN spider SONAME 'ha_spider.so';

let $PLUGIN_NAME= spider_flush_table_mon_cache;
let $PLUGIN_EXIST=
  `SELECT COUNT(*) FROM mysql.func WHERE name = '$PLUGIN_NAME'`;
while (!$PLUGIN_EXIST)
{
  let $PLUGIN_EXIST=
    `SELECT COUNT(*) FROM mysql.func WHERE name = '$PLUGIN_NAME'`;
}

# deinit spider

DROP FUNCTION spider_flush_table_mon_cache;
DROP FUNCTION spider_copy_tables;
DROP FUNCTION spider_ping_table;
DROP FUNCTION spider_bg_direct_sql;
DROP FUNCTION spider_direct_sql;
UNINSTALL PLUGIN spider_alloc_mem;
UNINSTALL PLUGIN spider;
DROP TABLE IF EXISTS mysql.spider_xa;
DROP TABLE IF EXISTS mysql.spider_xa_member;
DROP TABLE IF EXISTS mysql.spider_xa_failed_log;
DROP TABLE IF EXISTS mysql.spider_tables;
DROP TABLE IF EXISTS mysql.spider_link_mon_servers;
DROP TABLE IF EXISTS mysql.spider_link_failed_log;
DROP TABLE IF EXISTS mysql.spider_table_position_for_recovery;
DROP TABLE IF EXISTS mysql.spider_table_sts;
DROP TABLE IF EXISTS mysql.spider_table_crd;