summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--VERSION6
-rw-r--r--debian/additions/mariadb.conf.d/50-server.cnf4
-rw-r--r--debian/changelog2
-rw-r--r--debian/control28
-rw-r--r--debian/salsa-ci.yml8
-rw-r--r--debian/source/lintian-overrides28
-rw-r--r--extra/innochecksum.cc8
-rw-r--r--extra/mariabackup/backup_copy.cc2
-rw-r--r--extra/mariabackup/backup_mysql.cc92
-rw-r--r--extra/mariabackup/backup_mysql.h8
-rw-r--r--man/comp_err.12
-rw-r--r--man/galera_new_cluster.12
-rw-r--r--man/galera_recovery.12
-rw-r--r--man/innochecksum.12
-rw-r--r--man/mariabackup.12
-rw-r--r--man/mariadb-conv.12
-rw-r--r--man/mariadb-service-convert.12
-rw-r--r--man/mbstream.12
-rw-r--r--man/msql2mysql.12
-rw-r--r--man/my_print_defaults.12
-rw-r--r--man/my_safe_process.12
-rw-r--r--man/myisam_ftdump.12
-rw-r--r--man/myisamchk.12
-rw-r--r--man/myisamlog.12
-rw-r--r--man/myisampack.12
-rw-r--r--man/myrocks_hotbackup.12
-rw-r--r--man/mysql-stress-test.pl.12
-rw-r--r--man/mysql-test-run.pl.12
-rw-r--r--man/mysql.12
-rw-r--r--man/mysql.server.12
-rw-r--r--man/mysql_client_test.12
-rw-r--r--man/mysql_config.12
-rw-r--r--man/mysql_convert_table_format.12
-rw-r--r--man/mysql_find_rows.12
-rw-r--r--man/mysql_fix_extensions.12
-rw-r--r--man/mysql_install_db.12
-rw-r--r--man/mysql_ldb.12
-rw-r--r--man/mysql_plugin.12
-rw-r--r--man/mysql_secure_installation.12
-rw-r--r--man/mysql_setpermission.12
-rw-r--r--man/mysql_tzinfo_to_sql.12
-rw-r--r--man/mysql_upgrade.12
-rw-r--r--man/mysql_waitpid.12
-rw-r--r--man/mysqlaccess.12
-rw-r--r--man/mysqladmin.12
-rw-r--r--man/mysqlbinlog.12
-rw-r--r--man/mysqlcheck.12
-rw-r--r--man/mysqld.82
-rw-r--r--man/mysqld_multi.12
-rw-r--r--man/mysqld_safe.12
-rw-r--r--man/mysqld_safe_helper.12
-rw-r--r--man/mysqldump.12
-rw-r--r--man/mysqldumpslow.12
-rw-r--r--man/mysqlhotcopy.12
-rw-r--r--man/mysqlimport.12
-rw-r--r--man/mysqlshow.12
-rw-r--r--man/mysqlslap.12
-rw-r--r--man/mysqltest.12
-rw-r--r--man/mytop.12
-rw-r--r--man/perror.12
-rw-r--r--man/replace.12
-rw-r--r--man/resolve_stack_dump.12
-rw-r--r--man/resolveip.12
-rw-r--r--man/wsrep_sst_common.12
-rw-r--r--man/wsrep_sst_mariabackup.12
-rw-r--r--man/wsrep_sst_mysqldump.12
-rw-r--r--man/wsrep_sst_rsync.12
-rw-r--r--man/wsrep_sst_rsync_wan.12
-rw-r--r--mysql-test/main/fast_prefix_index_fetch_innodb.result228
-rw-r--r--mysql-test/main/fast_prefix_index_fetch_innodb.test522
-rw-r--r--mysql-test/main/mysql_upgrade-6984.result1
-rw-r--r--mysql-test/main/mysql_upgrade-6984.test4
-rw-r--r--mysql-test/main/mysqld--help.result9
-rw-r--r--mysql-test/main/skip_grants.result14
-rw-r--r--mysql-test/main/skip_grants.test21
-rw-r--r--mysql-test/suite/innodb/r/innodb-change-buffer-recovery.result8
-rw-r--r--mysql-test/suite/innodb/r/innodb.result9
-rw-r--r--mysql-test/suite/innodb/r/innodb_skip_innodb_is_tables.result10
-rw-r--r--mysql-test/suite/innodb/r/innodb_status_variables.result10
-rw-r--r--mysql-test/suite/innodb/r/monitor.result138
-rw-r--r--mysql-test/suite/innodb/t/innodb-change-buffer-recovery.test6
-rw-r--r--mysql-test/suite/innodb/t/innodb.test6
-rw-r--r--mysql-test/suite/innodb/t/monitor.test87
-rw-r--r--mysql-test/suite/perfschema/t/show_sanity.test1
-rw-r--r--mysql-test/suite/rpl/include/rpl_innodb_rows_counters.inc48
-rw-r--r--mysql-test/suite/rpl/r/rpl_innodb_bug68220.result233
-rw-r--r--mysql-test/suite/rpl/t/rpl_innodb_bug68220.test53
-rw-r--r--mysql-test/suite/sys_vars/r/allow_suspicious_udfs.result11
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_prefix_index_cluster_optimization_basic.result122
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_version_basic.result17
-rw-r--r--mysql-test/suite/sys_vars/r/sysvars_innodb.result5
-rw-r--r--mysql-test/suite/sys_vars/r/sysvars_server_embedded.result20
-rw-r--r--mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result20
-rw-r--r--mysql-test/suite/sys_vars/r/sysvars_star.result2
-rw-r--r--mysql-test/suite/sys_vars/t/allow_suspicious_udfs.test14
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_prefix_index_cluster_optimization_basic.test76
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_version_basic.test30
-rw-r--r--mysql-test/suite/sys_vars/t/sysvars_innodb.test1
-rw-r--r--sql/mysqld.cc13
-rw-r--r--sql/sys_vars.cc14
-rw-r--r--storage/innobase/handler/ha_innodb.cc59
-rw-r--r--storage/innobase/handler/i_s.cc436
-rw-r--r--storage/innobase/ibuf/ibuf0ibuf.cc42
-rw-r--r--storage/innobase/include/srv0mon.h13
-rw-r--r--storage/innobase/include/srv0srv.h47
-rw-r--r--storage/innobase/include/univ.i19
-rw-r--r--storage/innobase/log/log0log.cc22
-rw-r--r--storage/innobase/row/row0mysql.cc22
-rw-r--r--storage/innobase/row/row0sel.cc12
-rw-r--r--storage/innobase/srv/srv0mon.cc106
-rw-r--r--storage/innobase/srv/srv0srv.cc169
-rw-r--r--storage/rocksdb/mysql-test/rocksdb/r/innodb_i_s_tables_disabled.result10
-rw-r--r--storage/spider/ha_spider.cc698
-rw-r--r--storage/spider/ha_spider.h30
-rw-r--r--storage/spider/mysql-test/spider/bugfix/r/index.result9
-rw-r--r--storage/spider/mysql-test/spider/bugfix/t/index.test3
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child2_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child2_2.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child2_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child3_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child3_2.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_child3_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_master_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/include/deinit_slave1_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_2.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_2.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_3.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_deinit_master_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child2_1.inc8
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child2_2.inc4
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child2_3.inc4
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child3_1.inc140
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child3_2.inc140
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_child3_3.inc140
-rw-r--r--storage/spider/mysql-test/spider/handler/include/ha_init_master_1.inc105
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_2.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_deinit_master_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_init_child2_1.inc24
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_init_child2_2.inc12
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_init_child2_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/hs_init_master_1.inc12
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child2_1.inc176
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child2_2.inc80
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child2_3.inc11
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child3_1.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child3_2.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_child3_3.inc0
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_master_1.inc186
-rw-r--r--storage/spider/mysql-test/spider/handler/include/init_slave1_1.inc10
-rw-r--r--storage/spider/mysql-test/spider/handler/my.cnf176
-rw-r--r--storage/spider/mysql-test/spider/handler/r/basic_sql.result738
-rw-r--r--storage/spider/mysql-test/spider/handler/r/basic_sql_part.result141
-rw-r--r--storage/spider/mysql-test/spider/handler/r/direct_aggregate.result100
-rw-r--r--storage/spider/mysql-test/spider/handler/r/direct_aggregate_part.result90
-rw-r--r--storage/spider/mysql-test/spider/handler/r/direct_update.result155
-rw-r--r--storage/spider/mysql-test/spider/handler/r/direct_update_part.result145
-rw-r--r--storage/spider/mysql-test/spider/handler/r/function.result160
-rw-r--r--storage/spider/mysql-test/spider/handler/r/ha.result266
-rw-r--r--storage/spider/mysql-test/spider/handler/r/ha_part.result286
-rw-r--r--storage/spider/mysql-test/spider/handler/r/spider3_fixes.result245
-rw-r--r--storage/spider/mysql-test/spider/handler/r/spider3_fixes_part.result243
-rw-r--r--storage/spider/mysql-test/spider/handler/r/spider_fixes.result634
-rw-r--r--storage/spider/mysql-test/spider/handler/r/spider_fixes_part.result246
-rw-r--r--storage/spider/mysql-test/spider/handler/r/vp_fixes.result93
-rw-r--r--storage/spider/mysql-test/spider/handler/suite.opt1
-rw-r--r--storage/spider/mysql-test/spider/handler/suite.pm10
-rw-r--r--storage/spider/mysql-test/spider/handler/t/basic_sql.test2699
-rw-r--r--storage/spider/mysql-test/spider/handler/t/basic_sql_part.test571
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child2_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child2_2.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child2_3.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child3_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child3_2.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_child3_3.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_master_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/connect_slave1_1.inc1
-rw-r--r--storage/spider/mysql-test/spider/handler/t/direct_aggregate.test179
-rw-r--r--storage/spider/mysql-test/spider/handler/t/direct_aggregate_part.test192
-rw-r--r--storage/spider/mysql-test/spider/handler/t/direct_update.test198
-rw-r--r--storage/spider/mysql-test/spider/handler/t/direct_update_part.test211
-rw-r--r--storage/spider/mysql-test/spider/handler/t/function.test253
-rw-r--r--storage/spider/mysql-test/spider/handler/t/ha.test878
-rw-r--r--storage/spider/mysql-test/spider/handler/t/ha_part.test1017
-rw-r--r--storage/spider/mysql-test/spider/handler/t/ha_test_deinit.inc30
-rw-r--r--storage/spider/mysql-test/spider/handler/t/ha_test_init.inc30
-rw-r--r--storage/spider/mysql-test/spider/handler/t/have_engine.inc7
-rw-r--r--storage/spider/mysql-test/spider/handler/t/have_func.inc5
-rw-r--r--storage/spider/mysql-test/spider/handler/t/have_partition.inc7
-rw-r--r--storage/spider/mysql-test/spider/handler/t/have_trigger.inc2
-rw-r--r--storage/spider/mysql-test/spider/handler/t/hs_test_deinit.inc17
-rw-r--r--storage/spider/mysql-test/spider/handler/t/hs_test_init.inc17
-rw-r--r--storage/spider/mysql-test/spider/handler/t/slave_test_deinit.inc6
-rw-r--r--storage/spider/mysql-test/spider/handler/t/slave_test_init.inc44
-rw-r--r--storage/spider/mysql-test/spider/handler/t/spider3_fixes.test297
-rw-r--r--storage/spider/mysql-test/spider/handler/t/spider3_fixes_part.test350
-rw-r--r--storage/spider/mysql-test/spider/handler/t/spider_fixes.test1433
-rw-r--r--storage/spider/mysql-test/spider/handler/t/spider_fixes_part.test650
-rw-r--r--storage/spider/mysql-test/spider/handler/t/test_deinit.inc37
-rw-r--r--storage/spider/mysql-test/spider/handler/t/test_init.inc74
-rw-r--r--storage/spider/mysql-test/spider/handler/t/vp_fixes.test335
-rw-r--r--storage/spider/mysql-test/spider/r/variable_deprecation.result46
-rw-r--r--storage/spider/mysql-test/spider/t/variable_deprecation.test24
-rw-r--r--storage/spider/spd_conn.cc118
-rw-r--r--storage/spider/spd_conn.h12
-rw-r--r--storage/spider/spd_copy_tables.cc3
-rw-r--r--storage/spider/spd_db_conn.cc1087
-rw-r--r--storage/spider/spd_db_conn.h20
-rw-r--r--storage/spider/spd_db_include.h35
-rw-r--r--storage/spider/spd_db_mysql.cc453
-rw-r--r--storage/spider/spd_db_mysql.h39
-rw-r--r--storage/spider/spd_direct_sql.cc7
-rw-r--r--storage/spider/spd_environ.h3
-rw-r--r--storage/spider/spd_group_by_handler.cc24
-rw-r--r--storage/spider/spd_i_s.cc33
-rw-r--r--storage/spider/spd_include.h8
-rw-r--r--storage/spider/spd_param.cc210
-rw-r--r--storage/spider/spd_param.h27
-rw-r--r--storage/spider/spd_ping_table.cc8
-rw-r--r--storage/spider/spd_table.cc105
-rw-r--r--storage/spider/spd_trx.cc9
225 files changed, 669 insertions, 19686 deletions
diff --git a/VERSION b/VERSION
index cadaa937b95..6197e7f558b 100644
--- a/VERSION
+++ b/VERSION
@@ -1,4 +1,4 @@
MYSQL_VERSION_MAJOR=10
-MYSQL_VERSION_MINOR=9
-MYSQL_VERSION_PATCH=2
-SERVER_MATURITY=gamma
+MYSQL_VERSION_MINOR=10
+MYSQL_VERSION_PATCH=0
+SERVER_MATURITY=alpha
diff --git a/debian/additions/mariadb.conf.d/50-server.cnf b/debian/additions/mariadb.conf.d/50-server.cnf
index 953a34034c6..aa61301297e 100644
--- a/debian/additions/mariadb.conf.d/50-server.cnf
+++ b/debian/additions/mariadb.conf.d/50-server.cnf
@@ -108,7 +108,7 @@ collation-server = utf8mb4_general_ci
# you can put MariaDB-only options here
[mariadb]
-# This group is only read by MariaDB-10.9 servers.
+# This group is only read by MariaDB-10.10 servers.
# If you use the same .cnf file for MariaDB of different versions,
# use this group for options that older servers don't understand
-[mariadb-10.9]
+[mariadb-10.10]
diff --git a/debian/changelog b/debian/changelog
index 0ebfb0a61c2..2f98eccffce 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-mariadb (1:10.9.0) unstable; urgency=medium
+mariadb (1:10.10.0) unstable; urgency=medium
* Initial Release
diff --git a/debian/control b/debian/control
index 8a0e14beb80..8886da40fdf 100644
--- a/debian/control
+++ b/debian/control
@@ -337,7 +337,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-client-5.1,
mariadb-client-5.2,
mariadb-client-5.3,
@@ -367,7 +366,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-server-core-10.6,
mariadb-server-core-10.7,
mariadb-server-core-10.8,
- mariadb-server-core-10.9 (<< ${source:Version}),
mysql-client (<< 5.0.51),
mysql-client-5.0,
mysql-client-5.1,
@@ -386,7 +384,7 @@ Replaces: mariadb-client (<< ${source:Version}),
percona-xtradb-cluster-server-5.7,
virtual-mysql-client-core
Provides: default-mysql-client-core,
- mariadb-client-core-10.9,
+ mariadb-client-core-10.10,
virtual-mysql-client-core
Description: MariaDB database core client binaries
MariaDB is a fast, stable and true multi-user, multi-threaded SQL database
@@ -415,7 +413,6 @@ Conflicts: mariadb-client (<< ${source:Version}),
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-client-5.1,
mariadb-client-5.2,
mariadb-client-5.3,
@@ -445,7 +442,6 @@ Breaks: mariadb-client-core (<< ${source:Version}),
mariadb-client-core-10.6,
mariadb-client-core-10.7,
mariadb-client-core-10.8,
- mariadb-client-core-10.9 (<< ${source:Version}),
mariadb-server (<< ${source:Version}),
mariadb-server-10.0,
mariadb-server-10.1,
@@ -456,7 +452,6 @@ Breaks: mariadb-client-core (<< ${source:Version}),
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mariadb-server-core (<< ${source:Version}),
mariadb-server-core-10.0,
mariadb-server-core-10.1,
@@ -488,7 +483,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-client-5.1,
mariadb-client-5.2,
mariadb-client-5.3,
@@ -503,7 +497,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-client-core-10.6,
mariadb-client-core-10.7,
mariadb-client-core-10.8,
- mariadb-client-core-10.9 (<< ${source:Version}),
mariadb-server (<< ${source:Version}),
mariadb-server-10.0,
mariadb-server-10.1,
@@ -514,7 +507,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mariadb-server-core (<< ${source:Version}),
mariadb-server-core-10.0,
mariadb-server-core-10.1,
@@ -525,7 +517,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-server-core-10.6,
mariadb-server-core-10.7,
mariadb-server-core-10.8,
- mariadb-server-core-10.9 (<< ${source:Version}),
mysql-client (<< 5.0.51),
mysql-client-5.0,
mysql-client-5.1,
@@ -553,7 +544,7 @@ Replaces: mariadb-client (<< ${source:Version}),
percona-xtradb-cluster-server-5.7,
virtual-mysql-client
Provides: default-mysql-client,
- mariadb-client-10.9,
+ mariadb-client-10.10,
virtual-mysql-client
Recommends: libdbd-mariadb-perl | libdbd-mysql-perl,
libdbi-perl,
@@ -572,7 +563,8 @@ Architecture: any
Depends: mariadb-common (>= ${source:Version}),
${misc:Depends},
${shlibs:Depends}
-Conflicts: mariadb-server-core-10.0,
+Conflicts: mariadb-server-core (<< ${source:Version}),
+ mariadb-server-core-10.0,
mariadb-server-core-10.1,
mariadb-server-core-10.2,
mariadb-server-core-10.3,
@@ -581,7 +573,6 @@ Conflicts: mariadb-server-core-10.0,
mariadb-server-core-10.6,
mariadb-server-core-10.7,
mariadb-server-core-10.8,
- mariadb-server-core-10.9 (<< ${source:Version}),
mariadb-server-core-5.1,
mariadb-server-core-5.2,
mariadb-server-core-5.3,
@@ -604,7 +595,6 @@ Breaks: mariadb-client (<< ${source:Version}),
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-server (<< ${source:Version}),
mariadb-server-10.0,
mariadb-server-10.1,
@@ -614,7 +604,6 @@ Breaks: mariadb-client (<< ${source:Version}),
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mysql-client-5.5,
mysql-server-5.5,
mysql-server-5.6,
@@ -633,7 +622,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-server (<< ${source:Version}),
mariadb-server-10.0,
mariadb-server-10.1,
@@ -643,7 +631,6 @@ Replaces: mariadb-client (<< ${source:Version}),
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mariadb-server-core-10.0,
mariadb-server-core-10.1,
mariadb-server-core-10.2,
@@ -671,7 +658,7 @@ Replaces: mariadb-client (<< ${source:Version}),
percona-xtradb-cluster-server-5.7,
virtual-mysql-server-core
Provides: default-mysql-server-core,
- mariadb-server-core-10.9,
+ mariadb-server-core-10.10,
virtual-mysql-server-core
Description: MariaDB database core server files
MariaDB is a fast, stable and true multi-user, multi-threaded SQL database
@@ -718,7 +705,6 @@ Conflicts: mariadb-server (<< ${source:Version}),
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mariadb-server-5.1,
mariadb-server-5.2,
mariadb-server-5.3,
@@ -753,7 +739,6 @@ Replaces: handlersocket-mysql-5.5,
mariadb-client-10.6,
mariadb-client-10.7,
mariadb-client-10.8,
- mariadb-client-10.9 (<< ${source:Version}),
mariadb-server (<< ${source:Version}),
mariadb-server-10.0,
mariadb-server-10.1,
@@ -764,7 +749,6 @@ Replaces: handlersocket-mysql-5.5,
mariadb-server-10.6,
mariadb-server-10.7,
mariadb-server-10.8,
- mariadb-server-10.9 (<< ${source:Version}),
mariadb-server-5.1,
mariadb-server-5.2,
mariadb-server-5.3,
@@ -787,7 +771,7 @@ Replaces: handlersocket-mysql-5.5,
percona-xtradb-cluster-server-5.7,
virtual-mysql-server
Provides: default-mysql-server,
- mariadb-server-10.9,
+ mariadb-server-10.10,
virtual-mysql-server
Description: MariaDB database server binaries
MariaDB is a fast, stable and true multi-user, multi-threaded SQL database
diff --git a/debian/salsa-ci.yml b/debian/salsa-ci.yml
index 2c4848c9b71..d7ea01ea760 100644
--- a/debian/salsa-ci.yml
+++ b/debian/salsa-ci.yml
@@ -494,7 +494,7 @@ mysql-8.0 Jammy to mariadb upgrade:
variables:
- $CI_COMMIT_TAG != null && $SALSA_CI_ENABLE_PIPELINE_ON_TAGS !~ /^(1|yes|true)$/
-mariadb.org-10.7 to mariadb-10.9 upgrade:
+mariadb.org-10.7 to mariadb-10.10 upgrade:
stage: upgrade extras
needs:
- job: build
@@ -569,12 +569,12 @@ mariadb.org-10.6 to mariadb-10.8 upgrade:
variables:
- $CI_COMMIT_TAG != null && $SALSA_CI_ENABLE_PIPELINE_ON_TAGS !~ /^(1|yes|true)$/
allow_failure: true
- # Installation on Sid fails on missing liburing1 because upstream 10.9
+ # Installation on Sid fails on missing liburing1 because upstream 10.10
# MariaDB.org buildbot has not run 'apt upgrade' for a long time.
- # Remove this allow_failure once buildbot has built a new 10.9
+ # Remove this allow_failure once buildbot has built a new 10.10
# release using latest liburing-dev in Debian Sid.
-mariadb.org-10.5 to mariadb-10.9 upgrade:
+mariadb.org-10.5 to mariadb-10.10 upgrade:
stage: upgrade extras
needs:
- job: build
diff --git a/debian/source/lintian-overrides b/debian/source/lintian-overrides
index 3f6d23b3946..b71c56d95c0 100644
--- a/debian/source/lintian-overrides
+++ b/debian/source/lintian-overrides
@@ -10,22 +10,22 @@ version-substvar-for-external-package mariadb-client-10.9 -> mysql-client-core-5
version-substvar-for-external-package mariadb-client-10.9 -> mysql-client-core-8.*
version-substvar-for-external-package libmariadbd-dev -> libmariadbclient-dev
# Intentional version-substvar-for-external-package as long as mariadb-server
-# provides mariadb-server-10.9 and mariadb-client provides mariadb-client-10.9
-version-substvar-for-external-package Conflicts (line 408) ${source:Version} mariadb-client -> mariadb-client-10.9
-version-substvar-for-external-package Conflicts (line 575) ${source:Version} mariadb-server-core -> mariadb-server-core-10.9
-version-substvar-for-external-package Conflicts (line 711) ${source:Version} mariadb-server -> mariadb-server-10.9
+# provides mariadb-server-10.10 and mariadb-client provides mariadb-client-10.10
+version-substvar-for-external-package Conflicts (line 408) ${source:Version} mariadb-client -> mariadb-client-10.10
+version-substvar-for-external-package Conflicts (line 575) ${source:Version} mariadb-server-core -> mariadb-server-core-10.10
+version-substvar-for-external-package Conflicts (line 711) ${source:Version} mariadb-server -> mariadb-server-10.10
version-substvar-for-external-package Conflicts (line 95) ${source:Version} libmariadb-dev-compat -> libmariadbclient-dev
version-substvar-for-external-package Replaces (line 109) ${source:Version} libmariadb-dev-compat -> libmariadbclient-dev
-version-substvar-for-external-package Replaces (line 330) ${source:Version} mariadb-client-core -> mariadb-client-10.9
-version-substvar-for-external-package Replaces (line 330) ${source:Version} mariadb-client-core -> mariadb-server-core-10.9
-version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-client-10.9
-version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-client-core-10.9
-version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-server-10.9
-version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-server-core-10.9
-version-substvar-for-external-package Replaces (line 626) ${source:Version} mariadb-server-core -> mariadb-client-10.9
-version-substvar-for-external-package Replaces (line 626) ${source:Version} mariadb-server-core -> mariadb-server-10.9
-version-substvar-for-external-package Replaces (line 748) ${source:Version} mariadb-server -> mariadb-client-10.9
-version-substvar-for-external-package Replaces (line 748) ${source:Version} mariadb-server -> mariadb-server-10.9
+version-substvar-for-external-package Replaces (line 330) ${source:Version} mariadb-client-core -> mariadb-client-10.10
+version-substvar-for-external-package Replaces (line 330) ${source:Version} mariadb-client-core -> mariadb-server-core-10.10
+version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-client-10.10
+version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-client-core-10.10
+version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-server-10.10
+version-substvar-for-external-package Replaces (line 481) ${source:Version} mariadb-client -> mariadb-server-core-10.10
+version-substvar-for-external-package Replaces (line 626) ${source:Version} mariadb-server-core -> mariadb-client-10.10
+version-substvar-for-external-package Replaces (line 626) ${source:Version} mariadb-server-core -> mariadb-server-10.10
+version-substvar-for-external-package Replaces (line 748) ${source:Version} mariadb-server -> mariadb-client-10.10
+version-substvar-for-external-package Replaces (line 748) ${source:Version} mariadb-server -> mariadb-server-10.10
# ColumnStore not used in Debian, safe to ignore. Reported upstream in https://jira.mariadb.org/browse/MDEV-24124
source-is-missing storage/columnstore/columnstore/utils/jemalloc/libjemalloc.so.2
# Must be fixed upstream
diff --git a/extra/innochecksum.cc b/extra/innochecksum.cc
index c0dd80cf02f..fc616f1aa14 100644
--- a/extra/innochecksum.cc
+++ b/extra/innochecksum.cc
@@ -1209,16 +1209,16 @@ static struct my_option innochecksum_options[] = {
{0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
};
-/* Print out the Innodb version and machine information. */
-static void print_version(void)
+/** Print out the version and build information. */
+static void print_version()
{
#ifdef DBUG_OFF
printf("%s Ver %s, for %s (%s)\n",
- my_progname, INNODB_VERSION_STR,
+ my_progname, PACKAGE_VERSION,
SYSTEM_TYPE, MACHINE_TYPE);
#else
printf("%s-debug Ver %s, for %s (%s)\n",
- my_progname, INNODB_VERSION_STR,
+ my_progname, PACKAGE_VERSION,
SYSTEM_TYPE, MACHINE_TYPE);
#endif /* DBUG_OFF */
}
diff --git a/extra/mariabackup/backup_copy.cc b/extra/mariabackup/backup_copy.cc
index 49dd716f15f..77d26108bf7 100644
--- a/extra/mariabackup/backup_copy.cc
+++ b/extra/mariabackup/backup_copy.cc
@@ -1492,7 +1492,7 @@ bool backup_start(CorruptedPages &corrupted_pages)
}
}
- if (have_flush_engine_logs && !opt_no_lock) {
+ if (!opt_no_lock) {
msg("Executing FLUSH NO_WRITE_TO_BINLOG ENGINE LOGS...");
xb_mysql_query(mysql_connection,
"FLUSH NO_WRITE_TO_BINLOG ENGINE LOGS", false);
diff --git a/extra/mariabackup/backup_mysql.cc b/extra/mariabackup/backup_mysql.cc
index 2065711b9c2..28424f5cf32 100644
--- a/extra/mariabackup/backup_mysql.cc
+++ b/extra/mariabackup/backup_mysql.cc
@@ -62,16 +62,13 @@ Street, Fifth Floor, Boston, MA 02110-1335 USA
char *tool_name;
char tool_args[2048];
-/* mysql flavor and version */
-mysql_flavor_t server_flavor = FLAVOR_UNKNOWN;
-unsigned long mysql_server_version = 0;
+ulong mysql_server_version;
/* server capabilities */
bool have_changed_page_bitmaps = false;
bool have_backup_locks = false;
bool have_lock_wait_timeout = false;
bool have_galera_enabled = false;
-bool have_flush_engine_logs = false;
bool have_multi_threaded_slave = false;
bool have_gtid_slave = false;
@@ -297,48 +294,13 @@ read_mysql_one_value(MYSQL *mysql, const char *query)
static
bool
-check_server_version(unsigned long version_number,
- const char *version_string,
- const char *version_comment,
- const char *innodb_version)
+check_server_version(ulong version_number, const char *version_string)
{
- bool version_supported = false;
- bool mysql51 = false;
-
- mysql_server_version = version_number;
-
- server_flavor = FLAVOR_UNKNOWN;
- if (strstr(version_comment, "Percona") != NULL) {
- server_flavor = FLAVOR_PERCONA_SERVER;
- } else if (strstr(version_comment, "MariaDB") != NULL ||
- strstr(version_string, "MariaDB") != NULL) {
- server_flavor = FLAVOR_MARIADB;
- } else if (strstr(version_comment, "MySQL") != NULL) {
- server_flavor = FLAVOR_MYSQL;
- }
-
- mysql51 = version_number > 50100 && version_number < 50500;
- version_supported = version_supported
- || (mysql51 && innodb_version != NULL);
- version_supported = version_supported
- || (version_number > 50500 && version_number < 50700);
- version_supported = version_supported
- || ((version_number > 100000)
- && server_flavor == FLAVOR_MARIADB);
-
- if (mysql51 && innodb_version == NULL) {
- msg("Error: Built-in InnoDB in MySQL 5.1 is not "
- "supported in this release. You can either use "
- "Percona XtraBackup 2.0, or upgrade to InnoDB "
- "plugin.");
- } else if (!version_supported) {
- msg("Error: Unsupported server version: '%s'. Please "
- "report a bug at "
- "https://bugs.launchpad.net/percona-xtrabackup",
- version_string);
- }
+ if (strstr(version_string, "MariaDB") && version_number >= 100800)
+ return true;
- return(version_supported);
+ msg("Error: Unsupported server version: '%s'.", version_string);
+ return false;
}
/*********************************************************************//**
@@ -348,8 +310,6 @@ bool get_mysql_vars(MYSQL *connection)
{
char *gtid_mode_var= NULL;
char *version_var= NULL;
- char *version_comment_var= NULL;
- char *innodb_version_var= NULL;
char *have_backup_locks_var= NULL;
char *log_bin_var= NULL;
char *lock_wait_timeout_var= NULL;
@@ -369,7 +329,7 @@ bool get_mysql_vars(MYSQL *connection)
char *page_zip_level_var= NULL;
char *ignore_db_dirs= NULL;
char *endptr;
- unsigned long server_version= mysql_get_server_version(connection);
+ ulong server_version= mysql_get_server_version(connection);
bool ret= true;
@@ -379,8 +339,6 @@ bool get_mysql_vars(MYSQL *connection)
{"lock_wait_timeout", &lock_wait_timeout_var},
{"gtid_mode", &gtid_mode_var},
{"version", &version_var},
- {"version_comment", &version_comment_var},
- {"innodb_version", &innodb_version_var},
{"wsrep_on", &wsrep_on_var},
{"slave_parallel_workers", &slave_parallel_workers_var},
{"gtid_slave_pos", &gtid_slave_pos_var},
@@ -423,18 +381,13 @@ bool get_mysql_vars(MYSQL *connection)
have_galera_enabled= true;
}
- /* Check server version compatibility and detect server flavor */
-
- if (!(ret= check_server_version(server_version, version_var,
- version_comment_var, innodb_version_var)))
+ /* Check server version compatibility */
+ if (!(ret= check_server_version(server_version, version_var)))
{
goto out;
}
- if (server_version > 50500)
- {
- have_flush_engine_logs= true;
- }
+ mysql_server_version= server_version;
if (slave_parallel_workers_var != NULL &&
atoi(slave_parallel_workers_var) > 0)
@@ -565,16 +518,6 @@ detect_mysql_capabilities_for_backup()
have_changed_page_bitmaps = (atoi(innodb_changed_pages) == 1);
- /* INNODB_CHANGED_PAGES are listed in
- INFORMATION_SCHEMA.PLUGINS in MariaDB, but
- FLUSH NO_WRITE_TO_BINLOG CHANGED_PAGE_BITMAPS
- is not supported for versions below 10.1.6
- (see MDEV-7472) */
- if (server_flavor == FLAVOR_MARIADB &&
- mysql_server_version < 100106) {
- have_changed_page_bitmaps = false;
- }
-
free_mysql_variables(vars);
}
@@ -1381,21 +1324,8 @@ bool
write_slave_info(MYSQL *connection)
{
String sql, comment;
- bool show_all_slaves_status= false;
-
- switch (server_flavor)
- {
- case FLAVOR_MARIADB:
- show_all_slaves_status= mysql_server_version >= 100000;
- break;
- case FLAVOR_UNKNOWN:
- case FLAVOR_MYSQL:
- case FLAVOR_PERCONA_SERVER:
- break;
- }
- if (Show_slave_status::get_slave_info(connection, show_all_slaves_status,
- &sql, &comment))
+ if (Show_slave_status::get_slave_info(connection, true, &sql, &comment))
return false; // Error
if (!sql.length())
diff --git a/extra/mariabackup/backup_mysql.h b/extra/mariabackup/backup_mysql.h
index 5e78281e1cb..291e55e3ea8 100644
--- a/extra/mariabackup/backup_mysql.h
+++ b/extra/mariabackup/backup_mysql.h
@@ -3,18 +3,14 @@
#include <mysql.h>
-/* mysql flavor and version */
-enum mysql_flavor_t { FLAVOR_UNKNOWN, FLAVOR_MYSQL,
- FLAVOR_PERCONA_SERVER, FLAVOR_MARIADB };
-extern mysql_flavor_t server_flavor;
-extern unsigned long mysql_server_version;
+/* MariaDB version */
+extern ulong mysql_server_version;
/* server capabilities */
extern bool have_changed_page_bitmaps;
extern bool have_backup_locks;
extern bool have_lock_wait_timeout;
extern bool have_galera_enabled;
-extern bool have_flush_engine_logs;
extern bool have_multi_threaded_slave;
extern bool have_gtid_slave;
diff --git a/man/comp_err.1 b/man/comp_err.1
index 6be91925bcc..1603ddf51de 100644
--- a/man/comp_err.1
+++ b/man/comp_err.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBCOMP_ERR\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBCOMP_ERR\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/galera_new_cluster.1 b/man/galera_new_cluster.1
index 8330668f983..d7efa7c84be 100644
--- a/man/galera_new_cluster.1
+++ b/man/galera_new_cluster.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBGALERA_NEW_CLUSTER\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBGALERA_NEW_CLUSTER\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/galera_recovery.1 b/man/galera_recovery.1
index 4261e81db79..90fbe67cbc0 100644
--- a/man/galera_recovery.1
+++ b/man/galera_recovery.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBGALERA_RECOVERY\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBGALERA_RECOVERY\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/innochecksum.1 b/man/innochecksum.1
index eefeddfc67e..56e4f43dbd4 100644
--- a/man/innochecksum.1
+++ b/man/innochecksum.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBINNOCHECKSUM\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBINNOCHECKSUM\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mariabackup.1 b/man/mariabackup.1
index 27354687f52..4ee0a2f09d4 100644
--- a/man/mariabackup.1
+++ b/man/mariabackup.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIABACKUP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIABACKUP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mariadb-conv.1 b/man/mariadb-conv.1
index 282b194f9df..c47e08c99a7 100644
--- a/man/mariadb-conv.1
+++ b/man/mariadb-conv.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-CONV" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-CONV" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mariadb-service-convert.1 b/man/mariadb-service-convert.1
index f10af9cb8cd..6694145e491 100644
--- a/man/mariadb-service-convert.1
+++ b/man/mariadb-service-convert.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-SERVICE-CONVERT\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-SERVICE-CONVERT\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mbstream.1 b/man/mbstream.1
index 5cf23447e66..ed9d0036381 100644
--- a/man/mbstream.1
+++ b/man/mbstream.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMBSTREAM\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMBSTREAM\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/msql2mysql.1 b/man/msql2mysql.1
index d2a362eceee..4aecf1eb077 100644
--- a/man/msql2mysql.1
+++ b/man/msql2mysql.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMSQL2MYSQL\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMSQL2MYSQL\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/my_print_defaults.1 b/man/my_print_defaults.1
index 7ce606f0bc2..e3d1c7ac06d 100644
--- a/man/my_print_defaults.1
+++ b/man/my_print_defaults.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMY_PRINT_DEFAULTS" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMY_PRINT_DEFAULTS" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/my_safe_process.1 b/man/my_safe_process.1
index 5fdb3195605..faa81190b0a 100644
--- a/man/my_safe_process.1
+++ b/man/my_safe_process.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMY_SAFE_PROCESS\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMY_SAFE_PROCESS\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/myisam_ftdump.1 b/man/myisam_ftdump.1
index 396c8341c8b..a14722f3625 100644
--- a/man/myisam_ftdump.1
+++ b/man/myisam_ftdump.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYISAM_FTDUMP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYISAM_FTDUMP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/myisamchk.1 b/man/myisamchk.1
index 203f0564f6a..a6a274ed2be 100644
--- a/man/myisamchk.1
+++ b/man/myisamchk.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYISAMCHK\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYISAMCHK\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/myisamlog.1 b/man/myisamlog.1
index b77a16d58f8..a907a9f6b99 100644
--- a/man/myisamlog.1
+++ b/man/myisamlog.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYISAMLOG\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYISAMLOG\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/myisampack.1 b/man/myisampack.1
index 7a2127dfaac..a27b62150cb 100644
--- a/man/myisampack.1
+++ b/man/myisampack.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYISAMPACK\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYISAMPACK\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/myrocks_hotbackup.1 b/man/myrocks_hotbackup.1
index 712bcd0cad4..4237c452f76 100644
--- a/man/myrocks_hotbackup.1
+++ b/man/myrocks_hotbackup.1
@@ -1,4 +1,4 @@
-.TH MYROCKS_HOTBACKUP "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH MYROCKS_HOTBACKUP "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.SH NAME
myrocks_hotbackup \- streaming backup for MariaDB MyRocks
.SH DESCRIPTION
diff --git a/man/mysql-stress-test.pl.1 b/man/mysql-stress-test.pl.1
index f122c0f92ae..c9cf6cb1069 100644
--- a/man/mysql-stress-test.pl.1
+++ b/man/mysql-stress-test.pl.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYSQL\-STRESS\-TE" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYSQL\-STRESS\-TE" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql-test-run.pl.1 b/man/mysql-test-run.pl.1
index 9f6909f9c66..618fadb0ba0 100644
--- a/man/mysql-test-run.pl.1
+++ b/man/mysql-test-run.pl.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYSQL\-TEST\-RUN\" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYSQL\-TEST\-RUN\" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql.1 b/man/mysql.1
index 6b51e0f46f9..38ab116a2ef 100644
--- a/man/mysql.1
+++ b/man/mysql.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql.server.1 b/man/mysql.server.1
index 475b2dd717d..43062e8f88f 100644
--- a/man/mysql.server.1
+++ b/man/mysql.server.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYSQL\&.SERVER\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYSQL\&.SERVER\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_client_test.1 b/man/mysql_client_test.1
index 2ed1527be72..9d23903768c 100644
--- a/man/mysql_client_test.1
+++ b/man/mysql_client_test.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-CLIENT-TEST" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-CLIENT-TEST" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_config.1 b/man/mysql_config.1
index 9b45f894c92..334478ce32c 100644
--- a/man/mysql_config.1
+++ b/man/mysql_config.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMYSQL_CONFIG\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMYSQL_CONFIG\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_convert_table_format.1 b/man/mysql_convert_table_format.1
index 4561270f801..e1deb7df54d 100644
--- a/man/mysql_convert_table_format.1
+++ b/man/mysql_convert_table_format.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-CONVERT-TAB" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-CONVERT-TAB" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_find_rows.1 b/man/mysql_find_rows.1
index fb5c0269878..f0220250bf7 100644
--- a/man/mysql_find_rows.1
+++ b/man/mysql_find_rows.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-FIND-ROWS\F" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-FIND-ROWS\F" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_fix_extensions.1 b/man/mysql_fix_extensions.1
index 5ad730ffb2d..f043a6e4298 100644
--- a/man/mysql_fix_extensions.1
+++ b/man/mysql_fix_extensions.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-FIX-EXTENSI" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-FIX-EXTENSI" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_install_db.1 b/man/mysql_install_db.1
index 17b260277c1..1046a77c7e0 100644
--- a/man/mysql_install_db.1
+++ b/man/mysql_install_db.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-INSTALL-DB\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-INSTALL-DB\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_ldb.1 b/man/mysql_ldb.1
index 2903d5f7ae6..e1c08bba995 100644
--- a/man/mysql_ldb.1
+++ b/man/mysql_ldb.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-LDB\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-LDB\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_plugin.1 b/man/mysql_plugin.1
index f1180c6e0c0..d01fd26634c 100644
--- a/man/mysql_plugin.1
+++ b/man/mysql_plugin.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-PLUGIN\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-PLUGIN\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
diff --git a/man/mysql_secure_installation.1 b/man/mysql_secure_installation.1
index f4f8b9b54b6..9c788238d9c 100644
--- a/man/mysql_secure_installation.1
+++ b/man/mysql_secure_installation.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-SECURE-INST" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-SECURE-INST" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_setpermission.1 b/man/mysql_setpermission.1
index e40d4fe4207..1510981ddeb 100644
--- a/man/mysql_setpermission.1
+++ b/man/mysql_setpermission.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-SETPERMISSI" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-SETPERMISSI" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_tzinfo_to_sql.1 b/man/mysql_tzinfo_to_sql.1
index 9e11ac048f3..08681335c47 100644
--- a/man/mysql_tzinfo_to_sql.1
+++ b/man/mysql_tzinfo_to_sql.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-TZINFO-TO-S" "1" "22 April 2022" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-TZINFO-TO-S" "1" "22 April 2022" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_upgrade.1 b/man/mysql_upgrade.1
index b109f517553..c4041f281a5 100644
--- a/man/mysql_upgrade.1
+++ b/man/mysql_upgrade.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-UPGRADE\FR" "1" "20 July 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-UPGRADE\FR" "1" "20 July 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysql_waitpid.1 b/man/mysql_waitpid.1
index 40b79ba6a41..9153d246a03 100644
--- a/man/mysql_waitpid.1
+++ b/man/mysql_waitpid.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-WAITPID\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-WAITPID\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlaccess.1 b/man/mysqlaccess.1
index 874dbaa01ec..4d9e4902dae 100644
--- a/man/mysqlaccess.1
+++ b/man/mysqlaccess.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-ACCESS\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-ACCESS\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqladmin.1 b/man/mysqladmin.1
index b118e8d8a04..a3b6b167179 100644
--- a/man/mysqladmin.1
+++ b/man/mysqladmin.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-ADMIN\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-ADMIN\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlbinlog.1 b/man/mysqlbinlog.1
index a4baf39c22c..05376046259 100644
--- a/man/mysqlbinlog.1
+++ b/man/mysqlbinlog.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-BINLOG\FR" "1" "14 April 2021" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-BINLOG\FR" "1" "14 April 2021" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlcheck.1 b/man/mysqlcheck.1
index 0138c9a2ff1..ae9937db4d3 100644
--- a/man/mysqlcheck.1
+++ b/man/mysqlcheck.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-CHECK\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-CHECK\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqld.8 b/man/mysqld.8
index a28d6a46fa5..aee253fc220 100644
--- a/man/mysqld.8
+++ b/man/mysqld.8
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADBD\FR" "8" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADBD\FR" "8" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqld_multi.1 b/man/mysqld_multi.1
index d333ffea80c..e195eb59e2e 100644
--- a/man/mysqld_multi.1
+++ b/man/mysqld_multi.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADBD-MULTI\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADBD-MULTI\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqld_safe.1 b/man/mysqld_safe.1
index 727595e4af2..6e717e2a6bc 100644
--- a/man/mysqld_safe.1
+++ b/man/mysqld_safe.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADBD-SAFE\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADBD-SAFE\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqld_safe_helper.1 b/man/mysqld_safe_helper.1
index bfd91f890aa..e25447e2c11 100644
--- a/man/mysqld_safe_helper.1
+++ b/man/mysqld_safe_helper.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADBD-SAFE-HELPER\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADBD-SAFE-HELPER\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqldump.1 b/man/mysqldump.1
index df4a55cc061..23d13e65473 100644
--- a/man/mysqldump.1
+++ b/man/mysqldump.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-DUMP\FR" "1" "24 October 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-DUMP\FR" "1" "24 October 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqldumpslow.1 b/man/mysqldumpslow.1
index ef154b04302..4f82544dc14 100644
--- a/man/mysqldumpslow.1
+++ b/man/mysqldumpslow.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-DUMPSLOW\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-DUMPSLOW\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlhotcopy.1 b/man/mysqlhotcopy.1
index fb819cd146c..9e545c784c0 100644
--- a/man/mysqlhotcopy.1
+++ b/man/mysqlhotcopy.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-HOTCOPY\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-HOTCOPY\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlimport.1 b/man/mysqlimport.1
index 3b34c8a809b..bc84ed54179 100644
--- a/man/mysqlimport.1
+++ b/man/mysqlimport.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-IMPORT\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-IMPORT\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlshow.1 b/man/mysqlshow.1
index d33b3ad1523..dd0f97ed407 100644
--- a/man/mysqlshow.1
+++ b/man/mysqlshow.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-SHOW\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-SHOW\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqlslap.1 b/man/mysqlslap.1
index 7641574b526..f14ab8fa3fa 100644
--- a/man/mysqlslap.1
+++ b/man/mysqlslap.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-SLAP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-SLAP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mysqltest.1 b/man/mysqltest.1
index 415627f7b95..0f1e138a448 100644
--- a/man/mysqltest.1
+++ b/man/mysqltest.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBMARIADB-TEST\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBMARIADB-TEST\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/mytop.1 b/man/mytop.1
index 057c60d5066..9594caade78 100644
--- a/man/mytop.1
+++ b/man/mytop.1
@@ -1,4 +1,4 @@
-.TH MYTOP "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH MYTOP "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.SH NAME
mytop \- display MariaDB server performance info like 'top'
.SH "SEE ALSO"
diff --git a/man/perror.1 b/man/perror.1
index 5d4a08d9c5a..f225e074f10 100644
--- a/man/perror.1
+++ b/man/perror.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBPERROR\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBPERROR\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/replace.1 b/man/replace.1
index b4e60d21901..d8cc27e0bab 100644
--- a/man/replace.1
+++ b/man/replace.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBREPLACE\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBREPLACE\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/resolve_stack_dump.1 b/man/resolve_stack_dump.1
index 8275cd4341a..6f59e8ef4b4 100644
--- a/man/resolve_stack_dump.1
+++ b/man/resolve_stack_dump.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBRESOLVE_STACK_DUM" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBRESOLVE_STACK_DUM" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/resolveip.1 b/man/resolveip.1
index 6d387d86522..56895b50bfc 100644
--- a/man/resolveip.1
+++ b/man/resolveip.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBRESOLVEIP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBRESOLVEIP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/wsrep_sst_common.1 b/man/wsrep_sst_common.1
index 4bf5d339a69..7b3ac5dd244 100644
--- a/man/wsrep_sst_common.1
+++ b/man/wsrep_sst_common.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBWSREP_SST_COMMON\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBWSREP_SST_COMMON\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/wsrep_sst_mariabackup.1 b/man/wsrep_sst_mariabackup.1
index e6514a1cf9c..21a73de16db 100644
--- a/man/wsrep_sst_mariabackup.1
+++ b/man/wsrep_sst_mariabackup.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBWSREP_SST_MARIABACKUP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBWSREP_SST_MARIABACKUP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/wsrep_sst_mysqldump.1 b/man/wsrep_sst_mysqldump.1
index 4dbb1887918..55a859bf979 100644
--- a/man/wsrep_sst_mysqldump.1
+++ b/man/wsrep_sst_mysqldump.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBWSREP_SST_MYSQLDUMP\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBWSREP_SST_MYSQLDUMP\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/wsrep_sst_rsync.1 b/man/wsrep_sst_rsync.1
index 6f31e47fbd2..02862256f1c 100644
--- a/man/wsrep_sst_rsync.1
+++ b/man/wsrep_sst_rsync.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBWSREP_SST_RSYNC\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBWSREP_SST_RSYNC\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/man/wsrep_sst_rsync_wan.1 b/man/wsrep_sst_rsync_wan.1
index 03e2bdfb550..0736c03f9e9 100644
--- a/man/wsrep_sst_rsync_wan.1
+++ b/man/wsrep_sst_rsync_wan.1
@@ -1,6 +1,6 @@
'\" t
.\"
-.TH "\FBWSREP_SST_RSYNC_WAN\FR" "1" "15 May 2020" "MariaDB 10\&.9" "MariaDB Database System"
+.TH "\FBWSREP_SST_RSYNC_WAN\FR" "1" "15 May 2020" "MariaDB 10\&.10" "MariaDB Database System"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
diff --git a/mysql-test/main/fast_prefix_index_fetch_innodb.result b/mysql-test/main/fast_prefix_index_fetch_innodb.result
index aa888fb0704..1ce29100c66 100644
--- a/mysql-test/main/fast_prefix_index_fetch_innodb.result
+++ b/mysql-test/main/fast_prefix_index_fetch_innodb.result
@@ -1,8 +1,3 @@
-SET @save_opt= @@GLOBAL.innodb_prefix_index_cluster_optimization;
-set global innodb_prefix_index_cluster_optimization = ON;
-show variables like 'innodb_prefix_index_cluster_optimization';
-Variable_name Value
-innodb_prefix_index_cluster_optimization ON
SET @save_innodb_stats_persistent=@@GLOBAL.innodb_stats_persistent;
SET GLOBAL innodb_stats_persistent = OFF;
# Create a table with a large varchar field that we index the prefix
@@ -31,110 +26,39 @@ id fake_id bigfield
32 1032 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
33 1033 yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
128 1128 zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz
-# Baseline sanity check: 0, 0.
-select "no-op query";
-no-op query
-no-op query
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Eligible for optimization.
select id, bigfield from prefixinno where bigfield = repeat('d', 31);
id bigfield
31 ddddddddddddddddddddddddddddddd
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Eligible for optimization, access via fake_id only.
select id, bigfield from prefixinno where fake_id = 1031;
id bigfield
31 ddddddddddddddddddddddddddddddd
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible for optimization, access via fake_id of big row.
select id, bigfield from prefixinno where fake_id = 1033;
id bigfield
33 yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible for optimization.
select id, bigfield from prefixinno where bigfield = repeat('x', 32);
id bigfield
32 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
-# Not eligible for optimization.
select id, bigfield from prefixinno where bigfield = repeat('y', 33);
id bigfield
33 yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
-# Eligible, should not increment lookup counter.
select id, bigfield from prefixinno where bigfield = repeat('b', 8);
id bigfield
8 bbbbbbbb
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
-# Eligible, should not increment lookup counter.
select id, bigfield from prefixinno where bigfield = repeat('c', 24);
id bigfield
24 cccccccccccccccccccccccc
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
-# Should increment lookup counter.
select id, bigfield from prefixinno where bigfield = repeat('z', 128);
id bigfield
128 zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
-# Disable optimization, confirm we still increment counter.
-set global innodb_prefix_index_cluster_optimization = OFF;
select id, bigfield from prefixinno where fake_id = 1033;
id bigfield
33 yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
drop table prefixinno;
# Multi-byte handling case
-set global innodb_prefix_index_cluster_optimization = ON;
SET NAMES utf8mb4;
CREATE TABLE t1(
f1 varchar(10) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_BIN,
@@ -146,113 +70,47 @@ INSERT INTO t1 VALUES('😊me'), ('eu€'), ('ls¢');
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'a';
f1
a
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'c%';
f1
cccc
cčc
-select @cluster_lookups;
-@cluster_lookups
-3
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'až';
f1
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'தமிழ்';
f1
தமிழ்
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'ggᵷ%';
f1
ggᵷg
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '😊%';
f1
😊me
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'ls¢';
f1
ls¢
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '¢¢%';
f1
¢¢
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🐱🌑%';
f1
🐱🌑
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌑%';
f1
🌑
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-2
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌒%';
f1
🌒
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-2
DROP TABLE t1;
# Multi-byte with minimum character length > 1 bytes
CREATE TABLE t1(
@@ -265,113 +123,47 @@ INSERT INTO t1 VALUES('😊me'), ('eu€'), ('ls¢');
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'a';
f1
a
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'c%';
f1
cccc
cčc
-select @cluster_lookups;
-@cluster_lookups
-3
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'až';
f1
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'தமிழ்';
f1
தமிழ்
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'ggᵷ%';
f1
ggᵷg
-select @cluster_lookups;
-@cluster_lookups
-2
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '😊%';
f1
😊me
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Not eligible - record length longer than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'ls¢';
f1
ls¢
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX(`f1`) WHERE f1 like '¢¢%';
f1
¢¢
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Eligible - record length shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🐱🌑%';
f1
🐱🌑
-select @cluster_lookups;
-@cluster_lookups
-1
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Eligible - record length is shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌑%';
f1
🌑
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-2
# Eligible - record length is shorter than prefix length
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌒%';
f1
🌒
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-2
DROP TABLE t1;
CREATE TABLE t1(
col1 INT,
@@ -383,22 +175,10 @@ INSERT INTO t1(col1) VALUES(1);
SELECT col1 FROM t1 FORCE INDEX (`idx1`) WHERE col2 is NULL;
col1
1
-select @cluster_lookups;
-@cluster_lookups
-0
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-1
# Not eligible - record length longer than prefix index
SELECT col1 FROM t1 FORCE INDEX (`idx1`) WHERE col2 like 'test1%';
col1
3
-select @cluster_lookups;
-@cluster_lookups
-2
-select @cluster_lookups_avoided;
-@cluster_lookups_avoided
-0
DROP TABLE t1;
#
# MDEV-20464 Division by 0 in row_search_with_covering_prefix()
@@ -443,18 +223,10 @@ INSERT INTO wp_blogs (domain, path) VALUES
('domain.no', '/fondsinvesteringer/'), ('domain.no', '/'),
('foo', 'bar'), ('bar', 'foo'), ('foo', 'foo'), ('bar', 'bar'),
('foo', 'foobar'), ('bar', 'foobar'), ('foobar', 'foobar');
-SET GLOBAL innodb_prefix_index_cluster_optimization=off;
-SELECT blog_id FROM wp_blogs WHERE domain IN ('domain.no')
-AND path IN ( '/fondsinvesteringer/', '/' );
-blog_id
-2
-1
-SET GLOBAL innodb_prefix_index_cluster_optimization=on;
SELECT blog_id FROM wp_blogs WHERE domain IN ('domain.no')
AND path IN ( '/fondsinvesteringer/', '/' );
blog_id
2
1
DROP TABLE wp_blogs;
-SET GLOBAL innodb_prefix_index_cluster_optimization = @save_opt;
SET GLOBAL innodb_stats_persistent = @save_innodb_stats_persistent;
diff --git a/mysql-test/main/fast_prefix_index_fetch_innodb.test b/mysql-test/main/fast_prefix_index_fetch_innodb.test
index cb7ec642fe3..7afe08bd607 100644
--- a/mysql-test/main/fast_prefix_index_fetch_innodb.test
+++ b/mysql-test/main/fast_prefix_index_fetch_innodb.test
@@ -1,9 +1,5 @@
-- source include/have_innodb.inc
-SET @save_opt= @@GLOBAL.innodb_prefix_index_cluster_optimization;
-set global innodb_prefix_index_cluster_optimization = ON;
-show variables like 'innodb_prefix_index_cluster_optimization';
-
SET @save_innodb_stats_persistent=@@GLOBAL.innodb_stats_persistent;
SET GLOBAL innodb_stats_persistent = OFF;
@@ -28,185 +24,28 @@ insert into prefixinno values (1, 1001, repeat('a', 1)),
select * from prefixinno;
-let $show_count_statement = show status like 'innodb_secondary_index_triggered_cluster_reads';
-let $show_opt_statement = show status like 'innodb_secondary_index_triggered_cluster_reads_avoided';
-
---echo # Baseline sanity check: 0, 0.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
-select "no-op query";
-
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible for optimization.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('d', 31);
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible for optimization, access via fake_id only.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where fake_id = 1031;
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible for optimization, access via fake_id of big row.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where fake_id = 1033;
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible for optimization.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('x', 32);
-
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
---echo # Not eligible for optimization.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('y', 33);
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
---echo # Eligible, should not increment lookup counter.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('b', 8);
-
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
---echo # Eligible, should not increment lookup counter.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('c', 24);
-
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
---echo # Should increment lookup counter.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
select id, bigfield from prefixinno where bigfield = repeat('z', 128);
-
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
---echo # Disable optimization, confirm we still increment counter.
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
-set global innodb_prefix_index_cluster_optimization = OFF;
select id, bigfield from prefixinno where fake_id = 1033;
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval select $count - $base_count into @cluster_lookups;
-eval select $opt - $base_opt into @cluster_lookups_avoided;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
drop table prefixinno;
--echo # Multi-byte handling case
-set global innodb_prefix_index_cluster_optimization = ON;
SET NAMES utf8mb4;
CREATE TABLE t1(
f1 varchar(10) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_BIN,
@@ -217,200 +56,38 @@ INSERT INTO t1 VALUES('தமிழ்'), ('🐱🌑'), ('🌒'), ('🌑');
INSERT INTO t1 VALUES('😊me'), ('eu€'), ('ls¢');
--echo # Eligible - record length is shorter than prefix
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'a';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'c%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'až';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'தமிழ்';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'ggᵷ%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '😊%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'ls¢';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '¢¢%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🐱🌑%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌑%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌒%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
DROP TABLE t1;
--echo # Multi-byte with minimum character length > 1 bytes
@@ -424,201 +101,38 @@ INSERT INTO t1 VALUES('தமிழ்'), ('🐱🌑'), ('🌒'), ('🌑');
INSERT INTO t1 VALUES('😊me'), ('eu€'), ('ls¢');
--echo # Eligible - record length is shorter than prefix
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'a';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'c%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'až';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'தமிழ்';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like 'ggᵷ%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '😊%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 = 'ls¢';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX(`f1`) WHERE f1 like '¢¢%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🐱🌑%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length is shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌑%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Eligible - record length is shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT f1 FROM t1 FORCE INDEX (`f1`) WHERE f1 like '🌒%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
DROP TABLE t1;
CREATE TABLE t1(
@@ -629,41 +143,11 @@ INSERT INTO t1 VALUES (2, 'test'), (3, repeat('test1', 2000));
INSERT INTO t1(col1) VALUES(1);
--echo # Eligible - record length is shorter than prefix length
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT col1 FROM t1 FORCE INDEX (`idx1`) WHERE col2 is NULL;
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
--echo # Not eligible - record length longer than prefix index
-
-let $base_count = query_get_value($show_count_statement, Value, 1);
-let $base_opt = query_get_value($show_opt_statement, Value, 1);
-
SELECT col1 FROM t1 FORCE INDEX (`idx1`) WHERE col2 like 'test1%';
-let $count = query_get_value($show_count_statement, Value, 1);
-let $opt = query_get_value($show_opt_statement, Value, 1);
-
---disable_query_log
-eval set @cluster_lookups = $count - $base_count;
-eval set @cluster_lookups_avoided = $opt - $base_opt;
---enable_query_log
-
-select @cluster_lookups;
-select @cluster_lookups_avoided;
-
DROP TABLE t1;
--echo #
@@ -709,15 +193,9 @@ INSERT INTO wp_blogs (domain, path) VALUES
('foo', 'bar'), ('bar', 'foo'), ('foo', 'foo'), ('bar', 'bar'),
('foo', 'foobar'), ('bar', 'foobar'), ('foobar', 'foobar');
-SET GLOBAL innodb_prefix_index_cluster_optimization=off;
-SELECT blog_id FROM wp_blogs WHERE domain IN ('domain.no')
-AND path IN ( '/fondsinvesteringer/', '/' );
-
-SET GLOBAL innodb_prefix_index_cluster_optimization=on;
SELECT blog_id FROM wp_blogs WHERE domain IN ('domain.no')
AND path IN ( '/fondsinvesteringer/', '/' );
DROP TABLE wp_blogs;
-SET GLOBAL innodb_prefix_index_cluster_optimization = @save_opt;
SET GLOBAL innodb_stats_persistent = @save_innodb_stats_persistent;
diff --git a/mysql-test/main/mysql_upgrade-6984.result b/mysql-test/main/mysql_upgrade-6984.result
index a0ea4607b24..301fdfc3bfd 100644
--- a/mysql-test/main/mysql_upgrade-6984.result
+++ b/mysql-test/main/mysql_upgrade-6984.result
@@ -168,3 +168,4 @@ connect con1,localhost,root,foo,,,;
update mysql.global_priv set priv=json_compact(json_remove(priv, '$.plugin', '$.authentication_string')) where user='root';
flush privileges;
set global event_scheduler=OFF;
+# restart
diff --git a/mysql-test/main/mysql_upgrade-6984.test b/mysql-test/main/mysql_upgrade-6984.test
index 48a06bbd542..034310e036f 100644
--- a/mysql-test/main/mysql_upgrade-6984.test
+++ b/mysql-test/main/mysql_upgrade-6984.test
@@ -26,3 +26,7 @@ set global event_scheduler=OFF;
let MYSQLD_DATADIR= `select @@datadir`;
--remove_file $MYSQLD_DATADIR/mysql_upgrade_info
+
+# --skip-grant-tables state may changed during the test. Need to restart the server
+# to restore the --skip-grant-tables state. Otherwise MTR's internal check will fail
+--source include/restart_mysqld.inc
diff --git a/mysql-test/main/mysqld--help.result b/mysql-test/main/mysqld--help.result
index 684db62d770..5ada9729b4c 100644
--- a/mysql-test/main/mysqld--help.result
+++ b/mysql-test/main/mysqld--help.result
@@ -8,10 +8,11 @@ The following specify which files/extra groups are read (specified before remain
--defaults-group-suffix=# Additionally read default groups with # appended as a suffix.
--allow-suspicious-udfs
- Allows use of UDFs consisting of only one symbol xxx()
- without corresponding xxx_init() or xxx_deinit(). That
- also means that one can load any function from any
- library, for example exit() from libc.so
+ Allows use of user-defined functions (UDFs) consisting of
+ only one symbol xxx() without corresponding xxx_init() or
+ xxx_deinit(). That also means that one can load any
+ function from any library, for example exit() from
+ libc.so
--alter-algorithm[=name]
Specify the alter table algorithm. One of: DEFAULT, COPY,
INPLACE, NOCOPY, INSTANT
diff --git a/mysql-test/main/skip_grants.result b/mysql-test/main/skip_grants.result
index f21bfa1da41..fdd7be41095 100644
--- a/mysql-test/main/skip_grants.result
+++ b/mysql-test/main/skip_grants.result
@@ -137,3 +137,17 @@ drop user baz@baz;
#
# End of 10.3 tests
#
+#
+# MDEV-24815 Show "--skip-grant-tables" state in SYSTEM VARIABLES
+#
+SELECT @@skip_grant_tables AS EXPECT_1;
+EXPECT_1
+1
+# restart: --skip-skip-grant-tables
+SELECT @@skip_grant_tables AS EXPECT_0;
+EXPECT_0
+0
+# restart: --skip-grant-tables
+#
+# End of 10.10 tests
+#
diff --git a/mysql-test/main/skip_grants.test b/mysql-test/main/skip_grants.test
index 7594285aed7..b74cd41b039 100644
--- a/mysql-test/main/skip_grants.test
+++ b/mysql-test/main/skip_grants.test
@@ -160,7 +160,7 @@ alter user baz@baz identified with mysql_native_password as password("baz");
show create user baz@baz;
drop user bar@foo;
drop user baz@baz;
-# need to restart the server to restore the --skip-grant state
+# Need to restart the server to restore the "--skip-grant-tables" state
--source include/restart_mysqld.inc
--enable_ps_protocol
@@ -168,3 +168,22 @@ drop user baz@baz;
--echo #
--echo # End of 10.3 tests
--echo #
+
+--echo #
+--echo # MDEV-24815 Show "--skip-grant-tables" state in SYSTEM VARIABLES
+--echo #
+
+SELECT @@skip_grant_tables AS EXPECT_1;
+
+# Also check when the server starts without "--skip-grant-table" option
+--let $restart_parameters = "--skip-skip-grant-tables"
+--source include/restart_mysqld.inc
+SELECT @@skip_grant_tables AS EXPECT_0;
+
+# Need to restart the server to restore the "--skip-grant-tables" state
+--let $restart_parameters = "--skip-grant-tables"
+--source include/restart_mysqld.inc
+
+--echo #
+--echo # End of 10.10 tests
+--echo #
diff --git a/mysql-test/suite/innodb/r/innodb-change-buffer-recovery.result b/mysql-test/suite/innodb/r/innodb-change-buffer-recovery.result
index 13e45425872..42fdf680f2e 100644
--- a/mysql-test/suite/innodb/r/innodb-change-buffer-recovery.result
+++ b/mysql-test/suite/innodb/r/innodb-change-buffer-recovery.result
@@ -39,19 +39,13 @@ Table Op Msg_type Msg_text
test.t1 check Error Unknown storage engine 'InnoDB'
test.t1 check error Corrupt
FOUND 1 /innodb_read_only prevents crash recovery/ in mysqld.1.err
-# restart: --innodb-force-recovery=5
+# restart: --innodb-force-recovery=5 --debug-dbug=d,crash_after_log_ibuf_upd_inplace
SELECT * FROM t1 LIMIT 1;
a b c
1 X 1
-SHOW ENGINE INNODB STATUS;
-Type Name Status
-InnoDB insert 0, delete mark 0
SET GLOBAL innodb_fast_shutdown=0;
# restart
CHECK TABLE t1;
Table Op Msg_type Msg_text
test.t1 check status OK
-SHOW ENGINE INNODB STATUS;
-Type Name Status
-InnoDB
DROP TABLE t1;
diff --git a/mysql-test/suite/innodb/r/innodb.result b/mysql-test/suite/innodb/r/innodb.result
index d799cbb8fd9..27df5f3133e 100644
--- a/mysql-test/suite/innodb/r/innodb.result
+++ b/mysql-test/suite/innodb/r/innodb.result
@@ -1694,15 +1694,6 @@ OK
SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_page_size';
variable_value
16384
-SELECT variable_value - @innodb_rows_deleted_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_deleted';
-variable_value - @innodb_rows_deleted_orig
-71
-SELECT variable_value - @innodb_rows_inserted_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_inserted';
-variable_value - @innodb_rows_inserted_orig
-964
-SELECT variable_value - @innodb_rows_updated_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_updated';
-variable_value - @innodb_rows_updated_orig
-865
SELECT variable_value - @innodb_row_lock_waits_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_row_lock_waits';
variable_value - @innodb_row_lock_waits_orig
0
diff --git a/mysql-test/suite/innodb/r/innodb_skip_innodb_is_tables.result b/mysql-test/suite/innodb/r/innodb_skip_innodb_is_tables.result
index a504bb4aa39..bc5051b1442 100644
--- a/mysql-test/suite/innodb/r/innodb_skip_innodb_is_tables.result
+++ b/mysql-test/suite/innodb/r/innodb_skip_innodb_is_tables.result
@@ -70,8 +70,6 @@ buffer_pool_pages_free buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL N
buffer_pages_created buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages created (innodb_pages_created)
buffer_pages_written buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages written (innodb_pages_written)
buffer_pages_read buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages read (innodb_pages_read)
-buffer_index_sec_rec_cluster_reads buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of secondary record reads triggered cluster read
-buffer_index_sec_rec_cluster_reads_avoided buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of secondary record reads avoided triggering cluster read
buffer_data_reads buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Amount of data read in bytes (innodb_data_reads)
buffer_data_written buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Amount of data written in bytes (innodb_data_written)
buffer_flush_batch_scanned buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 set_owner Total pages scanned as part of flush batch
@@ -226,14 +224,6 @@ innodb_dict_lru_count_idle server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NU
innodb_dblwr_writes server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of doublewrite operations that have been performed (innodb_dblwr_writes)
innodb_dblwr_pages_written server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages that have been written for doublewrite operations (innodb_dblwr_pages_written)
innodb_page_size server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 value InnoDB page size in bytes (innodb_page_size)
-dml_reads dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows read
-dml_inserts dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows inserted
-dml_deletes dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows deleted
-dml_updates dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows updated
-dml_system_reads dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows read
-dml_system_inserts dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows inserted
-dml_system_deletes dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows deleted
-dml_system_updates dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows updated
ddl_background_drop_indexes ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of indexes waiting to be dropped after failed index creation
ddl_online_create_index ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of indexes being created online
ddl_pending_alter_table ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of ALTER TABLE, CREATE INDEX, DROP INDEX in progress
diff --git a/mysql-test/suite/innodb/r/innodb_status_variables.result b/mysql-test/suite/innodb/r/innodb_status_variables.result
index 086e4e1d1e7..2271cf48b14 100644
--- a/mysql-test/suite/innodb/r/innodb_status_variables.result
+++ b/mysql-test/suite/innodb/r/innodb_status_variables.result
@@ -74,14 +74,6 @@ INNODB_ROW_LOCK_TIME
INNODB_ROW_LOCK_TIME_AVG
INNODB_ROW_LOCK_TIME_MAX
INNODB_ROW_LOCK_WAITS
-INNODB_ROWS_DELETED
-INNODB_ROWS_INSERTED
-INNODB_ROWS_READ
-INNODB_ROWS_UPDATED
-INNODB_SYSTEM_ROWS_DELETED
-INNODB_SYSTEM_ROWS_INSERTED
-INNODB_SYSTEM_ROWS_READ
-INNODB_SYSTEM_ROWS_UPDATED
INNODB_NUM_OPEN_FILES
INNODB_TRUNCATED_STATUS_WRITES
INNODB_AVAILABLE_UNDO_LOGS
@@ -106,8 +98,6 @@ INNODB_INSTANT_ALTER_COLUMN
INNODB_ONLINEDDL_ROWLOG_ROWS
INNODB_ONLINEDDL_ROWLOG_PCT_USED
INNODB_ONLINEDDL_PCT_PROGRESS
-INNODB_SECONDARY_INDEX_TRIGGERED_CLUSTER_READS
-INNODB_SECONDARY_INDEX_TRIGGERED_CLUSTER_READS_AVOIDED
INNODB_ENCRYPTION_ROTATION_PAGES_READ_FROM_CACHE
INNODB_ENCRYPTION_ROTATION_PAGES_READ_FROM_DISK
INNODB_ENCRYPTION_ROTATION_PAGES_MODIFIED
diff --git a/mysql-test/suite/innodb/r/monitor.result b/mysql-test/suite/innodb/r/monitor.result
index 922c66a068f..24cd0ed064e 100644
--- a/mysql-test/suite/innodb/r/monitor.result
+++ b/mysql-test/suite/innodb/r/monitor.result
@@ -36,8 +36,6 @@ buffer_pool_pages_free disabled
buffer_pages_created disabled
buffer_pages_written disabled
buffer_pages_read disabled
-buffer_index_sec_rec_cluster_reads disabled
-buffer_index_sec_rec_cluster_reads_avoided disabled
buffer_data_reads disabled
buffer_data_written disabled
buffer_flush_batch_scanned disabled
@@ -192,14 +190,6 @@ innodb_dict_lru_count_idle disabled
innodb_dblwr_writes disabled
innodb_dblwr_pages_written disabled
innodb_page_size disabled
-dml_reads disabled
-dml_inserts disabled
-dml_deletes disabled
-dml_updates disabled
-dml_system_reads disabled
-dml_system_inserts disabled
-dml_system_deletes disabled
-dml_system_updates disabled
ddl_background_drop_indexes disabled
ddl_online_create_index disabled
ddl_pending_alter_table disabled
@@ -391,134 +381,6 @@ where name='trx_rollbacks';
name max_count min_count count max_count_reset min_count_reset count_reset status
trx_rollbacks 1 NULL 1 1 NULL 1 enabled
set global innodb_monitor_disable = module_trx;
-set global innodb_monitor_enable = module_dml;
-insert into monitor_test values(9);
-update monitor_test set col = 10 where col = 9;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 2 NULL 2 2 NULL 2 enabled
-dml_inserts 1 NULL 1 1 NULL 1 enabled
-dml_deletes 0 NULL 0 0 NULL 0 enabled
-dml_updates 2 NULL 2 2 NULL 2 enabled
-dml_system_reads 0 NULL 0 0 NULL 0 enabled
-dml_system_inserts 0 NULL 0 0 NULL 0 enabled
-dml_system_deletes 0 NULL 0 0 NULL 0 enabled
-dml_system_updates 0 NULL 0 0 NULL 0 enabled
-delete from monitor_test;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 4 NULL 4 4 NULL 4 enabled
-dml_inserts 1 NULL 1 1 NULL 1 enabled
-dml_deletes 2 NULL 2 2 NULL 2 enabled
-dml_updates 2 NULL 2 2 NULL 2 enabled
-dml_system_reads 0 NULL 0 0 NULL 0 enabled
-dml_system_inserts 0 NULL 0 0 NULL 0 enabled
-dml_system_deletes 0 NULL 0 0 NULL 0 enabled
-dml_system_updates 0 NULL 0 0 NULL 0 enabled
-set global innodb_monitor_reset = module_dml;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 4 NULL 4 0 NULL 0 enabled
-dml_inserts 1 NULL 1 0 NULL 0 enabled
-dml_deletes 2 NULL 2 0 NULL 0 enabled
-dml_updates 2 NULL 2 0 NULL 0 enabled
-dml_system_reads 0 NULL 0 0 NULL 0 enabled
-dml_system_inserts 0 NULL 0 0 NULL 0 enabled
-dml_system_deletes 0 NULL 0 0 NULL 0 enabled
-dml_system_updates 0 NULL 0 0 NULL 0 enabled
-insert into monitor_test values(9);
-insert into monitor_test values(1);
-delete from monitor_test;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 6 NULL 6 2 NULL 2 enabled
-dml_inserts 3 NULL 3 2 NULL 2 enabled
-dml_deletes 4 NULL 4 2 NULL 2 enabled
-dml_updates 2 NULL 2 0 NULL 0 enabled
-dml_system_reads 0 NULL 0 0 NULL 0 enabled
-dml_system_inserts 0 NULL 0 0 NULL 0 enabled
-dml_system_deletes 0 NULL 0 0 NULL 0 enabled
-dml_system_updates 0 NULL 0 0 NULL 0 enabled
-set global innodb_monitor_reset_all = module_dml;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 6 NULL 6 2 NULL 2 enabled
-dml_inserts 3 NULL 3 2 NULL 2 enabled
-dml_deletes 4 NULL 4 2 NULL 2 enabled
-dml_updates 2 NULL 2 0 NULL 0 enabled
-dml_system_reads 0 NULL 0 0 NULL 0 enabled
-dml_system_inserts 0 NULL 0 0 NULL 0 enabled
-dml_system_deletes 0 NULL 0 0 NULL 0 enabled
-dml_system_updates 0 NULL 0 0 NULL 0 enabled
-set global innodb_monitor_disable = module_dml;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads 6 NULL 6 2 NULL 2 disabled
-dml_inserts 3 NULL 3 2 NULL 2 disabled
-dml_deletes 4 NULL 4 2 NULL 2 disabled
-dml_updates 2 NULL 2 0 NULL 0 disabled
-dml_system_reads 0 NULL 0 0 NULL 0 disabled
-dml_system_inserts 0 NULL 0 0 NULL 0 disabled
-dml_system_deletes 0 NULL 0 0 NULL 0 disabled
-dml_system_updates 0 NULL 0 0 NULL 0 disabled
-set global innodb_monitor_reset_all = module_dml;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads NULL NULL 0 NULL NULL 0 disabled
-dml_inserts NULL NULL 0 NULL NULL 0 disabled
-dml_deletes NULL NULL 0 NULL NULL 0 disabled
-dml_updates NULL NULL 0 NULL NULL 0 disabled
-dml_system_reads NULL NULL 0 NULL NULL 0 disabled
-dml_system_inserts NULL NULL 0 NULL NULL 0 disabled
-dml_system_deletes NULL NULL 0 NULL NULL 0 disabled
-dml_system_updates NULL NULL 0 NULL NULL 0 disabled
-set global innodb_monitor_enable = dml_inserts;
-insert into monitor_test values(9);
-insert into monitor_test values(1);
-delete from monitor_test;
-select name, max_count, min_count, count,
-max_count_reset, min_count_reset, count_reset,
-if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-name max_count min_count count max_count_reset min_count_reset count_reset status
-dml_reads NULL NULL 0 NULL NULL 0 disabled
-dml_inserts 2 NULL 2 2 NULL 2 enabled
-dml_deletes NULL NULL 0 NULL NULL 0 disabled
-dml_updates NULL NULL 0 NULL NULL 0 disabled
-dml_system_reads NULL NULL 0 NULL NULL 0 disabled
-dml_system_inserts NULL NULL 0 NULL NULL 0 disabled
-dml_system_deletes NULL NULL 0 NULL NULL 0 disabled
-dml_system_updates NULL NULL 0 NULL NULL 0 disabled
-set global innodb_monitor_disable = module_dml;
drop table monitor_test;
set global innodb_monitor_enable = file_num_open_files;
select name, max_count, min_count, count,
diff --git a/mysql-test/suite/innodb/t/innodb-change-buffer-recovery.test b/mysql-test/suite/innodb/t/innodb-change-buffer-recovery.test
index 129037e783b..dbce2f91948 100644
--- a/mysql-test/suite/innodb/t/innodb-change-buffer-recovery.test
+++ b/mysql-test/suite/innodb/t/innodb-change-buffer-recovery.test
@@ -67,16 +67,12 @@ CHECK TABLE t1;
let SEARCH_PATTERN=innodb_read_only prevents crash recovery;
--source include/search_pattern_in_file.inc
---let $restart_parameters= --innodb-force-recovery=5
+--let $restart_parameters= --innodb-force-recovery=5 --debug-dbug=d,crash_after_log_ibuf_upd_inplace
--source include/start_mysqld.inc
SELECT * FROM t1 LIMIT 1;
-replace_regex /.*operations:.* (insert.*), delete \d.*discarded .*/\1/;
-SHOW ENGINE INNODB STATUS;
# Slow shutdown will not merge the changes due to innodb_force_recovery=5.
SET GLOBAL innodb_fast_shutdown=0;
--let $restart_parameters=
--source include/restart_mysqld.inc
CHECK TABLE t1;
-replace_regex /.*operations:.* insert [1-9][0-9]*, delete mark [1-9][0-9]*, delete \d.*discarded .*//;
-SHOW ENGINE INNODB STATUS;
DROP TABLE t1;
diff --git a/mysql-test/suite/innodb/t/innodb.test b/mysql-test/suite/innodb/t/innodb.test
index 3a8c12dfbbd..3df24735860 100644
--- a/mysql-test/suite/innodb/t/innodb.test
+++ b/mysql-test/suite/innodb/t/innodb.test
@@ -25,9 +25,6 @@ call mtr.add_suppression("\\[ERROR\\] InnoDB: in ALTER TABLE `test`.`t1`");
call mtr.add_suppression("\\[ERROR\\] InnoDB: in RENAME TABLE table `test`.`t1`");
--disable_warnings
-SET @innodb_rows_deleted_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_deleted');
-SET @innodb_rows_inserted_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_inserted');
-SET @innodb_rows_updated_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_updated');
SET @innodb_row_lock_waits_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_row_lock_waits');
SET @innodb_row_lock_current_waits_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_row_lock_current_waits');
SET @innodb_row_lock_time_orig = (SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_row_lock_time');
@@ -1319,9 +1316,6 @@ drop table t1;
# uses previous ones(pages_created, rows_deleted, ...).
SELECT IF(variable_value BETWEEN 488 AND 512, 'OK', variable_value) FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_buffer_pool_pages_total';
SELECT variable_value FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_page_size';
-SELECT variable_value - @innodb_rows_deleted_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_deleted';
-SELECT variable_value - @innodb_rows_inserted_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_inserted';
-SELECT variable_value - @innodb_rows_updated_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_rows_updated';
# Test for row locks InnoDB status variables.
SELECT variable_value - @innodb_row_lock_waits_orig FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_row_lock_waits';
diff --git a/mysql-test/suite/innodb/t/monitor.test b/mysql-test/suite/innodb/t/monitor.test
index 3a004b22751..731c2b034fb 100644
--- a/mysql-test/suite/innodb/t/monitor.test
+++ b/mysql-test/suite/innodb/t/monitor.test
@@ -254,93 +254,6 @@ where name='trx_rollbacks';
set global innodb_monitor_disable = module_trx;
-# Test DML Module
-set global innodb_monitor_enable = module_dml;
-
-insert into monitor_test values(9);
-
-update monitor_test set col = 10 where col = 9;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-delete from monitor_test;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
- from information_schema.innodb_metrics
- where name like "dml%";
-
-# test reset counter while the counter is on
-set global innodb_monitor_reset = module_dml;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-# insert/delete some rows after the reset
-insert into monitor_test values(9);
-insert into monitor_test values(1);
-
-delete from monitor_test;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-# We do not allow reset_all while the counter is on, nothing
-# should be reset here
-set global innodb_monitor_reset_all = module_dml;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-# Turn off the counter
-set global innodb_monitor_disable = module_dml;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-# Reset all counter values
-set global innodb_monitor_reset_all = module_dml;
-
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-# Open individual counter "dml_inserts"
-set global innodb_monitor_enable = dml_inserts;
-
-insert into monitor_test values(9);
-insert into monitor_test values(1);
-
-delete from monitor_test;
-
-# Only counter "dml_inserts" should be updated
-select name, max_count, min_count, count,
- max_count_reset, min_count_reset, count_reset,
- if(enabled,'enabled','disabled') status
-from information_schema.innodb_metrics
-where name like "dml%";
-
-set global innodb_monitor_disable = module_dml;
-
drop table monitor_test;
set global innodb_monitor_enable = file_num_open_files;
diff --git a/mysql-test/suite/perfschema/t/show_sanity.test b/mysql-test/suite/perfschema/t/show_sanity.test
index 171bbfa8bd6..3ca88b556f8 100644
--- a/mysql-test/suite/perfschema/t/show_sanity.test
+++ b/mysql-test/suite/perfschema/t/show_sanity.test
@@ -496,7 +496,6 @@ insert into test.sanity values
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INNODB_UNDO_LOG_TRUNCATE"),
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INNODB_UNDO_TABLESPACES"),
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INNODB_USE_NATIVE_AIO"),
- ("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INNODB_VERSION"),
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INNODB_WRITE_IO_THREADS"),
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "INTERNAL_TMP_DISK_STORAGE_ENGINE"),
("JUNK: GLOBAL-ONLY", "I_S.SESSION_VARIABLES", "KEY_BUFFER_SIZE"),
diff --git a/mysql-test/suite/rpl/include/rpl_innodb_rows_counters.inc b/mysql-test/suite/rpl/include/rpl_innodb_rows_counters.inc
deleted file mode 100644
index cb51058f0ae..00000000000
--- a/mysql-test/suite/rpl/include/rpl_innodb_rows_counters.inc
+++ /dev/null
@@ -1,48 +0,0 @@
-#########################################
-# Author: Benjamin Renard benj@fb.com
-# Date: 11/15/2013
-# Purpose: Showing the difference between current innodb rows stats and the ones recorded at the beginning of the test
-# Requirements: Having @[master|slave]_[system_]rows_[read|inserted|deleted|updated] counters already created
-#########################################
-
---connection master
-
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @master_rows_read;
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @master_rows_updated;
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @master_rows_deleted;
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @master_rows_inserted;
-
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @master_system_rows_read;
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @master_system_rows_updated;
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @master_system_rows_deleted;
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @master_system_rows_inserted;
-
---sync_slave_with_master
-
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @slave_rows_read;
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @slave_rows_updated;
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @slave_rows_deleted;
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @slave_rows_inserted;
-
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @slave_system_rows_read;
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @slave_system_rows_updated;
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @slave_system_rows_deleted;
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @slave_system_rows_inserted;
-
---connection master
diff --git a/mysql-test/suite/rpl/r/rpl_innodb_bug68220.result b/mysql-test/suite/rpl/r/rpl_innodb_bug68220.result
deleted file mode 100644
index a9c8c6d612f..00000000000
--- a/mysql-test/suite/rpl/r/rpl_innodb_bug68220.result
+++ /dev/null
@@ -1,233 +0,0 @@
-include/master-slave.inc
-[connection master]
-connection master;
-select variable_value into @master_rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select variable_value into @master_rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select variable_value into @master_rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select variable_value into @master_rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select variable_value into @master_system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select variable_value into @master_system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select variable_value into @master_system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select variable_value into @master_system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-connection slave;
-select variable_value into @slave_rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select variable_value into @slave_rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select variable_value into @slave_rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select variable_value into @slave_rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select variable_value into @slave_system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select variable_value into @slave_system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select variable_value into @slave_system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select variable_value into @slave_system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-connection master;
-CREATE DATABASE testdb;
-USE testdb;
-CREATE TABLE testdb.t1 (i int NOT NULL PRIMARY KEY) ENGINE=InnoDB;
-INSERT INTO testdb.t1 VALUES (1);
-connection master;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @master_rows_read;
-@rows_read - @master_rows_read
-0
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @master_rows_updated;
-@rows_updated - @master_rows_updated
-0
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @master_rows_deleted;
-@rows_deleted - @master_rows_deleted
-0
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @master_rows_inserted;
-@rows_inserted - @master_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @master_system_rows_read;
-@system_rows_read - @master_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @master_system_rows_updated;
-@system_rows_updated - @master_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @master_system_rows_deleted;
-@system_rows_deleted - @master_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @master_system_rows_inserted;
-@system_rows_inserted - @master_system_rows_inserted
-0
-connection slave;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @slave_rows_read;
-@rows_read - @slave_rows_read
-0
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @slave_rows_updated;
-@rows_updated - @slave_rows_updated
-0
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @slave_rows_deleted;
-@rows_deleted - @slave_rows_deleted
-0
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @slave_rows_inserted;
-@rows_inserted - @slave_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @slave_system_rows_read;
-@system_rows_read - @slave_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @slave_system_rows_updated;
-@system_rows_updated - @slave_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @slave_system_rows_deleted;
-@system_rows_deleted - @slave_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @slave_system_rows_inserted;
-@system_rows_inserted - @slave_system_rows_inserted
-0
-connection master;
-UPDATE t1 SET i=2 WHERE i=1;
-connection slave;
-connection master;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @master_rows_read;
-@rows_read - @master_rows_read
-1
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @master_rows_updated;
-@rows_updated - @master_rows_updated
-1
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @master_rows_deleted;
-@rows_deleted - @master_rows_deleted
-0
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @master_rows_inserted;
-@rows_inserted - @master_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @master_system_rows_read;
-@system_rows_read - @master_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @master_system_rows_updated;
-@system_rows_updated - @master_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @master_system_rows_deleted;
-@system_rows_deleted - @master_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @master_system_rows_inserted;
-@system_rows_inserted - @master_system_rows_inserted
-0
-connection slave;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @slave_rows_read;
-@rows_read - @slave_rows_read
-1
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @slave_rows_updated;
-@rows_updated - @slave_rows_updated
-1
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @slave_rows_deleted;
-@rows_deleted - @slave_rows_deleted
-0
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @slave_rows_inserted;
-@rows_inserted - @slave_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @slave_system_rows_read;
-@system_rows_read - @slave_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @slave_system_rows_updated;
-@system_rows_updated - @slave_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @slave_system_rows_deleted;
-@system_rows_deleted - @slave_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @slave_system_rows_inserted;
-@system_rows_inserted - @slave_system_rows_inserted
-0
-connection master;
-DELETE FROM t1 WHERE i=2;
-connection master;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @master_rows_read;
-@rows_read - @master_rows_read
-2
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @master_rows_updated;
-@rows_updated - @master_rows_updated
-1
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @master_rows_deleted;
-@rows_deleted - @master_rows_deleted
-1
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @master_rows_inserted;
-@rows_inserted - @master_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @master_system_rows_read;
-@system_rows_read - @master_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @master_system_rows_updated;
-@system_rows_updated - @master_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @master_system_rows_deleted;
-@system_rows_deleted - @master_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @master_system_rows_inserted;
-@system_rows_inserted - @master_system_rows_inserted
-0
-connection slave;
-select variable_value into @rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select @rows_read - @slave_rows_read;
-@rows_read - @slave_rows_read
-2
-select variable_value into @rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select @rows_updated - @slave_rows_updated;
-@rows_updated - @slave_rows_updated
-1
-select variable_value into @rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select @rows_deleted - @slave_rows_deleted;
-@rows_deleted - @slave_rows_deleted
-1
-select variable_value into @rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select @rows_inserted - @slave_rows_inserted;
-@rows_inserted - @slave_rows_inserted
-1
-select variable_value into @system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select @system_rows_read - @slave_system_rows_read;
-@system_rows_read - @slave_system_rows_read
-0
-select variable_value into @system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select @system_rows_updated - @slave_system_rows_updated;
-@system_rows_updated - @slave_system_rows_updated
-0
-select variable_value into @system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select @system_rows_deleted - @slave_system_rows_deleted;
-@system_rows_deleted - @slave_system_rows_deleted
-0
-select variable_value into @system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-select @system_rows_inserted - @slave_system_rows_inserted;
-@system_rows_inserted - @slave_system_rows_inserted
-0
-connection master;
-DROP TABLE t1;
-DROP DATABASE testdb;
-connection slave;
-include/rpl_end.inc
diff --git a/mysql-test/suite/rpl/t/rpl_innodb_bug68220.test b/mysql-test/suite/rpl/t/rpl_innodb_bug68220.test
deleted file mode 100644
index 1e4f40a0019..00000000000
--- a/mysql-test/suite/rpl/t/rpl_innodb_bug68220.test
+++ /dev/null
@@ -1,53 +0,0 @@
---source include/have_innodb.inc
---source include/have_binlog_format_row.inc
---source include/master-slave.inc
-
-#
-# Bug#68220: innodb_rows_updated is misleading on slave when *info_repository=TABLE
-#
-
-# created all the base variables at the beginning at the test
---connection master
-select variable_value into @master_rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select variable_value into @master_rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select variable_value into @master_rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select variable_value into @master_rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select variable_value into @master_system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select variable_value into @master_system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select variable_value into @master_system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select variable_value into @master_system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-
---connection slave
-select variable_value into @slave_rows_read from information_schema.global_status where variable_name = 'innodb_rows_read';
-select variable_value into @slave_rows_updated from information_schema.global_status where variable_name = 'innodb_rows_updated';
-select variable_value into @slave_rows_deleted from information_schema.global_status where variable_name = 'innodb_rows_deleted';
-select variable_value into @slave_rows_inserted from information_schema.global_status where variable_name = 'innodb_rows_inserted';
-select variable_value into @slave_system_rows_read from information_schema.global_status where variable_name = 'innodb_system_rows_read';
-select variable_value into @slave_system_rows_updated from information_schema.global_status where variable_name = 'innodb_system_rows_updated';
-select variable_value into @slave_system_rows_deleted from information_schema.global_status where variable_name = 'innodb_system_rows_deleted';
-select variable_value into @slave_system_rows_inserted from information_schema.global_status where variable_name = 'innodb_system_rows_inserted';
-
---connection master
-CREATE DATABASE testdb;
-USE testdb;
-CREATE TABLE testdb.t1 (i int NOT NULL PRIMARY KEY) ENGINE=InnoDB;
-
-# insert a row and show counters on master and slave
-INSERT INTO testdb.t1 VALUES (1);
---source suite/rpl/include/rpl_innodb_rows_counters.inc
-
-# update the row and show counters on master and slave
-UPDATE t1 SET i=2 WHERE i=1;
---sync_slave_with_master
---source suite/rpl/include/rpl_innodb_rows_counters.inc
-
-# delete the row and show counters on master and slave
-DELETE FROM t1 WHERE i=2;
---source suite/rpl/include/rpl_innodb_rows_counters.inc
-
-# clean the test
-DROP TABLE t1;
-DROP DATABASE testdb;
---sync_slave_with_master
-
---source include/rpl_end.inc
diff --git a/mysql-test/suite/sys_vars/r/allow_suspicious_udfs.result b/mysql-test/suite/sys_vars/r/allow_suspicious_udfs.result
new file mode 100644
index 00000000000..db0b4749e69
--- /dev/null
+++ b/mysql-test/suite/sys_vars/r/allow_suspicious_udfs.result
@@ -0,0 +1,11 @@
+#
+# MDEV-24815 Show "--allow-suspicious-udfs" state in SYSTEM VARIABLES
+#
+SELECT @@allow_suspicious_udfs AS EXPECT_0;
+EXPECT_0
+0
+# restart: --allow-suspicious-udfs
+SELECT @@allow_suspicious_udfs AS EXPECT_1;
+EXPECT_1
+1
+# restart: --skip-allow-suspicious-udfs
diff --git a/mysql-test/suite/sys_vars/r/innodb_prefix_index_cluster_optimization_basic.result b/mysql-test/suite/sys_vars/r/innodb_prefix_index_cluster_optimization_basic.result
deleted file mode 100644
index 57b653bcf5e..00000000000
--- a/mysql-test/suite/sys_vars/r/innodb_prefix_index_cluster_optimization_basic.result
+++ /dev/null
@@ -1,122 +0,0 @@
-SET @start_global_value = @@global.innodb_prefix_index_cluster_optimization;
-SELECT @start_global_value;
-@start_global_value
-0
-#
-# exists as global only
-#
-Valid values are 'ON' and 'OFF'
-select @@global.innodb_prefix_index_cluster_optimization in (0, 1);
-@@global.innodb_prefix_index_cluster_optimization in (0, 1)
-1
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-0
-select @@session.innodb_prefix_index_cluster_optimization;
-ERROR HY000: Variable 'innodb_prefix_index_cluster_optimization' is a GLOBAL variable
-show global variables like 'innodb_prefix_index_cluster_optimization';
-Variable_name Value
-innodb_prefix_index_cluster_optimization OFF
-show session variables like 'innodb_prefix_index_cluster_optimization';
-Variable_name Value
-innodb_prefix_index_cluster_optimization OFF
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-#
-# show that it's writable
-#
-set global innodb_prefix_index_cluster_optimization = 'OFF';
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-0
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-set @@global.innodb_prefix_index_cluster_optimization = 'ON';
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-1
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-set global innodb_prefix_index_cluster_optimization = 0;
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-0
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION OFF
-set @@global.innodb_prefix_index_cluster_optimization = 1;
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-1
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-set session innodb_prefix_index_cluster_optimization = 'OFF';
-ERROR HY000: Variable 'innodb_prefix_index_cluster_optimization' is a GLOBAL variable and should be set with SET GLOBAL
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-1
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-set @@session.innodb_prefix_index_cluster_optimization = 'ON';
-ERROR HY000: Variable 'innodb_prefix_index_cluster_optimization' is a GLOBAL variable and should be set with SET GLOBAL
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-1
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-#
-# incorrect types
-#
-set global innodb_prefix_index_cluster_optimization = 1.1;
-ERROR 42000: Incorrect argument type to variable 'innodb_prefix_index_cluster_optimization'
-set global innodb_prefix_index_cluster_optimization = 1e1;
-ERROR 42000: Incorrect argument type to variable 'innodb_prefix_index_cluster_optimization'
-set global innodb_prefix_index_cluster_optimization = 2;
-ERROR 42000: Variable 'innodb_prefix_index_cluster_optimization' can't be set to the value of '2'
-set global innodb_prefix_index_cluster_optimization = -3;
-ERROR 42000: Variable 'innodb_prefix_index_cluster_optimization' can't be set to the value of '-3'
-select @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-1
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-VARIABLE_NAME VARIABLE_VALUE
-INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION ON
-set global innodb_prefix_index_cluster_optimization = 'AUTO';
-ERROR 42000: Variable 'innodb_prefix_index_cluster_optimization' can't be set to the value of 'AUTO'
-#
-# Cleanup
-#
-SET @@global.innodb_prefix_index_cluster_optimization = @start_global_value;
-SELECT @@global.innodb_prefix_index_cluster_optimization;
-@@global.innodb_prefix_index_cluster_optimization
-0
diff --git a/mysql-test/suite/sys_vars/r/innodb_version_basic.result b/mysql-test/suite/sys_vars/r/innodb_version_basic.result
deleted file mode 100644
index 759b5048512..00000000000
--- a/mysql-test/suite/sys_vars/r/innodb_version_basic.result
+++ /dev/null
@@ -1,17 +0,0 @@
-select @@global.innodb_version;
-@@global.innodb_version
-x.y.z
-select @@session.innodb_version;
-ERROR HY000: Variable 'innodb_version' is a GLOBAL variable
-show global variables like 'innodb_version' disabled so to not change with every version;
-show session variables like 'innodb_version' disabled so to not change with every version;
-select VARIABLE_VALUE=@@global.innodb_version from information_schema.global_variables where variable_name='innodb_version';
-VARIABLE_VALUE=@@global.innodb_version
-1
-select VARIABLE_VALUE=@@global.innodb_version from information_schema.session_variables where variable_name='innodb_version';
-VARIABLE_VALUE=@@global.innodb_version
-1
-set global innodb_version=1;
-ERROR HY000: Variable 'innodb_version' is a read only variable
-set session innodb_version=1;
-ERROR HY000: Variable 'innodb_version' is a read only variable
diff --git a/mysql-test/suite/sys_vars/r/sysvars_innodb.result b/mysql-test/suite/sys_vars/r/sysvars_innodb.result
index 8b95878c347..42803695813 100644
--- a/mysql-test/suite/sys_vars/r/sysvars_innodb.result
+++ b/mysql-test/suite/sys_vars/r/sysvars_innodb.result
@@ -1,7 +1,6 @@
select VARIABLE_NAME, SESSION_VALUE, DEFAULT_VALUE, VARIABLE_SCOPE, VARIABLE_TYPE, VARIABLE_COMMENT, NUMERIC_MIN_VALUE, NUMERIC_MAX_VALUE, NUMERIC_BLOCK_SIZE, ENUM_VALUE_LIST, READ_ONLY, COMMAND_LINE_ARGUMENT from information_schema.system_variables
where variable_name like 'innodb%' and
variable_name not in (
-'innodb_version', # always the same as the server version
'innodb_numa_interleave', # only available WITH_NUMA
'innodb_evict_tables_on_commit_debug', # one may want to override this
'innodb_use_native_aio', # default value depends on OS
@@ -1258,10 +1257,10 @@ READ_ONLY YES
COMMAND_LINE_ARGUMENT OPTIONAL
VARIABLE_NAME INNODB_PREFIX_INDEX_CLUSTER_OPTIMIZATION
SESSION_VALUE NULL
-DEFAULT_VALUE OFF
+DEFAULT_VALUE ON
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BOOLEAN
-VARIABLE_COMMENT Enable prefix optimization to sometimes avoid cluster index lookups.
+VARIABLE_COMMENT Deprecated parameter with no effect
NUMERIC_MIN_VALUE NULL
NUMERIC_MAX_VALUE NULL
NUMERIC_BLOCK_SIZE NULL
diff --git a/mysql-test/suite/sys_vars/r/sysvars_server_embedded.result b/mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
index 906da9edace..d8a76f6719d 100644
--- a/mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
+++ b/mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
@@ -12,6 +12,16 @@ variable_name not in (
'log_tc_size','have_sanitizer'
)
order by variable_name;
+VARIABLE_NAME ALLOW_SUSPICIOUS_UDFS
+VARIABLE_SCOPE GLOBAL
+VARIABLE_TYPE BOOLEAN
+VARIABLE_COMMENT Allows use of user-defined functions (UDFs) consisting of only one symbol xxx() without corresponding xxx_init() or xxx_deinit(). That also means that one can load any function from any library, for example exit() from libc.so
+NUMERIC_MIN_VALUE NULL
+NUMERIC_MAX_VALUE NULL
+NUMERIC_BLOCK_SIZE NULL
+ENUM_VALUE_LIST OFF,ON
+READ_ONLY YES
+COMMAND_LINE_ARGUMENT OPTIONAL
VARIABLE_NAME ALTER_ALGORITHM
VARIABLE_SCOPE SESSION
VARIABLE_TYPE ENUM
@@ -3082,6 +3092,16 @@ NUMERIC_BLOCK_SIZE NULL
ENUM_VALUE_LIST OFF,ON
READ_ONLY YES
COMMAND_LINE_ARGUMENT NULL
+VARIABLE_NAME SKIP_GRANT_TABLES
+VARIABLE_SCOPE GLOBAL
+VARIABLE_TYPE BOOLEAN
+VARIABLE_COMMENT Start without grant tables. This gives all users FULL ACCESS to all tables.
+NUMERIC_MIN_VALUE NULL
+NUMERIC_MAX_VALUE NULL
+NUMERIC_BLOCK_SIZE NULL
+ENUM_VALUE_LIST OFF,ON
+READ_ONLY YES
+COMMAND_LINE_ARGUMENT OPTIONAL
VARIABLE_NAME SKIP_NAME_RESOLVE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BOOLEAN
diff --git a/mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result b/mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result
index b9444a92cbe..27f15844b33 100644
--- a/mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result
+++ b/mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result
@@ -12,6 +12,16 @@ variable_name not in (
'log_tc_size','have_sanitizer'
)
order by variable_name;
+VARIABLE_NAME ALLOW_SUSPICIOUS_UDFS
+VARIABLE_SCOPE GLOBAL
+VARIABLE_TYPE BOOLEAN
+VARIABLE_COMMENT Allows use of user-defined functions (UDFs) consisting of only one symbol xxx() without corresponding xxx_init() or xxx_deinit(). That also means that one can load any function from any library, for example exit() from libc.so
+NUMERIC_MIN_VALUE NULL
+NUMERIC_MAX_VALUE NULL
+NUMERIC_BLOCK_SIZE NULL
+ENUM_VALUE_LIST OFF,ON
+READ_ONLY YES
+COMMAND_LINE_ARGUMENT OPTIONAL
VARIABLE_NAME ALTER_ALGORITHM
VARIABLE_SCOPE SESSION
VARIABLE_TYPE ENUM
@@ -3582,6 +3592,16 @@ NUMERIC_BLOCK_SIZE NULL
ENUM_VALUE_LIST OFF,ON
READ_ONLY YES
COMMAND_LINE_ARGUMENT NULL
+VARIABLE_NAME SKIP_GRANT_TABLES
+VARIABLE_SCOPE GLOBAL
+VARIABLE_TYPE BOOLEAN
+VARIABLE_COMMENT Start without grant tables. This gives all users FULL ACCESS to all tables.
+NUMERIC_MIN_VALUE NULL
+NUMERIC_MAX_VALUE NULL
+NUMERIC_BLOCK_SIZE NULL
+ENUM_VALUE_LIST OFF,ON
+READ_ONLY YES
+COMMAND_LINE_ARGUMENT OPTIONAL
VARIABLE_NAME SKIP_NAME_RESOLVE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BOOLEAN
diff --git a/mysql-test/suite/sys_vars/r/sysvars_star.result b/mysql-test/suite/sys_vars/r/sysvars_star.result
index 54af0aa3014..b8a49a089b4 100644
--- a/mysql-test/suite/sys_vars/r/sysvars_star.result
+++ b/mysql-test/suite/sys_vars/r/sysvars_star.result
@@ -60,7 +60,7 @@ VARIABLE_NAME PLUGIN_MATURITY
SESSION_VALUE NULL
GLOBAL_VALUE alpha
GLOBAL_VALUE_ORIGIN CONFIG
-DEFAULT_VALUE beta
+DEFAULT_VALUE experimental
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE ENUM
VARIABLE_COMMENT The lowest desirable plugin maturity. Plugins less mature than that will not be installed or loaded
diff --git a/mysql-test/suite/sys_vars/t/allow_suspicious_udfs.test b/mysql-test/suite/sys_vars/t/allow_suspicious_udfs.test
new file mode 100644
index 00000000000..9179cfbef4d
--- /dev/null
+++ b/mysql-test/suite/sys_vars/t/allow_suspicious_udfs.test
@@ -0,0 +1,14 @@
+--echo #
+--echo # MDEV-24815 Show "--allow-suspicious-udfs" state in SYSTEM VARIABLES
+--echo #
+
+SELECT @@allow_suspicious_udfs AS EXPECT_0;
+
+# Restart the server the server with "--allow-suspicious-udfs" option
+--let $restart_parameters = "--allow-suspicious-udfs"
+--source include/restart_mysqld.inc
+SELECT @@allow_suspicious_udfs AS EXPECT_1;
+
+# Disable "--allow-suspicious-udfs" to restore the original state
+--let $restart_parameters = "--skip-allow-suspicious-udfs"
+--source include/restart_mysqld.inc
diff --git a/mysql-test/suite/sys_vars/t/innodb_prefix_index_cluster_optimization_basic.test b/mysql-test/suite/sys_vars/t/innodb_prefix_index_cluster_optimization_basic.test
deleted file mode 100644
index 4e272fbd9c5..00000000000
--- a/mysql-test/suite/sys_vars/t/innodb_prefix_index_cluster_optimization_basic.test
+++ /dev/null
@@ -1,76 +0,0 @@
---source include/have_innodb.inc
-
-SET @start_global_value = @@global.innodb_prefix_index_cluster_optimization;
-SELECT @start_global_value;
-
---echo #
---echo # exists as global only
---echo #
-
---echo Valid values are 'ON' and 'OFF'
-select @@global.innodb_prefix_index_cluster_optimization in (0, 1);
-select @@global.innodb_prefix_index_cluster_optimization;
---error ER_INCORRECT_GLOBAL_LOCAL_VAR
-select @@session.innodb_prefix_index_cluster_optimization;
-show global variables like 'innodb_prefix_index_cluster_optimization';
-show session variables like 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-
---echo #
---echo # show that it's writable
---echo #
-
-set global innodb_prefix_index_cluster_optimization = 'OFF';
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-set @@global.innodb_prefix_index_cluster_optimization = 'ON';
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-set global innodb_prefix_index_cluster_optimization = 0;
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-set @@global.innodb_prefix_index_cluster_optimization = 1;
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-
---error ER_GLOBAL_VARIABLE
-set session innodb_prefix_index_cluster_optimization = 'OFF';
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-
---error ER_GLOBAL_VARIABLE
-set @@session.innodb_prefix_index_cluster_optimization = 'ON';
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-
---echo #
---echo # incorrect types
---echo #
-
---error ER_WRONG_TYPE_FOR_VAR
-set global innodb_prefix_index_cluster_optimization = 1.1;
---error ER_WRONG_TYPE_FOR_VAR
-set global innodb_prefix_index_cluster_optimization = 1e1;
---error ER_WRONG_VALUE_FOR_VAR
-set global innodb_prefix_index_cluster_optimization = 2;
---error ER_WRONG_VALUE_FOR_VAR
-set global innodb_prefix_index_cluster_optimization = -3;
-select @@global.innodb_prefix_index_cluster_optimization;
-select * from information_schema.global_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
-select * from information_schema.session_variables where variable_name = 'innodb_prefix_index_cluster_optimization';
---error ER_WRONG_VALUE_FOR_VAR
-set global innodb_prefix_index_cluster_optimization = 'AUTO';
-
---echo #
---echo # Cleanup
---echo #
-
-SET @@global.innodb_prefix_index_cluster_optimization = @start_global_value;
-SELECT @@global.innodb_prefix_index_cluster_optimization;
diff --git a/mysql-test/suite/sys_vars/t/innodb_version_basic.test b/mysql-test/suite/sys_vars/t/innodb_version_basic.test
deleted file mode 100644
index 182841048f7..00000000000
--- a/mysql-test/suite/sys_vars/t/innodb_version_basic.test
+++ /dev/null
@@ -1,30 +0,0 @@
-
-#
-# 2010-01-27 OBN - Added
-#
-
---source include/have_innodb.inc
-
-#
-# show the global and session values;
-#
---let $inno_ver= `select @@global.innodb_version`
---replace_result $inno_ver x.y.z
-select @@global.innodb_version;
---error ER_INCORRECT_GLOBAL_LOCAL_VAR
-select @@session.innodb_version;
---echo show global variables like 'innodb_version' disabled so to not change with every version;
---echo show session variables like 'innodb_version' disabled so to not change with every version;
---disable_warnings
-select VARIABLE_VALUE=@@global.innodb_version from information_schema.global_variables where variable_name='innodb_version';
-select VARIABLE_VALUE=@@global.innodb_version from information_schema.session_variables where variable_name='innodb_version';
---enable_warnings
-
-#
-# show that it's read-only
-#
---error ER_INCORRECT_GLOBAL_LOCAL_VAR
-set global innodb_version=1;
---error ER_INCORRECT_GLOBAL_LOCAL_VAR
-set session innodb_version=1;
-
diff --git a/mysql-test/suite/sys_vars/t/sysvars_innodb.test b/mysql-test/suite/sys_vars/t/sysvars_innodb.test
index 6d46c22683f..2680e442da4 100644
--- a/mysql-test/suite/sys_vars/t/sysvars_innodb.test
+++ b/mysql-test/suite/sys_vars/t/sysvars_innodb.test
@@ -8,7 +8,6 @@
select VARIABLE_NAME, SESSION_VALUE, DEFAULT_VALUE, VARIABLE_SCOPE, VARIABLE_TYPE, VARIABLE_COMMENT, NUMERIC_MIN_VALUE, NUMERIC_MAX_VALUE, NUMERIC_BLOCK_SIZE, ENUM_VALUE_LIST, READ_ONLY, COMMAND_LINE_ARGUMENT from information_schema.system_variables
where variable_name like 'innodb%' and
variable_name not in (
- 'innodb_version', # always the same as the server version
'innodb_numa_interleave', # only available WITH_NUMA
'innodb_evict_tables_on_commit_debug', # one may want to override this
'innodb_use_native_aio', # default value depends on OS
diff --git a/sql/mysqld.cc b/sql/mysqld.cc
index 9a64fbf2c52..1e30d8f3644 100644
--- a/sql/mysqld.cc
+++ b/sql/mysqld.cc
@@ -6342,13 +6342,6 @@ struct my_option my_long_options[]=
{"help", '?', "Display this help and exit.",
&opt_help, &opt_help, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0,
0, 0},
- {"allow-suspicious-udfs", 0,
- "Allows use of UDFs consisting of only one symbol xxx() "
- "without corresponding xxx_init() or xxx_deinit(). That also means "
- "that one can load any function from any library, for example exit() "
- "from libc.so",
- &opt_allow_suspicious_udfs, &opt_allow_suspicious_udfs,
- 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
{"ansi", 'a', "Use ANSI SQL syntax instead of MySQL syntax. This mode "
"will also set transaction isolation level 'serializable'.", 0, 0, 0,
GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
@@ -6673,12 +6666,6 @@ struct my_option my_long_options[]=
GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
{"silent-startup", OPT_SILENT, "Don't print [Note] to the error log during startup.",
&opt_silent_startup, &opt_silent_startup, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
-#ifndef DISABLE_GRANT_OPTIONS
- {"skip-grant-tables", 0,
- "Start without grant tables. This gives all users FULL ACCESS to all tables.",
- &opt_noacl, &opt_noacl, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0,
- 0},
-#endif
{"skip-host-cache", OPT_SKIP_HOST_CACHE, "Don't cache host names.", 0, 0, 0,
GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"skip-slave-start", 0,
diff --git a/sql/sys_vars.cc b/sql/sys_vars.cc
index eb8137c26a8..cd0fb5967dc 100644
--- a/sql/sys_vars.cc
+++ b/sql/sys_vars.cc
@@ -2679,6 +2679,20 @@ static Sys_var_mybool Sys_old_mode(
SESSION_VAR(old_mode), CMD_LINE(OPT_ARG), DEFAULT(FALSE), 0, NOT_IN_BINLOG, ON_CHECK(0),
ON_UPDATE(set_old_mode), DEPRECATED("'@@old_mode'"));
+static Sys_var_mybool Sys_opt_allow_suspicious_udfs(
+ "allow_suspicious_udfs",
+ "Allows use of user-defined functions (UDFs) consisting of only one symbol xxx() without corresponding xxx_init() or xxx_deinit(). That also means that one can load any function from any library, for example exit() from libc.so",
+ READ_ONLY GLOBAL_VAR(opt_allow_suspicious_udfs),
+ CMD_LINE(OPT_ARG), DEFAULT(FALSE));
+
+#ifndef DISABLE_GRANT_OPTIONS
+static Sys_var_mybool Sys_skip_grant_tables(
+ "skip_grant_tables",
+ "Start without grant tables. This gives all users FULL ACCESS to all tables.",
+ READ_ONLY GLOBAL_VAR(opt_noacl),
+ CMD_LINE(OPT_ARG), DEFAULT(FALSE));
+#endif
+
static const char *alter_algorithm_modes[]= {"DEFAULT", "COPY", "INPLACE",
"NOCOPY", "INSTANT", NULL};
diff --git a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc
index 4cf34d4f0e0..e8a8e813c25 100644
--- a/storage/innobase/handler/ha_innodb.cc
+++ b/storage/innobase/handler/ha_innodb.cc
@@ -202,8 +202,6 @@ static my_bool innobase_create_status_file;
my_bool innobase_stats_on_metadata;
static my_bool innodb_optimize_fulltext_only;
-static char* innodb_version_str = (char*) INNODB_VERSION_STR;
-
extern uint srv_fil_crypt_rotate_key_age;
extern uint srv_n_fil_crypt_iops;
@@ -900,6 +898,8 @@ static MYSQL_THDVAR_STR(tmpdir,
"Directory for temporary non-tablespace files.",
innodb_tmpdir_validate, NULL, NULL);
+static size_t truncated_status_writes;
+
static SHOW_VAR innodb_status_variables[]= {
#ifdef BTR_CUR_HASH_ADAPT
{"adaptive_hash_hash_searches", &export_vars.innodb_ahi_hit, SHOW_SIZE_T},
@@ -1008,19 +1008,8 @@ static SHOW_VAR innodb_status_variables[]= {
{"row_lock_time_avg", &export_vars.innodb_row_lock_time_avg, SHOW_SIZE_T},
{"row_lock_time_max", &export_vars.innodb_row_lock_time_max, SHOW_SIZE_T},
{"row_lock_waits", &export_vars.innodb_row_lock_waits, SHOW_SIZE_T},
- {"rows_deleted", &export_vars.innodb_rows_deleted, SHOW_SIZE_T},
- {"rows_inserted", &export_vars.innodb_rows_inserted, SHOW_SIZE_T},
- {"rows_read", &export_vars.innodb_rows_read, SHOW_SIZE_T},
- {"rows_updated", &export_vars.innodb_rows_updated, SHOW_SIZE_T},
- {"system_rows_deleted", &export_vars.innodb_system_rows_deleted,SHOW_SIZE_T},
- {"system_rows_inserted", &export_vars.innodb_system_rows_inserted,
- SHOW_SIZE_T},
- {"system_rows_read", &export_vars.innodb_system_rows_read, SHOW_SIZE_T},
- {"system_rows_updated", &export_vars.innodb_system_rows_updated,
- SHOW_SIZE_T},
{"num_open_files", &fil_system.n_open, SHOW_SIZE_T},
- {"truncated_status_writes", &export_vars.innodb_truncated_status_writes,
- SHOW_SIZE_T},
+ {"truncated_status_writes", &truncated_status_writes, SHOW_SIZE_T},
{"available_undo_logs", &srv_available_undo_logs, SHOW_ULONG},
{"undo_truncations", &export_vars.innodb_undo_truncations, SHOW_ULONG},
@@ -1063,13 +1052,6 @@ static SHOW_VAR innodb_status_variables[]= {
{"onlineddl_pct_progress",
&export_vars.innodb_onlineddl_pct_progress, SHOW_SIZE_T},
- /* Times secondary index lookup triggered cluster lookup and
- times prefix optimization avoided triggering cluster lookup */
- {"secondary_index_triggered_cluster_reads",
- &export_vars.innodb_sec_rec_cluster_reads, SHOW_SIZE_T},
- {"secondary_index_triggered_cluster_reads_avoided",
- &export_vars.innodb_sec_rec_cluster_reads_avoided, SHOW_SIZE_T},
-
/* Encryption */
{"encryption_rotation_pages_read_from_cache",
&export_vars.innodb_encryption_rotation_pages_read_from_cache, SHOW_SIZE_T},
@@ -9018,13 +9000,6 @@ ha_innobase::index_read(
case DB_SUCCESS:
error = 0;
table->status = 0;
- if (m_prebuilt->table->is_system_db) {
- srv_stats.n_system_rows_read.add(
- thd_get_thread_id(m_prebuilt->trx->mysql_thd), 1);
- } else {
- srv_stats.n_rows_read.add(
- thd_get_thread_id(m_prebuilt->trx->mysql_thd), 1);
- }
break;
case DB_RECORD_NOT_FOUND:
@@ -9279,13 +9254,6 @@ ha_innobase::general_fetch(
case DB_SUCCESS:
error = 0;
table->status = 0;
- if (m_prebuilt->table->is_system_db) {
- srv_stats.n_system_rows_read.add(
- thd_get_thread_id(trx->mysql_thd), 1);
- } else {
- srv_stats.n_rows_read.add(
- thd_get_thread_id(trx->mysql_thd), 1);
- }
break;
case DB_RECORD_NOT_FOUND:
error = HA_ERR_END_OF_FILE;
@@ -16206,7 +16174,7 @@ innodb_show_status(
if (flen > MAX_STATUS_SIZE) {
usable_len = MAX_STATUS_SIZE;
- srv_truncated_status_writes++;
+ truncated_status_writes++;
} else {
usable_len = flen;
}
@@ -19359,11 +19327,13 @@ static MYSQL_SYSVAR_UINT(spin_wait_delay, srv_spin_wait_delay,
"Maximum delay between polling for a spin lock (4 by default)",
NULL, NULL, 4, 0, 6000, 0);
+static my_bool innodb_prefix_index_cluster_optimization;
+
static MYSQL_SYSVAR_BOOL(prefix_index_cluster_optimization,
- srv_prefix_index_cluster_optimization,
- PLUGIN_VAR_OPCMDARG,
- "Enable prefix optimization to sometimes avoid cluster index lookups.",
- NULL, NULL, FALSE);
+ innodb_prefix_index_cluster_optimization,
+ PLUGIN_VAR_OPCMDARG | PLUGIN_VAR_DEPRECATED,
+ "Deprecated parameter with no effect",
+ nullptr, nullptr, TRUE);
static MYSQL_SYSVAR_STR(data_file_path, innobase_data_file_path,
PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
@@ -19418,10 +19388,6 @@ static MYSQL_SYSVAR_LONG(autoinc_lock_mode, innobase_autoinc_lock_mode,
AUTOINC_OLD_STYLE_LOCKING, /* Minimum value */
AUTOINC_NO_LOCKING, 0); /* Maximum value */
-static MYSQL_SYSVAR_STR(version, innodb_version_str,
- PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_READONLY,
- "InnoDB version", NULL, NULL, INNODB_VERSION_STR);
-
#ifdef HAVE_URING
# include <sys/utsname.h>
static utsname uname_for_io_uring;
@@ -19815,7 +19781,6 @@ static struct st_mysql_sys_var* innobase_system_variables[]= {
MYSQL_SYSVAR(prefix_index_cluster_optimization),
MYSQL_SYSVAR(tmpdir),
MYSQL_SYSVAR(autoinc_lock_mode),
- MYSQL_SYSVAR(version),
MYSQL_SYSVAR(use_native_aio),
#ifdef HAVE_LIBNUMA
MYSQL_SYSVAR(numa_interleave),
@@ -19895,10 +19860,10 @@ maria_declare_plugin(innobase)
PLUGIN_LICENSE_GPL,
innodb_init, /* Plugin Init */
NULL, /* Plugin Deinit */
- INNODB_VERSION_SHORT,
+ MYSQL_VERSION_MAJOR << 8 | MYSQL_VERSION_MINOR,
innodb_status_variables_export,/* status variables */
innobase_system_variables, /* system variables */
- INNODB_VERSION_STR, /* string version */
+ PACKAGE_VERSION,
MariaDB_PLUGIN_MATURITY_STABLE /* maturity */
},
i_s_innodb_trx,
diff --git a/storage/innobase/handler/i_s.cc b/storage/innobase/handler/i_s.cc
index 0a00b29a90b..5342bb9fd1e 100644
--- a/storage/innobase/handler/i_s.cc
+++ b/storage/innobase/handler/i_s.cc
@@ -512,6 +512,9 @@ static struct st_mysql_information_schema i_s_info =
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION
};
+/** version number reported by SHOW PLUGINS */
+constexpr unsigned i_s_version= MYSQL_VERSION_MAJOR << 8 | MYSQL_VERSION_MINOR;
+
struct st_maria_plugin i_s_innodb_trx =
{
/* the plugin type (a MYSQL_XXX_PLUGIN value) */
@@ -546,19 +549,8 @@ struct st_maria_plugin i_s_innodb_trx =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
static const LEX_CSTRING lock_mode_values[] =
@@ -761,19 +753,8 @@ struct st_maria_plugin i_s_innodb_locks =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -915,19 +896,8 @@ struct st_maria_plugin i_s_innodb_lock_waits =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
/*******************************************************************//**
@@ -1203,19 +1173,8 @@ struct st_maria_plugin i_s_innodb_cmp =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
struct st_maria_plugin i_s_innodb_cmp_reset =
@@ -1253,19 +1212,8 @@ struct st_maria_plugin i_s_innodb_cmp_reset =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -1509,19 +1457,8 @@ struct st_maria_plugin i_s_innodb_cmp_per_index =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
struct st_maria_plugin i_s_innodb_cmp_per_index_reset =
@@ -1559,19 +1496,8 @@ struct st_maria_plugin i_s_innodb_cmp_per_index_reset =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -1754,19 +1680,8 @@ struct st_maria_plugin i_s_innodb_cmpmem =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
struct st_maria_plugin i_s_innodb_cmpmem_reset =
@@ -1804,19 +1719,8 @@ struct st_maria_plugin i_s_innodb_cmpmem_reset =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -2236,19 +2140,8 @@ struct st_maria_plugin i_s_innodb_metrics =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -2345,19 +2238,8 @@ struct st_maria_plugin i_s_innodb_ft_default_stopword =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -2514,19 +2396,8 @@ struct st_maria_plugin i_s_innodb_ft_deleted =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
/*******************************************************************//**
@@ -2597,19 +2468,8 @@ struct st_maria_plugin i_s_innodb_ft_being_deleted =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -2860,19 +2720,8 @@ struct st_maria_plugin i_s_innodb_ft_index_cache =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
/*******************************************************************//**
@@ -3290,19 +3139,8 @@ struct st_maria_plugin i_s_innodb_ft_index_table =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -3483,19 +3321,8 @@ struct st_maria_plugin i_s_innodb_ft_config =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -3783,19 +3610,8 @@ struct st_maria_plugin i_s_innodb_buffer_stats =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
/** These must correspond to the first values of buf_page_state */
@@ -4319,19 +4135,8 @@ struct st_maria_plugin i_s_innodb_buffer_page =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -4672,19 +4477,8 @@ struct st_maria_plugin i_s_innodb_buffer_page_lru =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
/*******************************************************************//**
@@ -4960,19 +4754,8 @@ struct st_maria_plugin i_s_innodb_sys_tables =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -5206,19 +4989,8 @@ struct st_maria_plugin i_s_innodb_sys_tablestats =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -5445,19 +5217,8 @@ struct st_maria_plugin i_s_innodb_sys_indexes =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -5658,19 +5419,8 @@ struct st_maria_plugin i_s_innodb_sys_columns =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -5845,19 +5595,8 @@ struct st_maria_plugin i_s_innodb_sys_virtual =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
@@ -6040,19 +5779,8 @@ struct st_maria_plugin i_s_innodb_sys_fields =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -6236,19 +5964,8 @@ struct st_maria_plugin i_s_innodb_sys_foreign =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -6432,19 +6149,8 @@ struct st_maria_plugin i_s_innodb_sys_foreign_cols =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -6638,19 +6344,8 @@ struct st_maria_plugin i_s_innodb_sys_tablespaces =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
- MariaDB_PLUGIN_MATURITY_STABLE,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
+ MariaDB_PLUGIN_MATURITY_STABLE
};
namespace Show {
@@ -6865,17 +6560,6 @@ struct st_maria_plugin i_s_innodb_tablespaces_encryption =
/* int (*)(void*); */
i_s_common_deinit,
- /* plugin version (for SHOW PLUGINS) */
- /* unsigned int */
- INNODB_VERSION_SHORT,
-
- /* struct st_mysql_show_var* */
- NULL,
-
- /* struct st_mysql_sys_var** */
- NULL,
-
- /* Maria extension */
- INNODB_VERSION_STR,
+ i_s_version, nullptr, nullptr, PACKAGE_VERSION,
MariaDB_PLUGIN_MATURITY_STABLE
};
diff --git a/storage/innobase/ibuf/ibuf0ibuf.cc b/storage/innobase/ibuf/ibuf0ibuf.cc
index e1d08a49aef..031fe8a321c 100644
--- a/storage/innobase/ibuf/ibuf0ibuf.cc
+++ b/storage/innobase/ibuf/ibuf0ibuf.cc
@@ -1207,6 +1207,7 @@ static
void
ibuf_print_ops(
/*===========*/
+ const char* op_name,/*!< in: operation name */
const Atomic_counter<ulint>* ops, /*!< in: operation counts */
FILE* file) /*!< in: file where to print */
{
@@ -1215,11 +1216,11 @@ ibuf_print_ops(
"delete mark",
"delete"
};
- ulint i;
- ut_a(UT_ARR_SIZE(op_names) == IBUF_OP_COUNT);
+ static_assert(array_elements(op_names) == IBUF_OP_COUNT, "");
+ fputs(op_name, file);
- for (i = 0; i < IBUF_OP_COUNT; i++) {
+ for (ulint i = 0; i < IBUF_OP_COUNT; i++) {
fprintf(file, "%s " ULINTPF "%s", op_names[i],
ulint{ops[i]}, (i < (IBUF_OP_COUNT - 1)) ? ", " : "");
}
@@ -4565,23 +4566,28 @@ ibuf_print(
/*=======*/
FILE* file) /*!< in: file where to print */
{
- mysql_mutex_lock(&ibuf_mutex);
-
- fprintf(file,
- "Ibuf: size " ULINTPF ", free list len " ULINTPF ","
- " seg size " ULINTPF ", " ULINTPF " merges\n",
- ibuf.size,
- ibuf.free_list_len,
- ibuf.seg_size,
- ulint{ibuf.n_merges});
-
- fputs("merged operations:\n ", file);
- ibuf_print_ops(ibuf.n_merged_ops, file);
- fputs("discarded operations:\n ", file);
- ibuf_print_ops(ibuf.n_discarded_ops, file);
+ mysql_mutex_lock(&ibuf_mutex);
+ if (ibuf.empty)
+ {
+ mysql_mutex_unlock(&ibuf_mutex);
+ return;
+ }
- mysql_mutex_unlock(&ibuf_mutex);
+ const ulint size= ibuf.size;
+ const ulint free_list_len= ibuf.free_list_len;
+ const ulint seg_size= ibuf.seg_size;
+ mysql_mutex_unlock(&ibuf_mutex);
+
+ fprintf(file,
+ "-------------\n"
+ "INSERT BUFFER\n"
+ "-------------\n"
+ "size " ULINTPF ", free list len " ULINTPF ","
+ " seg size " ULINTPF ", " ULINTPF " merges\n",
+ size, free_list_len, seg_size, ulint{ibuf.n_merges});
+ ibuf_print_ops("merged operations:\n", ibuf.n_merged_ops, file);
+ ibuf_print_ops("discarded operations:\n", ibuf.n_discarded_ops, file);
}
/** Check the insert buffer bitmaps on IMPORT TABLESPACE.
diff --git a/storage/innobase/include/srv0mon.h b/storage/innobase/include/srv0mon.h
index 1ca2d7a429f..51f3049b81a 100644
--- a/storage/innobase/include/srv0mon.h
+++ b/storage/innobase/include/srv0mon.h
@@ -175,8 +175,6 @@ enum monitor_id_t {
MONITOR_OVLD_PAGE_CREATED,
MONITOR_OVLD_PAGES_WRITTEN,
MONITOR_OVLD_PAGES_READ,
- MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS,
- MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS_AVOIDED,
MONITOR_OVLD_BYTE_READ,
MONITOR_OVLD_BYTE_WRITTEN,
MONITOR_FLUSH_BATCH_SCANNED,
@@ -374,17 +372,6 @@ enum monitor_id_t {
MONITOR_OVLD_SRV_DBLWR_PAGES_WRITTEN,
MONITOR_OVLD_SRV_PAGE_SIZE,
- /* Data DML related counters */
- MONITOR_MODULE_DML_STATS,
- MONITOR_OLVD_ROW_READ,
- MONITOR_OLVD_ROW_INSERTED,
- MONITOR_OLVD_ROW_DELETED,
- MONITOR_OLVD_ROW_UPDTATED,
- MONITOR_OLVD_SYSTEM_ROW_READ,
- MONITOR_OLVD_SYSTEM_ROW_INSERTED,
- MONITOR_OLVD_SYSTEM_ROW_DELETED,
- MONITOR_OLVD_SYSTEM_ROW_UPDATED,
-
/* Data DDL related counters */
MONITOR_MODULE_DDL_STATS,
MONITOR_BACKGROUND_DROP_INDEX,
diff --git a/storage/innobase/include/srv0srv.h b/storage/innobase/include/srv0srv.h
index 41f61567b53..cc78696ee77 100644
--- a/storage/innobase/include/srv0srv.h
+++ b/storage/innobase/include/srv0srv.h
@@ -116,36 +116,6 @@ struct srv_stats_t
/** Number of data read in total (in bytes) */
ulint_ctr_1_t data_read;
- /** Number of rows read. */
- ulint_ctr_n_t n_rows_read;
-
- /** Number of rows updated */
- ulint_ctr_n_t n_rows_updated;
-
- /** Number of rows deleted */
- ulint_ctr_n_t n_rows_deleted;
-
- /** Number of rows inserted */
- ulint_ctr_n_t n_rows_inserted;
-
- /** Number of system rows read. */
- ulint_ctr_n_t n_system_rows_read;
-
- /** Number of system rows updated */
- ulint_ctr_n_t n_system_rows_updated;
-
- /** Number of system rows deleted */
- ulint_ctr_n_t n_system_rows_deleted;
-
- /** Number of system rows inserted */
- ulint_ctr_n_t n_system_rows_inserted;
-
- /** Number of times secondary index lookup triggered cluster lookup */
- ulint_ctr_n_t n_sec_rec_cluster_reads;
-
- /** Number of times prefix optimization avoided triggering cluster lookup */
- ulint_ctr_n_t n_sec_rec_cluster_reads_avoided;
-
/** Number of encryption_get_latest_key_version calls */
ulint_ctr_n_t n_key_requests;
@@ -251,10 +221,6 @@ extern ulong srv_purge_rseg_truncate_frequency;
/** Enable or Disable Truncate of UNDO tablespace. */
extern my_bool srv_undo_log_truncate;
-/* Optimize prefix index queries to skip cluster index lookup when possible */
-/* Enables or disables this prefix optimization. Disabled by default. */
-extern my_bool srv_prefix_index_cluster_optimization;
-
/** Default size of UNDO tablespace (10MiB for innodb_page_size=16k) */
constexpr ulint SRV_UNDO_TABLESPACE_SIZE_IN_PAGES= (10U << 20) /
UNIV_PAGE_SIZE_DEF;
@@ -399,7 +365,6 @@ extern bool srv_monitor_active;
extern ulong srv_n_spin_wait_rounds;
extern uint srv_spin_wait_delay;
-extern ulint srv_truncated_status_writes;
/** Number of initialized rollback segments for persistent undo log */
extern ulong srv_available_undo_logs;
/** Iterations of the loop bounded by 'srv_active' label. */
@@ -701,15 +666,6 @@ struct export_var_t{
/ srv_n_lock_wait_count */
ulint innodb_row_lock_time_max; /*!< srv_n_lock_max_wait_time
/ 1000 */
- ulint innodb_rows_read; /*!< srv_n_rows_read */
- ulint innodb_rows_inserted; /*!< srv_n_rows_inserted */
- ulint innodb_rows_updated; /*!< srv_n_rows_updated */
- ulint innodb_rows_deleted; /*!< srv_n_rows_deleted */
- ulint innodb_system_rows_read; /*!< srv_n_system_rows_read */
- ulint innodb_system_rows_inserted; /*!< srv_n_system_rows_inserted */
- ulint innodb_system_rows_updated; /*!< srv_n_system_rows_updated */
- ulint innodb_system_rows_deleted; /*!< srv_n_system_rows_deleted*/
- ulint innodb_truncated_status_writes; /*!< srv_truncated_status_writes */
/** Number of undo tablespace truncation operations */
ulong innodb_undo_truncations;
@@ -761,9 +717,6 @@ struct export_var_t{
/* Number of temporary tablespace pages decrypted */
ib_int64_t innodb_n_temp_blocks_decrypted;
- ulint innodb_sec_rec_cluster_reads; /*!< srv_sec_rec_cluster_reads */
- ulint innodb_sec_rec_cluster_reads_avoided;/*!< srv_sec_rec_cluster_reads_avoided */
-
ulint innodb_encryption_rotation_pages_read_from_cache;
ulint innodb_encryption_rotation_pages_read_from_disk;
ulint innodb_encryption_rotation_pages_modified;
diff --git a/storage/innobase/include/univ.i b/storage/innobase/include/univ.i
index 6dc1d8b7341..e14a54a010d 100644
--- a/storage/innobase/include/univ.i
+++ b/storage/innobase/include/univ.i
@@ -33,25 +33,6 @@ Created 1/20/1994 Heikki Tuuri
#pragma once
-/* aux macros to convert M into "123" (string) if M is defined like
-#define M 123 */
-#define _IB_TO_STR(s) #s
-#define IB_TO_STR(s) _IB_TO_STR(s)
-
-/* The following is the InnoDB version as shown in
-SELECT plugin_version FROM information_schema.plugins;
-calculated in make_version_string() in sql/sql_show.cc like this:
-"version >> 8" . "version & 0xff"
-because the version is shown with only one dot, we skip the last
-component, i.e. we show M.N.P as M.N */
-#define INNODB_VERSION_SHORT \
- (MYSQL_VERSION_MAJOR << 8 | MYSQL_VERSION_MINOR)
-
-#define INNODB_VERSION_STR \
- IB_TO_STR(MYSQL_VERSION_MAJOR) "." \
- IB_TO_STR(MYSQL_VERSION_MINOR) "." \
- IB_TO_STR(MYSQL_VERSION_PATCH)
-
/** How far ahead should we tell the service manager the timeout
(time in seconds) */
#define INNODB_EXTEND_TIMEOUT_INTERVAL 30
diff --git a/storage/innobase/log/log0log.cc b/storage/innobase/log/log0log.cc
index 66576bda977..cdc05e040fb 100644
--- a/storage/innobase/log/log0log.cc
+++ b/storage/innobase/log/log0log.cc
@@ -255,16 +255,18 @@ void log_t::header_write(byte *buf, lsn_t lsn, bool encrypted)
mach_write_to_4(my_assume_aligned<4>(buf) + LOG_HEADER_FORMAT,
log_sys.FORMAT_10_8);
mach_write_to_8(my_assume_aligned<8>(buf + LOG_HEADER_START_LSN), lsn);
- static constexpr const char LOG_HEADER_CREATOR_CURRENT[]=
- "MariaDB "
- IB_TO_STR(MYSQL_VERSION_MAJOR) "."
- IB_TO_STR(MYSQL_VERSION_MINOR) "."
- IB_TO_STR(MYSQL_VERSION_PATCH);
-
- strcpy(reinterpret_cast<char*>(buf) + LOG_HEADER_CREATOR,
- LOG_HEADER_CREATOR_CURRENT);
- static_assert(LOG_HEADER_CREATOR_END - LOG_HEADER_CREATOR >=
- sizeof LOG_HEADER_CREATOR_CURRENT, "compatibility");
+
+#if defined __GNUC__ && __GNUC__ > 7
+# pragma GCC diagnostic push
+# pragma GCC diagnostic ignored "-Wstringop-truncation"
+#endif
+ strncpy(reinterpret_cast<char*>(buf) + LOG_HEADER_CREATOR,
+ "MariaDB " PACKAGE_VERSION,
+ LOG_HEADER_CREATOR_END - LOG_HEADER_CREATOR);
+#if defined __GNUC__ && __GNUC__ > 7
+# pragma GCC diagnostic pop
+#endif
+
if (encrypted)
log_crypt_write_header(buf + LOG_HEADER_CREATOR_END);
mach_write_to_4(my_assume_aligned<4>(508 + buf), my_crc32c(0, buf, 508));
diff --git a/storage/innobase/row/row0mysql.cc b/storage/innobase/row/row0mysql.cc
index 3540882d49e..a04fa3e3e1c 100644
--- a/storage/innobase/row/row0mysql.cc
+++ b/storage/innobase/row/row0mysql.cc
@@ -1384,12 +1384,6 @@ error_exit:
}
}
- if (table->is_system_db) {
- srv_stats.n_system_rows_inserted.inc(size_t(trx->id));
- } else {
- srv_stats.n_rows_inserted.inc(size_t(trx->id));
- }
-
/* Not protected by dict_sys.latch or table->stats_mutex_lock()
for performance
reasons, we would rather get garbage in stat_n_rows (which is
@@ -1735,20 +1729,8 @@ row_update_for_mysql(row_prebuilt_t* prebuilt)
with a latch. */
dict_table_n_rows_dec(prebuilt->table);
- if (table->is_system_db) {
- srv_stats.n_system_rows_deleted.inc(size_t(trx->id));
- } else {
- srv_stats.n_rows_deleted.inc(size_t(trx->id));
- }
-
update_statistics = !srv_stats_include_delete_marked;
} else {
- if (table->is_system_db) {
- srv_stats.n_system_rows_updated.inc(size_t(trx->id));
- } else {
- srv_stats.n_rows_updated.inc(size_t(trx->id));
- }
-
update_statistics
= !(node->cmpl_info & UPD_NODE_NO_ORD_CHANGE);
}
@@ -1961,8 +1943,6 @@ static dberr_t row_update_vers_insert(que_thr_t* thr, upd_node_t* node)
goto exit;
case DB_SUCCESS:
- srv_stats.n_rows_inserted.inc(
- static_cast<size_t>(trx->id));
dict_stats_update_if_needed(table, *trx);
goto exit;
}
@@ -2046,11 +2026,9 @@ row_update_cascade_for_mysql(
dict_table_n_rows_dec(node->table);
stats = !srv_stats_include_delete_marked;
- srv_stats.n_rows_deleted.inc(size_t(trx->id));
} else {
stats = !(node->cmpl_info
& UPD_NODE_NO_ORD_CHANGE);
- srv_stats.n_rows_updated.inc(size_t(trx->id));
}
if (stats) {
diff --git a/storage/innobase/row/row0sel.cc b/storage/innobase/row/row0sel.cc
index d11b29d995f..c81888e6263 100644
--- a/storage/innobase/row/row0sel.cc
+++ b/storage/innobase/row/row0sel.cc
@@ -3344,9 +3344,6 @@ Row_sel_get_clust_rec_for_mysql::operator()(
*out_rec = NULL;
trx = thr_get_trx(thr);
- srv_stats.n_sec_rec_cluster_reads.inc(
- thd_get_thread_id(trx->mysql_thd));
-
row_build_row_ref_in_tuple(prebuilt->clust_ref, rec,
sec_index, *offsets);
@@ -4217,11 +4214,9 @@ bool row_search_with_covering_prefix(
const dict_index_t* index = prebuilt->index;
ut_ad(!dict_index_is_clust(index));
- if (dict_index_is_spatial(index)) {
- return false;
- }
-
- if (!srv_prefix_index_cluster_optimization) {
+ /* In ha_innobase::build_template() we choose to access the
+ whole row when using exclusive row locks. */
+ if (prebuilt->select_lock_type == LOCK_X || !index->is_btree()) {
return false;
}
@@ -4288,7 +4283,6 @@ bool row_search_with_covering_prefix(
ut_a(templ->rec_field_no != ULINT_UNDEFINED);
}
- srv_stats.n_sec_rec_cluster_reads_avoided.inc();
return true;
}
diff --git a/storage/innobase/srv/srv0mon.cc b/storage/innobase/srv/srv0mon.cc
index b2069b11f0f..32dee38c74b 100644
--- a/storage/innobase/srv/srv0mon.cc
+++ b/storage/innobase/srv/srv0mon.cc
@@ -278,18 +278,6 @@ static monitor_info_t innodb_counter_info[] =
MONITOR_EXISTING | MONITOR_DEFAULT_ON),
MONITOR_DEFAULT_START, MONITOR_OVLD_PAGES_READ},
- {"buffer_index_sec_rec_cluster_reads", "buffer",
- "Number of secondary record reads triggered cluster read",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS},
-
- {"buffer_index_sec_rec_cluster_reads_avoided", "buffer",
- "Number of secondary record reads avoided triggering cluster read",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS_AVOIDED},
-
{"buffer_data_reads", "buffer",
"Amount of data read in bytes (innodb_data_reads)",
static_cast<monitor_type_t>(
@@ -1078,50 +1066,6 @@ static monitor_info_t innodb_counter_info[] =
MONITOR_EXISTING | MONITOR_DEFAULT_ON | MONITOR_DISPLAY_CURRENT),
MONITOR_DEFAULT_START, MONITOR_OVLD_SRV_PAGE_SIZE},
- /* ========== Counters for DML operations ========== */
- {"module_dml", "dml", "Statistics for DMLs",
- MONITOR_MODULE,
- MONITOR_DEFAULT_START, MONITOR_MODULE_DML_STATS},
-
- {"dml_reads", "dml", "Number of rows read",
- static_cast<monitor_type_t>(MONITOR_EXISTING),
- MONITOR_DEFAULT_START, MONITOR_OLVD_ROW_READ},
-
- {"dml_inserts", "dml", "Number of rows inserted",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_ROW_INSERTED},
-
- {"dml_deletes", "dml", "Number of rows deleted",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_ROW_DELETED},
-
- {"dml_updates", "dml", "Number of rows updated",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_ROW_UPDTATED},
-
- {"dml_system_reads", "dml", "Number of system rows read",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_SYSTEM_ROW_READ},
-
- {"dml_system_inserts", "dml", "Number of system rows inserted",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_SYSTEM_ROW_INSERTED},
-
- {"dml_system_deletes", "dml", "Number of system rows deleted",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_SYSTEM_ROW_DELETED},
-
- {"dml_system_updates", "dml", "Number of system rows updated",
- static_cast<monitor_type_t>(
- MONITOR_EXISTING | MONITOR_DEFAULT_ON),
- MONITOR_DEFAULT_START, MONITOR_OLVD_SYSTEM_ROW_UPDATED},
-
/* ========== Counters for DDL operations ========== */
{"module_ddl", "ddl", "Statistics for DDLs",
MONITOR_MODULE,
@@ -1469,16 +1413,6 @@ srv_mon_process_existing_counter(
value = buf_pool.stat.n_pages_read;
break;
- /* Number of times secondary index lookup triggered cluster lookup */
- case MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS:
- value = srv_stats.n_sec_rec_cluster_reads;
- break;
- /* Number of times prefix optimization avoided triggering cluster
- lookup */
- case MONITOR_OVLD_INDEX_SEC_REC_CLUSTER_READS_AVOIDED:
- value = srv_stats.n_sec_rec_cluster_reads_avoided;
- break;
-
/* innodb_data_reads, the total number of data reads */
case MONITOR_OVLD_BYTE_READ:
value = srv_stats.data_read;
@@ -1547,46 +1481,6 @@ srv_mon_process_existing_counter(
value = srv_buf_pool_size;
break;
- /* innodb_rows_read */
- case MONITOR_OLVD_ROW_READ:
- value = srv_stats.n_rows_read;
- break;
-
- /* innodb_rows_inserted */
- case MONITOR_OLVD_ROW_INSERTED:
- value = srv_stats.n_rows_inserted;
- break;
-
- /* innodb_rows_deleted */
- case MONITOR_OLVD_ROW_DELETED:
- value = srv_stats.n_rows_deleted;
- break;
-
- /* innodb_rows_updated */
- case MONITOR_OLVD_ROW_UPDTATED:
- value = srv_stats.n_rows_updated;
- break;
-
- /* innodb_system_rows_read */
- case MONITOR_OLVD_SYSTEM_ROW_READ:
- value = srv_stats.n_system_rows_read;
- break;
-
- /* innodb_system_rows_inserted */
- case MONITOR_OLVD_SYSTEM_ROW_INSERTED:
- value = srv_stats.n_system_rows_inserted;
- break;
-
- /* innodb_system_rows_deleted */
- case MONITOR_OLVD_SYSTEM_ROW_DELETED:
- value = srv_stats.n_system_rows_deleted;
- break;
-
- /* innodb_system_rows_updated */
- case MONITOR_OLVD_SYSTEM_ROW_UPDATED:
- value = srv_stats.n_system_rows_updated;
- break;
-
/* innodb_row_lock_current_waits */
case MONITOR_OVLD_ROW_LOCK_CURRENT_WAIT:
// dirty read without lock_sys.wait_mutex
diff --git a/storage/innobase/srv/srv0srv.cc b/storage/innobase/srv/srv0srv.cc
index 3612da6a438..0934c666aa6 100644
--- a/storage/innobase/srv/srv0srv.cc
+++ b/storage/innobase/srv/srv0srv.cc
@@ -291,10 +291,6 @@ uint srv_fast_shutdown;
/** copy of innodb_status_file; generate a innodb_status.<pid> file */
ibool srv_innodb_status;
-/** innodb_prefix_index_cluster_optimization; whether to optimize
-prefix index queries to skip cluster index lookup when possible */
-my_bool srv_prefix_index_cluster_optimization;
-
/** innodb_stats_transient_sample_pages;
When estimating number of different key values in an index, sample
this many index pages, there are 2 ways to calculate statistics:
@@ -327,16 +323,6 @@ ulong srv_n_spin_wait_rounds;
/** innodb_spin_wait_delay */
uint srv_spin_wait_delay;
-static ulint srv_n_rows_inserted_old;
-static ulint srv_n_rows_updated_old;
-static ulint srv_n_rows_deleted_old;
-static ulint srv_n_rows_read_old;
-static ulint srv_n_system_rows_inserted_old;
-static ulint srv_n_system_rows_updated_old;
-static ulint srv_n_system_rows_deleted_old;
-static ulint srv_n_system_rows_read_old;
-
-ulint srv_truncated_status_writes;
/** Number of initialized rollback segments for persistent undo log */
ulong srv_available_undo_logs;
@@ -392,9 +378,6 @@ mysql_mutex_t srv_misc_tmpfile_mutex;
/** Temporary file for miscellanous diagnostic output */
FILE* srv_misc_tmpfile;
-static ulint srv_main_thread_process_no;
-static ulint srv_main_thread_id;
-
/* The following counts are used by the srv_master_callback. */
/** Iterations of the loop bounded by 'srv_active' label. */
@@ -695,7 +678,7 @@ static void srv_refresh_innodb_monitor_stats(time_t current_time)
mysql_mutex_lock(&srv_innodb_monitor_mutex);
if (difftime(current_time, srv_last_monitor_time) < 60) {
- /* We referesh InnoDB Monitor values so that averages are
+ /* We refresh InnoDB Monitor values so that averages are
printed from at most 60 last seconds */
mysql_mutex_unlock(&srv_innodb_monitor_mutex);
return;
@@ -712,16 +695,6 @@ static void srv_refresh_innodb_monitor_stats(time_t current_time)
buf_refresh_io_stats();
- srv_n_rows_inserted_old = srv_stats.n_rows_inserted;
- srv_n_rows_updated_old = srv_stats.n_rows_updated;
- srv_n_rows_deleted_old = srv_stats.n_rows_deleted;
- srv_n_rows_read_old = srv_stats.n_rows_read;
-
- srv_n_system_rows_inserted_old = srv_stats.n_system_rows_inserted;
- srv_n_system_rows_updated_old = srv_stats.n_system_rows_updated;
- srv_n_system_rows_deleted_old = srv_stats.n_system_rows_deleted;
- srv_n_system_rows_read_old = srv_stats.n_system_rows_read;
-
mysql_mutex_unlock(&srv_innodb_monitor_mutex);
}
@@ -828,34 +801,36 @@ srv_printf_innodb_monitor(
"--------\n", file);
os_aio_print(file);
- fputs("-------------------------------------\n"
- "INSERT BUFFER AND ADAPTIVE HASH INDEX\n"
- "-------------------------------------\n", file);
ibuf_print(file);
#ifdef BTR_CUR_HASH_ADAPT
- for (ulint i = 0; i < btr_ahi_parts && btr_search_enabled; ++i) {
- const auto part= &btr_search_sys.parts[i];
- part->latch.rd_lock(SRW_LOCK_CALL);
- ut_ad(part->heap->type == MEM_HEAP_FOR_BTR_SEARCH);
- fprintf(file, "Hash table size " ULINTPF
- ", node heap has " ULINTPF " buffer(s)\n",
- part->table.n_cells,
- part->heap->base.count - !part->heap->free_block);
- part->latch.rd_unlock();
- }
+ if (btr_search_enabled) {
+ fputs("-------------------\n"
+ "ADAPTIVE HASH INDEX\n"
+ "-------------------\n", file);
+ for (ulint i = 0; i < btr_ahi_parts; ++i) {
+ const auto part= &btr_search_sys.parts[i];
+ part->latch.rd_lock(SRW_LOCK_CALL);
+ ut_ad(part->heap->type == MEM_HEAP_FOR_BTR_SEARCH);
+ fprintf(file, "Hash table size " ULINTPF
+ ", node heap has " ULINTPF " buffer(s)\n",
+ part->table.n_cells,
+ part->heap->base.count
+ - !part->heap->free_block);
+ part->latch.rd_unlock();
+ }
- /* btr_cur_n_sea_old and btr_cur_n_non_sea_old are protected by
- srv_innodb_monitor_mutex (srv_refresh_innodb_monitor_stats) */
- const ulint with_ahi = btr_cur_n_sea, without_ahi = btr_cur_n_non_sea;
- fprintf(file,
- "%.2f hash searches/s, %.2f non-hash searches/s\n",
- static_cast<double>(with_ahi - btr_cur_n_sea_old)
- / time_elapsed,
- static_cast<double>(without_ahi - btr_cur_n_non_sea_old)
- / time_elapsed);
- btr_cur_n_sea_old = with_ahi;
- btr_cur_n_non_sea_old = without_ahi;
+ const ulint with_ahi = btr_cur_n_sea;
+ const ulint without_ahi = btr_cur_n_non_sea;
+ fprintf(file,
+ "%.2f hash searches/s, %.2f non-hash searches/s\n",
+ static_cast<double>(with_ahi - btr_cur_n_sea_old)
+ / time_elapsed,
+ static_cast<double>(without_ahi - btr_cur_n_non_sea_old)
+ / time_elapsed);
+ btr_cur_n_sea_old = with_ahi;
+ btr_cur_n_non_sea_old = without_ahi;
+ }
#endif /* BTR_CUR_HASH_ADAPT */
fputs("---\n"
@@ -887,68 +862,7 @@ srv_printf_innodb_monitor(
n_reserved);
}
- fprintf(file,
- "Process ID=" ULINTPF
- ", Main thread ID=" ULINTPF
- ", state: %s\n",
- srv_main_thread_process_no,
- srv_main_thread_id,
- srv_main_thread_op_info);
- fprintf(file,
- "Number of rows inserted " ULINTPF
- ", updated " ULINTPF
- ", deleted " ULINTPF
- ", read " ULINTPF "\n",
- (ulint) srv_stats.n_rows_inserted,
- (ulint) srv_stats.n_rows_updated,
- (ulint) srv_stats.n_rows_deleted,
- (ulint) srv_stats.n_rows_read);
- fprintf(file,
- "%.2f inserts/s, %.2f updates/s,"
- " %.2f deletes/s, %.2f reads/s\n",
- static_cast<double>(srv_stats.n_rows_inserted
- - srv_n_rows_inserted_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_rows_updated
- - srv_n_rows_updated_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_rows_deleted
- - srv_n_rows_deleted_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_rows_read
- - srv_n_rows_read_old)
- / time_elapsed);
- fprintf(file,
- "Number of system rows inserted " ULINTPF
- ", updated " ULINTPF ", deleted " ULINTPF
- ", read " ULINTPF "\n",
- (ulint) srv_stats.n_system_rows_inserted,
- (ulint) srv_stats.n_system_rows_updated,
- (ulint) srv_stats.n_system_rows_deleted,
- (ulint) srv_stats.n_system_rows_read);
- fprintf(file,
- "%.2f inserts/s, %.2f updates/s,"
- " %.2f deletes/s, %.2f reads/s\n",
- static_cast<double>(srv_stats.n_system_rows_inserted
- - srv_n_system_rows_inserted_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_system_rows_updated
- - srv_n_system_rows_updated_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_system_rows_deleted
- - srv_n_system_rows_deleted_old)
- / time_elapsed,
- static_cast<double>(srv_stats.n_system_rows_read
- - srv_n_system_rows_read_old)
- / time_elapsed);
- srv_n_rows_inserted_old = srv_stats.n_rows_inserted;
- srv_n_rows_updated_old = srv_stats.n_rows_updated;
- srv_n_rows_deleted_old = srv_stats.n_rows_deleted;
- srv_n_rows_read_old = srv_stats.n_rows_read;
- srv_n_system_rows_inserted_old = srv_stats.n_system_rows_inserted;
- srv_n_system_rows_updated_old = srv_stats.n_system_rows_updated;
- srv_n_system_rows_deleted_old = srv_stats.n_system_rows_deleted;
- srv_n_system_rows_read_old = srv_stats.n_system_rows_read;
+ fprintf(file, ", state: %s\n", srv_main_thread_op_info);
fputs("----------------------------\n"
"END OF INNODB MONITOR OUTPUT\n"
@@ -1086,28 +1000,6 @@ srv_export_innodb_status(void)
/ export_vars.innodb_row_lock_waits)
: 0;
- export_vars.innodb_rows_read = srv_stats.n_rows_read;
-
- export_vars.innodb_rows_inserted = srv_stats.n_rows_inserted;
-
- export_vars.innodb_rows_updated = srv_stats.n_rows_updated;
-
- export_vars.innodb_rows_deleted = srv_stats.n_rows_deleted;
-
- export_vars.innodb_system_rows_read = srv_stats.n_system_rows_read;
-
- export_vars.innodb_system_rows_inserted =
- srv_stats.n_system_rows_inserted;
-
- export_vars.innodb_system_rows_updated =
- srv_stats.n_system_rows_updated;
-
- export_vars.innodb_system_rows_deleted =
- srv_stats.n_system_rows_deleted;
-
- export_vars.innodb_truncated_status_writes =
- srv_truncated_status_writes;
-
export_vars.innodb_page_compression_saved = srv_stats.page_compression_saved;
export_vars.innodb_pages_page_compressed = srv_stats.pages_page_compressed;
export_vars.innodb_page_compressed_trim_op = srv_stats.page_compressed_trim_op;
@@ -1135,11 +1027,6 @@ srv_export_innodb_status(void)
export_vars.innodb_onlineddl_rowlog_pct_used = onlineddl_rowlog_pct_used;
export_vars.innodb_onlineddl_pct_progress = onlineddl_pct_progress;
- export_vars.innodb_sec_rec_cluster_reads =
- srv_stats.n_sec_rec_cluster_reads;
- export_vars.innodb_sec_rec_cluster_reads_avoided =
- srv_stats.n_sec_rec_cluster_reads_avoided;
-
if (!srv_read_only_mode) {
export_vars.innodb_encryption_rotation_pages_read_from_cache =
crypt_stat.pages_read_from_cache;
diff --git a/storage/rocksdb/mysql-test/rocksdb/r/innodb_i_s_tables_disabled.result b/storage/rocksdb/mysql-test/rocksdb/r/innodb_i_s_tables_disabled.result
index 45c87cc7313..de5ed76ad27 100644
--- a/storage/rocksdb/mysql-test/rocksdb/r/innodb_i_s_tables_disabled.result
+++ b/storage/rocksdb/mysql-test/rocksdb/r/innodb_i_s_tables_disabled.result
@@ -52,8 +52,6 @@ buffer_pool_pages_free buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL N
buffer_pages_created buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages created (innodb_pages_created)
buffer_pages_written buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages written (innodb_pages_written)
buffer_pages_read buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages read (innodb_pages_read)
-buffer_index_sec_rec_cluster_reads buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of secondary record reads triggered cluster read
-buffer_index_sec_rec_cluster_reads_avoided buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of secondary record reads avoided triggering cluster read
buffer_data_reads buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Amount of data read in bytes (innodb_data_reads)
buffer_data_written buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Amount of data written in bytes (innodb_data_written)
buffer_flush_batch_scanned buffer 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 set_owner Total pages scanned as part of flush batch
@@ -208,14 +206,6 @@ innodb_dict_lru_count_idle server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NU
innodb_dblwr_writes server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of doublewrite operations that have been performed (innodb_dblwr_writes)
innodb_dblwr_pages_written server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of pages that have been written for doublewrite operations (innodb_dblwr_pages_written)
innodb_page_size server 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 value InnoDB page size in bytes (innodb_page_size)
-dml_reads dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows read
-dml_inserts dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows inserted
-dml_deletes dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows deleted
-dml_updates dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of rows updated
-dml_system_reads dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows read
-dml_system_inserts dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows inserted
-dml_system_deletes dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows deleted
-dml_system_updates dml 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 status_counter Number of system rows updated
ddl_background_drop_indexes ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of indexes waiting to be dropped after failed index creation
ddl_online_create_index ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of indexes being created online
ddl_pending_alter_table ddl 0 NULL NULL NULL 0 NULL NULL NULL NULL NULL NULL NULL 0 counter Number of ALTER TABLE, CREATE INDEX, DROP INDEX in progress
diff --git a/storage/spider/ha_spider.cc b/storage/spider/ha_spider.cc
index 06606f6fd62..4ffe22aac0d 100644
--- a/storage/spider/ha_spider.cc
+++ b/storage/spider/ha_spider.cc
@@ -81,7 +81,6 @@ ha_spider::ha_spider(
ft_current = NULL;
ft_count = 0;
ft_init_without_index_init = FALSE;
- sql_kinds = 0;
error_mode = 0;
use_spatial_index = FALSE;
use_fields = FALSE;
@@ -92,7 +91,6 @@ ha_spider::ha_spider(
prev_index_rnd_init = SPD_NONE;
direct_aggregate_item_first = NULL;
result_link_idx = 0;
- result_list.have_sql_kind_backup = FALSE;
result_list.sqls = NULL;
result_list.insert_sqls = NULL;
result_list.update_sqls = NULL;
@@ -143,7 +141,6 @@ ha_spider::ha_spider(
ft_current = NULL;
ft_count = 0;
ft_init_without_index_init = FALSE;
- sql_kinds = 0;
error_mode = 0;
use_spatial_index = FALSE;
use_fields = FALSE;
@@ -154,7 +151,6 @@ ha_spider::ha_spider(
prev_index_rnd_init = SPD_NONE;
direct_aggregate_item_first = NULL;
result_link_idx = 0;
- result_list.have_sql_kind_backup = FALSE;
result_list.sqls = NULL;
result_list.insert_sqls = NULL;
result_list.update_sqls = NULL;
@@ -486,7 +482,7 @@ error_wide_handler_alloc:
int ha_spider::close()
{
- int error_num = 0, roop_count, error_num2;
+ int error_num= 0, roop_count;
THD *thd = ha_thd();
backup_error_status();
DBUG_ENTER("ha_spider::close");
@@ -513,17 +509,6 @@ int ha_spider::close()
spider_free(spider_current_trx, direct_aggregate_item_first, MYF(0));
direct_aggregate_item_first = direct_aggregate_item_current;
}
- if (is_clone)
- {
- for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
- {
- if ((error_num2 = close_opened_handler(roop_count, FALSE)))
- {
- if (check_error_mode(error_num2))
- error_num = error_num2;
- }
- }
- }
for (roop_count = share->use_dbton_count - 1; roop_count >= 0; roop_count--)
{
uint dbton_id = share->use_dbton_ids[roop_count];
@@ -996,13 +981,11 @@ int ha_spider::reset()
{
delete direct_aggregate_item_current->item;
direct_aggregate_item_current->item = NULL;
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
if (direct_aggregate_item_current->init_mem_root)
{
free_root(&direct_aggregate_item_current->mem_root, MYF(0));
direct_aggregate_item_current->init_mem_root = FALSE;
}
-#endif
}
direct_aggregate_item_current = direct_aggregate_item_current->next;
}
@@ -1070,12 +1053,6 @@ int ha_spider::reset()
{
result_list.update_sqls[roop_count].length(0);
- if ((error_num2 = close_opened_handler(roop_count, TRUE)))
- {
- if (check_error_mode(error_num2))
- error_num = error_num2;
- }
-
conn_kind[roop_count] = SPIDER_CONN_KIND_MYSQL;
}
result_list.bulk_update_mode = 0;
@@ -1116,10 +1093,8 @@ int ha_spider::reset()
ft_current = NULL;
ft_count = 0;
ft_init_without_index_init = FALSE;
- sql_kinds = 0;
do_direct_update = FALSE;
prev_index_rnd_init = SPD_NONE;
- result_list.have_sql_kind_backup = FALSE;
result_list.direct_order_limit = FALSE;
result_list.direct_limit_offset = FALSE;
result_list.set_split_read = FALSE;
@@ -1278,8 +1253,7 @@ int ha_spider::index_init(
set_select_column_mode();
}
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
result_list.check_direct_order_limit = FALSE;
prev_index_rnd_init = SPD_INDEX;
@@ -1337,8 +1311,6 @@ int ha_spider::index_read_map_internal(
)
use_spatial_index = TRUE;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
@@ -1351,8 +1323,7 @@ int ha_spider::index_read_map_internal(
start_key.key = key;
start_key.keypart_map = keypart_map;
start_key.flag = find_flag;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
if ((error_num = spider_set_conn_bg_param(this)))
DBUG_RETURN(error_num);
@@ -1400,7 +1371,6 @@ int ha_spider::index_read_map_internal(
result_list.split_read));
DBUG_PRINT("info",("spider result_list.limit_num=%lld",
result_list.limit_num));
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -1427,16 +1397,6 @@ int ha_spider::index_read_map_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, lock_mode, link_ok;
lock_mode = spider_conn_lock_mode(this);
@@ -1495,13 +1455,8 @@ int ha_spider::index_read_map_internal(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -1709,8 +1664,6 @@ int ha_spider::index_read_last_map_internal(
DBUG_RETURN(ER_QUERY_INTERRUPTED);
}
do_direct_update = FALSE;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
@@ -1731,8 +1684,7 @@ int ha_spider::index_read_last_map_internal(
start_key.key = key;
start_key.keypart_map = keypart_map;
start_key.flag = HA_READ_KEY_EXACT;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
if ((error_num = spider_set_conn_bg_param(this)))
DBUG_RETURN(error_num);
@@ -1768,7 +1720,6 @@ int ha_spider::index_read_last_map_internal(
&start_key, NULL, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -1795,16 +1746,6 @@ int ha_spider::index_read_last_map_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -1863,13 +1804,8 @@ int ha_spider::index_read_last_map_internal(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -2128,25 +2064,20 @@ int ha_spider::index_first_internal(
DBUG_RETURN(ER_QUERY_INTERRUPTED);
}
do_direct_update = FALSE;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
pt_clone_source_handler));
pt_clone_source_handler->pt_clone_last_searcher = this;
}
- if (
- sql_is_empty(SPIDER_SQL_TYPE_HANDLER) ||
- sql_is_empty(SPIDER_SQL_TYPE_SELECT_SQL)
- ) {
-/*
- spider_db_free_one_result_for_start_next(this);
-*/
+ if (sql_is_empty(SPIDER_SQL_TYPE_SELECT_SQL))
+ {
+ /*
+ spider_db_free_one_result_for_start_next(this);
+ */
if ((error_num = spider_db_free_result(this, FALSE)))
DBUG_RETURN(error_num);
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
check_direct_order_limit();
@@ -2185,7 +2116,6 @@ int ha_spider::index_first_internal(
NULL, NULL, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -2212,16 +2142,6 @@ int ha_spider::index_first_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -2280,13 +2200,8 @@ int ha_spider::index_first_internal(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -2493,25 +2408,20 @@ int ha_spider::index_last_internal(
DBUG_RETURN(ER_QUERY_INTERRUPTED);
}
do_direct_update = FALSE;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
pt_clone_source_handler));
pt_clone_source_handler->pt_clone_last_searcher = this;
}
- if (
- sql_is_empty(SPIDER_SQL_TYPE_HANDLER) ||
- sql_is_empty(SPIDER_SQL_TYPE_SELECT_SQL)
- ) {
-/*
- spider_db_free_one_result_for_start_next(this);
-*/
+ if (sql_is_empty(SPIDER_SQL_TYPE_SELECT_SQL))
+ {
+ /*
+ spider_db_free_one_result_for_start_next(this);
+ */
if ((error_num = spider_db_free_result(this, FALSE)))
DBUG_RETURN(error_num);
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
check_direct_order_limit();
@@ -2550,7 +2460,6 @@ int ha_spider::index_last_internal(
NULL, NULL, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -2577,16 +2486,6 @@ int ha_spider::index_last_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -2645,13 +2544,8 @@ int ha_spider::index_last_internal(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -2910,8 +2804,6 @@ int ha_spider::read_range_first_internal(
}
range_key_part = table->key_info[active_index].key_part;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
@@ -2920,8 +2812,7 @@ int ha_spider::read_range_first_internal(
}
spider_db_free_one_result_for_start_next(this);
check_direct_order_limit();
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
if ((error_num = spider_set_conn_bg_param(this)))
DBUG_RETURN(error_num);
@@ -2958,7 +2849,6 @@ int ha_spider::read_range_first_internal(
start_key, eq_range ? NULL : end_key, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -2985,16 +2875,6 @@ int ha_spider::read_range_first_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -3053,13 +2933,8 @@ int ha_spider::read_range_first_internal(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -3242,12 +3117,12 @@ int ha_spider::read_range_first(
use_pre_call = FALSE;
if ((error_num = read_range_next()))
DBUG_RETURN(error_num);
- DBUG_RETURN(check_ha_range_eof());
+ DBUG_RETURN(0);
}
if ((error_num = read_range_first_internal(table->record[0], start_key,
end_key, eq_range, sorted)))
DBUG_RETURN(error_num);
- DBUG_RETURN(check_ha_range_eof());
+ DBUG_RETURN(0);
}
int ha_spider::read_range_next()
@@ -3278,7 +3153,7 @@ int ha_spider::read_range_next()
if ((error_num = spider_db_seek_next(table->record[0], this, search_link_idx,
table)))
DBUG_RETURN(check_error_mode_eof(error_num));
- DBUG_RETURN(check_ha_range_eof());
+ DBUG_RETURN(0);
}
void ha_spider::reset_no_where_cond()
@@ -3455,8 +3330,6 @@ int ha_spider::multi_range_read_next_first(
DBUG_RETURN(ER_QUERY_INTERRUPTED);
}
do_direct_update = FALSE;
- if ((error_num = index_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
if (is_clone)
{
DBUG_PRINT("info",("spider set pt_clone_last_searcher to %p",
@@ -3472,17 +3345,13 @@ int ha_spider::multi_range_read_next_first(
DBUG_PRINT("info",("spider result_list.finish_flg = FALSE"));
result_list.finish_flg = FALSE;
result_list.record_num = 0;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
result_list.desc_flg = FALSE;
result_list.sorted = mrr_is_output_sorted;
result_list.key_info = &table->key_info[active_index];
- if (
- multi_range_num == 1 ||
- result_list.multi_split_read <= 1 ||
- (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- ) {
+ if (multi_range_num == 1 || result_list.multi_split_read <= 1)
+ {
if (wide_handler->keyread)
result_list.keyread = TRUE;
else
@@ -3517,7 +3386,6 @@ int ha_spider::multi_range_read_next_first(
NULL : &mrr_cur_range.end_key, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -3544,16 +3412,6 @@ int ha_spider::multi_range_read_next_first(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset + result_list.record_num,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -3610,13 +3468,8 @@ int ha_spider::multi_range_read_next_first(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -3786,7 +3639,7 @@ int ha_spider::multi_range_read_next_first(
if (!(error_num = spider_db_fetch(table->record[0], this, table)))
{
*range_info = (char *) mrr_cur_range.ptr;
- DBUG_RETURN(check_ha_range_eof());
+ DBUG_RETURN(0);
}
if (
error_num != HA_ERR_END_OF_FILE &&
@@ -3814,7 +3667,6 @@ int ha_spider::multi_range_read_next_first(
DBUG_RETURN(check_error_mode_eof(0));
}
set_where_to_pos_sql(SPIDER_SQL_TYPE_SELECT_SQL);
- set_where_to_pos_sql(SPIDER_SQL_TYPE_HANDLER);
}
DBUG_PRINT("info",("spider range_res2=%d", range_res));
if (error_num)
@@ -3925,34 +3777,11 @@ int ha_spider::multi_range_read_next_first(
if ((error_num = reset_sql_sql(
SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL)))
DBUG_RETURN(error_num);
- if ((sql_kinds & SPIDER_SQL_KIND_SQL))
- {
- for (roop_count = 0; roop_count < (int) share->link_count;
- roop_count++)
- {
- result_list.sql_kind_backup[roop_count] = sql_kind[roop_count];
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
- }
- result_list.sql_kinds_backup = sql_kinds;
- sql_kinds = SPIDER_SQL_KIND_SQL;
- result_list.have_sql_kind_backup = TRUE;
- }
}
memset(result_list.tmp_table_join_first, 0xFF,
share->link_bitmap_size);
} else {
result_list.tmp_table_join = FALSE;
- if (result_list.have_sql_kind_backup)
- {
- for (roop_count = 0; roop_count < (int) share->link_count;
- roop_count++)
- {
- sql_kind[roop_count] =
- result_list.sql_kind_backup[roop_count];
- }
- sql_kinds = result_list.sql_kinds_backup;
- result_list.have_sql_kind_backup = FALSE;
- }
}
result_list.tmp_table_join_break_after_get_next = FALSE;
@@ -4267,13 +4096,8 @@ int ha_spider::multi_range_read_next_first(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -4547,8 +4371,7 @@ int ha_spider::multi_range_read_next_first(
DBUG_RETURN(check_error_mode_eof(0));
}
multi_range_cnt = 0;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
} while (!error_num);
}
@@ -4621,11 +4444,8 @@ int ha_spider::multi_range_read_next_next(
pt_clone_source_handler));
pt_clone_source_handler->pt_clone_last_searcher = this;
}
- if (
- multi_range_num == 1 ||
- result_list.multi_split_read <= 1 ||
- (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- ) {
+ if (multi_range_num == 1 || result_list.multi_split_read <= 1)
+ {
if (!(error_num = spider_db_seek_next(table->record[0], this,
search_link_idx, table)))
{
@@ -4665,7 +4485,6 @@ int ha_spider::multi_range_read_next_next(
DBUG_RETURN(check_error_mode_eof(0));
}
set_where_to_pos_sql(SPIDER_SQL_TYPE_SELECT_SQL);
- set_where_to_pos_sql(SPIDER_SQL_TYPE_HANDLER);
result_list.limit_num =
result_list.internal_limit - result_list.record_num >=
result_list.split_read ?
@@ -4678,7 +4497,6 @@ int ha_spider::multi_range_read_next_next(
NULL : &mrr_cur_range.end_key, this))
)
DBUG_RETURN(error_num);
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (result_list.direct_order_limit)
{
@@ -4705,16 +4523,6 @@ int ha_spider::multi_range_read_next_next(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset + result_list.record_num,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -4771,13 +4579,8 @@ int ha_spider::multi_range_read_next_next(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -4946,7 +4749,7 @@ int ha_spider::multi_range_read_next_next(
if (!(error_num = spider_db_fetch(table->record[0], this, table)))
{
*range_info = (char *) mrr_cur_range.ptr;
- DBUG_RETURN(check_ha_range_eof());
+ DBUG_RETURN(0);
}
if (
error_num != HA_ERR_END_OF_FILE &&
@@ -5049,8 +4852,7 @@ int ha_spider::multi_range_read_next_next(
}
result_list.record_num = 0;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
bool tmp_high_priority = wide_handler->high_priority;
@@ -5091,34 +4893,11 @@ int ha_spider::multi_range_read_next_next(
if ((error_num = reset_sql_sql(
SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL)))
DBUG_RETURN(error_num);
- if ((sql_kinds & SPIDER_SQL_KIND_SQL))
- {
- for (roop_count = 0; roop_count < (int) share->link_count;
- roop_count++)
- {
- result_list.sql_kind_backup[roop_count] = sql_kind[roop_count];
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
- }
- result_list.sql_kinds_backup = sql_kinds;
- sql_kinds = SPIDER_SQL_KIND_SQL;
- result_list.have_sql_kind_backup = TRUE;
- }
}
memset(result_list.tmp_table_join_first, 0xFF,
share->link_bitmap_size);
} else {
result_list.tmp_table_join = FALSE;
- if (result_list.have_sql_kind_backup)
- {
- for (roop_count = 0; roop_count < (int) share->link_count;
- roop_count++)
- {
- sql_kind[roop_count] =
- result_list.sql_kind_backup[roop_count];
- }
- sql_kinds = result_list.sql_kinds_backup;
- result_list.have_sql_kind_backup = FALSE;
- }
}
if (result_list.tmp_table_join)
@@ -5421,13 +5200,8 @@ int ha_spider::multi_range_read_next_next(
}
} else {
ulong sql_type;
- conn = conns[roop_count];
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -5699,8 +5473,7 @@ int ha_spider::multi_range_read_next_next(
DBUG_RETURN(check_error_mode_eof(0));
}
multi_range_cnt = 0;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
} while (!error_num);
}
@@ -5805,8 +5578,7 @@ int ha_spider::rnd_init(
result_list.keyread = FALSE;
init_rnd_handler = FALSE;
- if ((error_num = reset_sql_sql(
- SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER)))
+ if ((error_num= reset_sql_sql(SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
result_list.check_direct_order_limit = FALSE;
}
@@ -5862,8 +5634,6 @@ int ha_spider::rnd_next_internal(
{
if ((error_num = spider_set_conn_bg_param(this)))
DBUG_RETURN(error_num);
- if ((error_num = rnd_handler_init()))
- DBUG_RETURN(check_error_mode_eof(error_num));
check_direct_order_limit();
check_select_column(TRUE);
@@ -5936,7 +5706,6 @@ int ha_spider::rnd_next_internal(
result_list.limit_num =
result_list.internal_limit >= result_list.split_read ?
result_list.split_read : result_list.internal_limit;
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = append_limit_sql_part(
result_list.internal_offset,
@@ -5952,16 +5721,6 @@ int ha_spider::rnd_next_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -6021,12 +5780,7 @@ int ha_spider::rnd_next_internal(
} else {
SPIDER_CONN *conn = conns[roop_count];
ulong sql_type;
- if (sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_hdl = dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_hdl->need_lock_before_set_sql_for_exec(sql_type))
@@ -6382,7 +6136,7 @@ _ft_vft spider_ft_vft = {
int ha_spider::ft_init()
{
- int roop_count, error_num;
+ int error_num;
DBUG_ENTER("ha_spider::ft_init");
DBUG_PRINT("info",("spider this=%p", this));
if (store_error_num)
@@ -6418,9 +6172,6 @@ int ha_spider::ft_init()
ft_init_and_first = TRUE;
- for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
- sql_kinds = SPIDER_SQL_KIND_SQL;
DBUG_RETURN(0);
}
@@ -6563,7 +6314,6 @@ int ha_spider::ft_read_internal(
append_group_by_sql_part(NULL, 0, SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
}
- if (sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = append_limit_sql_part(
result_list.internal_offset,
@@ -6579,16 +6329,6 @@ int ha_spider::ft_read_internal(
DBUG_RETURN(error_num);
}
}
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = append_limit_sql_part(
- result_list.internal_offset,
- result_list.limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_RETURN(error_num);
- }
- }
int roop_start, roop_end, roop_count, tmp_lock_mode, link_ok;
tmp_lock_mode = spider_conn_lock_mode(this);
@@ -8433,7 +8173,6 @@ bool ha_spider::check_direct_update_sql_part(
DBUG_RETURN(FALSE);
}
-#ifdef SPIDER_MDEV_16246
/**
Perform initialization for a direct update request.
@@ -8446,9 +8185,6 @@ bool ha_spider::check_direct_update_sql_part(
int ha_spider::direct_update_rows_init(
List<Item> *update_fields
)
-#else
-int ha_spider::direct_update_rows_init()
-#endif
{
st_select_lex *select_lex;
longlong select_limit;
@@ -8565,11 +8301,8 @@ int ha_spider::direct_update_rows(
table_share->db.str, table_share->table_name.str);
DBUG_RETURN(ER_SPIDER_READ_ONLY_NUM);
}
- if (
- (active_index != MAX_KEY && (error_num = index_handler_init())) ||
- (active_index == MAX_KEY && (error_num = rnd_handler_init())) ||
- (error_num = spider_db_direct_update(this, table, update_rows, found_rows))
- )
+ if ((error_num=
+ spider_db_direct_update(this, table, update_rows, found_rows)))
DBUG_RETURN(check_error_mode(error_num));
DBUG_RETURN(0);
@@ -8711,11 +8444,7 @@ int ha_spider::direct_delete_rows(
table_share->db.str, table_share->table_name.str);
DBUG_RETURN(ER_SPIDER_READ_ONLY_NUM);
}
- if (
- (active_index != MAX_KEY && (error_num = index_handler_init())) ||
- (active_index == MAX_KEY && (error_num = rnd_handler_init())) ||
- (error_num = spider_db_direct_delete(this, table, delete_rows))
- )
+ if ((error_num= spider_db_direct_delete(this, table, delete_rows)))
DBUG_RETURN(check_error_mode(error_num));
DBUG_RETURN(0);
@@ -8724,7 +8453,7 @@ int ha_spider::direct_delete_rows(
int ha_spider::delete_all_rows()
{
- int error_num, roop_count;
+ int error_num;
THD *thd = ha_thd();
backup_error_status();
DBUG_ENTER("ha_spider::delete_all_rows");
@@ -8738,9 +8467,6 @@ int ha_spider::delete_all_rows()
DBUG_RETURN(ER_SPIDER_READ_ONLY_NUM);
}
do_direct_update = FALSE;
- sql_kinds = SPIDER_SQL_KIND_SQL;
- for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
if ((error_num = spider_db_delete_all_rows(this)))
DBUG_RETURN(check_error_mode(error_num));
if (wide_handler->sql_command == SQLCOM_TRUNCATE &&
@@ -8762,7 +8488,7 @@ int ha_spider::delete_all_rows()
int ha_spider::truncate()
{
- int error_num, roop_count;
+ int error_num;
THD *thd = ha_thd();
backup_error_status();
DBUG_ENTER("ha_spider::truncate");
@@ -8779,9 +8505,6 @@ int ha_spider::truncate()
DBUG_RETURN(error_num);
}
do_direct_update = FALSE;
- sql_kinds = SPIDER_SQL_KIND_SQL;
- for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
if ((error_num = spider_db_delete_all_rows(this)))
DBUG_RETURN(check_error_mode(error_num));
if (wide_handler->sql_command == SQLCOM_TRUNCATE &&
@@ -10123,7 +9846,6 @@ uint ha_spider::check_partitioned()
void ha_spider::check_direct_order_limit()
{
- int roop_count;
DBUG_ENTER("ha_spider::check_direct_order_limit");
DBUG_PRINT("info",("spider this=%p", this));
if (!result_list.check_direct_order_limit)
@@ -10131,9 +9853,6 @@ void ha_spider::check_direct_order_limit()
if (spider_check_direct_order_limit(this))
{
result_list.direct_order_limit = TRUE;
- sql_kinds = SPIDER_SQL_KIND_SQL;
- for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
- sql_kind[roop_count] = SPIDER_SQL_KIND_SQL;
} else
result_list.direct_order_limit = FALSE;
@@ -10219,35 +9938,6 @@ bool ha_spider::is_sole_projection_field(
DBUG_RETURN( TRUE );
}
-int ha_spider::check_ha_range_eof()
-{
- DBUG_ENTER("ha_spider::check_ha_range_eof");
- DBUG_PRINT("info",("spider this=%p", this));
- const key_range *end_key = result_list.end_key;
- DBUG_PRINT("info",("spider use_both_key=%s",
- result_list.use_both_key ? "TRUE" : "FALSE"));
- DBUG_PRINT("info",("spider sql_kind[%u]=%u",
- search_link_idx, sql_kind[search_link_idx]));
- DBUG_PRINT("info",("spider sql_command=%u", wide_handler->sql_command));
- if (
- result_list.use_both_key &&
- (sql_kind[search_link_idx] & SPIDER_SQL_KIND_HANDLER) &&
- wide_handler->sql_command != SQLCOM_HA_READ
- ) {
- int cmp_result = key_cmp(result_list.key_info->key_part,
- end_key->key, end_key->length);
- DBUG_PRINT("info",("spider cmp_result=%d", cmp_result));
- if (
- cmp_result > 0 ||
- (end_key->flag == HA_READ_BEFORE_KEY && !cmp_result)
- ) {
- table->status = STATUS_NOT_FOUND;
- DBUG_RETURN(HA_ERR_END_OF_FILE);
- }
- }
- DBUG_RETURN(0);
-}
-
int ha_spider::drop_tmp_tables()
{
int error_num = 0, tmp_error_num, need_mon;
@@ -10393,262 +10083,6 @@ int ha_spider::drop_tmp_tables()
DBUG_RETURN(error_num);
}
-bool ha_spider::handler_opened(
- int link_idx,
- uint tgt_conn_kind
-) {
- DBUG_ENTER("ha_spider::handler_opened");
- DBUG_PRINT("info",("spider this=%p", this));
- DBUG_PRINT("info",("spider link_idx=%d", link_idx));
- DBUG_PRINT("info",("spider tgt_conn_kind=%u", tgt_conn_kind));
- if (
- spider_bit_is_set(m_handler_opened, link_idx)
- ) {
- DBUG_PRINT("info",("spider TRUE"));
- DBUG_RETURN(TRUE);
- }
- DBUG_PRINT("info",("spider FALSE"));
- DBUG_RETURN(FALSE);
-}
-
-void ha_spider::set_handler_opened(
- int link_idx
-) {
- DBUG_ENTER("ha_spider::set_handler_opened");
- DBUG_PRINT("info",("spider this=%p", this));
- spider_set_bit(m_handler_opened, link_idx);
- DBUG_VOID_RETURN;
-}
-
-void ha_spider::clear_handler_opened(
- int link_idx,
- uint tgt_conn_kind
-) {
- DBUG_ENTER("ha_spider::clear_handler_opened");
- DBUG_PRINT("info",("spider this=%p", this));
- spider_clear_bit(m_handler_opened, link_idx);
- DBUG_VOID_RETURN;
-}
-
-int ha_spider::close_opened_handler(
- int link_idx,
- bool release_conn
-) {
- int error_num = 0, error_num2;
- DBUG_ENTER("ha_spider::close_opened_handler");
- DBUG_PRINT("info",("spider this=%p", this));
-
- if (spider_bit_is_set(m_handler_opened, link_idx))
- {
- if ((error_num2 = spider_db_close_handler(this,
- conns[link_idx], link_idx, SPIDER_CONN_KIND_MYSQL))
- ) {
- if (
- share->monitoring_kind[link_idx] &&
- need_mons[link_idx]
- ) {
- error_num2 = spider_ping_table_mon_from_table(
- wide_handler->trx,
- wide_handler->trx->thd,
- share,
- link_idx,
- (uint32) share->monitoring_sid[link_idx],
- share->table_name,
- share->table_name_length,
- conn_link_idx[link_idx],
- NULL,
- 0,
- share->monitoring_kind[link_idx],
- share->monitoring_limit[link_idx],
- share->monitoring_flag[link_idx],
- TRUE
- );
- }
- error_num = error_num2;
- }
- spider_clear_bit(m_handler_opened, link_idx);
- if (release_conn && !conns[link_idx]->join_trx)
- {
- spider_free_conn_from_trx(wide_handler->trx, conns[link_idx],
- FALSE, FALSE, NULL);
- conns[link_idx] = NULL;
- }
- }
- DBUG_RETURN(error_num);
-}
-
-int ha_spider::index_handler_init()
-{
- int lock_mode, error_num;
- int roop_start, roop_end, roop_count;
- DBUG_ENTER("ha_spider::index_handler_init");
- DBUG_PRINT("info",("spider this=%p", this));
- if (!init_index_handler)
- {
- init_index_handler = TRUE;
- lock_mode = spider_conn_lock_mode(this);
- if (lock_mode)
- {
- /* "for update" or "lock in share mode" */
- roop_start = spider_conn_link_idx_next(share->link_statuses,
- conn_link_idx, -1, share->link_count,
- SPIDER_LINK_STATUS_RECOVERY);
- roop_end = share->link_count;
- } else {
- roop_start = search_link_idx;
- roop_end = search_link_idx + 1;
- }
- sql_kinds = 0;
- direct_update_kinds = 0;
- for (roop_count = roop_start; roop_count < roop_end;
- roop_count = spider_conn_link_idx_next(share->link_statuses,
- conn_link_idx, roop_count, share->link_count,
- SPIDER_LINK_STATUS_RECOVERY)
- ) {
- if (
- spider_conn_use_handler(this, lock_mode, roop_count) &&
- spider_conn_need_open_handler(this, active_index, roop_count)
- ) {
- if ((error_num = spider_db_open_handler(this,
- conns[roop_count]
- , roop_count))
- ) {
- if (
- share->monitoring_kind[roop_count] &&
- need_mons[roop_count]
- ) {
- error_num = spider_ping_table_mon_from_table(
- wide_handler->trx,
- wide_handler->trx->thd,
- share,
- roop_count,
- (uint32) share->monitoring_sid[roop_count],
- share->table_name,
- share->table_name_length,
- conn_link_idx[roop_count],
- NULL,
- 0,
- share->monitoring_kind[roop_count],
- share->monitoring_limit[roop_count],
- share->monitoring_flag[roop_count],
- TRUE
- );
- }
- DBUG_RETURN(error_num);
- }
- set_handler_opened(roop_count);
- }
- }
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- st_select_lex *select_lex;
- longlong select_limit;
- longlong offset_limit;
- spider_get_select_limit(this, &select_lex, &select_limit, &offset_limit);
- DBUG_PRINT("info",("spider SPIDER_SQL_KIND_HANDLER"));
- result_list.semi_split_read = 1;
- result_list.semi_split_read_limit = 9223372036854775807LL;
- if (select_limit == 9223372036854775807LL)
- {
- DBUG_PRINT("info",("spider set limit to 1"));
- result_list.semi_split_read_base = 1;
- result_list.split_read = 1;
- } else {
- DBUG_PRINT("info",("spider set limit to %lld", select_limit));
- result_list.semi_split_read_base = select_limit;
- result_list.split_read = select_limit;
- }
- }
- }
- DBUG_RETURN(0);
-}
-
-int ha_spider::rnd_handler_init()
-{
- int error_num, lock_mode;
- int roop_start, roop_end, roop_count;
- DBUG_ENTER("ha_spider::rnd_handler_init");
- DBUG_PRINT("info",("spider this=%p", this));
- if (!init_rnd_handler)
- {
- init_rnd_handler = TRUE;
- lock_mode = spider_conn_lock_mode(this);
- if (lock_mode)
- {
- /* "for update" or "lock in share mode" */
- roop_start = spider_conn_link_idx_next(share->link_statuses,
- conn_link_idx, -1, share->link_count,
- SPIDER_LINK_STATUS_RECOVERY);
- roop_end = share->link_count;
- } else {
- roop_start = search_link_idx;
- roop_end = search_link_idx + 1;
- }
- sql_kinds = 0;
- direct_update_kinds = 0;
- for (roop_count = roop_start; roop_count < roop_end;
- roop_count = spider_conn_link_idx_next(share->link_statuses,
- conn_link_idx, roop_count, share->link_count,
- SPIDER_LINK_STATUS_RECOVERY)
- ) {
- if (
- spider_conn_use_handler(this, lock_mode, roop_count) &&
- spider_conn_need_open_handler(this, MAX_KEY, roop_count)
- ) {
- if ((error_num = spider_db_open_handler(this,
- conns[roop_count]
- , roop_count))
- ) {
- if (
- share->monitoring_kind[roop_count] &&
- need_mons[roop_count]
- ) {
- error_num = spider_ping_table_mon_from_table(
- wide_handler->trx,
- wide_handler->trx->thd,
- share,
- roop_count,
- (uint32) share->monitoring_sid[roop_count],
- share->table_name,
- share->table_name_length,
- conn_link_idx[roop_count],
- NULL,
- 0,
- share->monitoring_kind[roop_count],
- share->monitoring_limit[roop_count],
- share->monitoring_flag[roop_count],
- TRUE
- );
- }
- DBUG_RETURN(error_num);
- }
- set_handler_opened(roop_count);
- }
- }
- if (sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- st_select_lex *select_lex;
- longlong select_limit;
- longlong offset_limit;
- spider_get_select_limit(this, &select_lex, &select_limit, &offset_limit);
- DBUG_PRINT("info",("spider SPIDER_SQL_KIND_HANDLER"));
- result_list.semi_split_read = 1;
- result_list.semi_split_read_limit = 9223372036854775807LL;
- if (select_limit == 9223372036854775807LL)
- {
- DBUG_PRINT("info",("spider set limit to 1"));
- result_list.semi_split_read_base = 1;
- result_list.split_read = 1;
- } else {
- DBUG_PRINT("info",("spider set limit to %lld", select_limit));
- result_list.semi_split_read_base = select_limit;
- result_list.split_read = select_limit;
- }
- }
- }
- DBUG_RETURN(0);
-}
-
void ha_spider::set_error_mode()
{
THD *thd = ha_thd();
@@ -12594,26 +12028,6 @@ int ha_spider::print_item_type(
DBUG_RETURN(0);
}
-bool ha_spider::support_use_handler_sql(
- int use_handler
-) {
- uint roop_count, dbton_id;
- spider_db_handler *dbton_hdl;
- DBUG_ENTER("ha_spider::support_use_handler_sql");
- for (roop_count = 0; roop_count < share->use_sql_dbton_count; roop_count++)
- {
- dbton_id = share->use_sql_dbton_ids[roop_count];
- dbton_hdl = dbton_handler[dbton_id];
- if (
- dbton_hdl->first_link_idx >= 0 &&
- !dbton_hdl->support_use_handler(use_handler)
- ) {
- DBUG_RETURN(FALSE);
- }
- }
- DBUG_RETURN(TRUE);
-}
-
int ha_spider::init_union_table_name_pos_sql()
{
int error_num;
diff --git a/storage/spider/ha_spider.h b/storage/spider/ha_spider.h
index 579700d855b..4dffdf78553 100644
--- a/storage/spider/ha_spider.h
+++ b/storage/spider/ha_spider.h
@@ -59,8 +59,6 @@ public:
const char *mem_calc_func_name;
const char *mem_calc_file_name;
ulong mem_calc_line_no;
- uint sql_kinds;
- uint *sql_kind;
ulonglong *connection_ids;
uint conn_kinds;
uint *conn_kind;
@@ -138,9 +136,6 @@ public:
ulonglong *db_request_id;
uchar *db_request_phase;
- uchar *m_handler_opened;
- uint *m_handler_id;
- char **m_handler_cid;
bool do_direct_update;
uint direct_update_kinds;
spider_index_rnd_init prev_index_rnd_init;
@@ -427,13 +422,9 @@ public:
longlong select_limit,
longlong offset_limit
);
-#ifdef SPIDER_MDEV_16246
int direct_update_rows_init(
List<Item> *update_fields
);
-#else
- int direct_update_rows_init();
-#endif
int direct_update_rows(
ha_rows *update_rows,
ha_rows *found_row
@@ -551,25 +542,7 @@ public:
bool is_sole_projection_field(
uint16 field_index
);
- int check_ha_range_eof();
int drop_tmp_tables();
- bool handler_opened(
- int link_idx,
- uint tgt_conn_kind
- );
- void set_handler_opened(
- int link_idx
- );
- void clear_handler_opened(
- int link_idx,
- uint tgt_conn_kind
- );
- int close_opened_handler(
- int link_idx,
- bool release_conn
- );
- int index_handler_init();
- int rnd_handler_init();
void set_error_mode();
void backup_error_status();
int check_error_mode(
@@ -813,9 +786,6 @@ public:
const char *alias,
uint alias_length
);
- bool support_use_handler_sql(
- int use_handler
- );
int init_union_table_name_pos_sql();
int set_union_table_name_pos_sql();
int append_lock_tables_list();
diff --git a/storage/spider/mysql-test/spider/bugfix/r/index.result b/storage/spider/mysql-test/spider/bugfix/r/index.result
index 2aa0b56ef06..3563744997b 100644
--- a/storage/spider/mysql-test/spider/bugfix/r/index.result
+++ b/storage/spider/mysql-test/spider/bugfix/r/index.result
@@ -64,15 +64,6 @@ create table auto_test_local.t (a int, b char(1), primary key(a desc));
insert into auto_test_local.t VALUES (1,'f'),(2,'g'),(3,'j'), (4,'i'),(5,'h');
create table ts (a int, b char(1), primary key(a desc))
engine=spider comment='wrapper "mysql", srv "s_1", table "t"';
-set spider_use_handler=3;
-Warnings:
-Warning 1287 '@@spider_use_handler' is deprecated and will be removed in a future release
-select a, b from ts where a > 0 and b = 'g' order by a;
-a b
-2 g
-set spider_use_handler=default;
-Warnings:
-Warning 1287 '@@spider_use_handler' is deprecated and will be removed in a future release
select a, b from ts where a > 0 and b = 'g' order by a;
a b
2 g
diff --git a/storage/spider/mysql-test/spider/bugfix/t/index.test b/storage/spider/mysql-test/spider/bugfix/t/index.test
index 5167e40e8c4..10d5025c9c7 100644
--- a/storage/spider/mysql-test/spider/bugfix/t/index.test
+++ b/storage/spider/mysql-test/spider/bugfix/t/index.test
@@ -38,9 +38,6 @@ create table auto_test_local.t (a int, b char(1), primary key(a desc));
insert into auto_test_local.t VALUES (1,'f'),(2,'g'),(3,'j'), (4,'i'),(5,'h');
create table ts (a int, b char(1), primary key(a desc))
engine=spider comment='wrapper "mysql", srv "s_1", table "t"';
-set spider_use_handler=3;
-select a, b from ts where a > 0 and b = 'g' order by a;
-set spider_use_handler=default;
select a, b from ts where a > 0 and b = 'g' order by a;
drop table ts, auto_test_local.t;
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child2_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child2_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child2_2.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child2_2.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child2_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child2_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child3_1.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child3_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child3_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child3_2.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child3_2.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child3_2.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_child3_3.inc b/storage/spider/mysql-test/spider/handler/include/deinit_child3_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_child3_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_master_1.inc b/storage/spider/mysql-test/spider/handler/include/deinit_master_1.inc
deleted file mode 100644
index c19e376d10a..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_master_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---source ../../include/deinit_spider.inc
diff --git a/storage/spider/mysql-test/spider/handler/include/deinit_slave1_1.inc b/storage/spider/mysql-test/spider/handler/include/deinit_slave1_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/deinit_slave1_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_2.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_2.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child2_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_1.inc
deleted file mode 100644
index c19e376d10a..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---source ../../include/deinit_spider.inc
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_2.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_2.inc
deleted file mode 100644
index c19e376d10a..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_2.inc
+++ /dev/null
@@ -1 +0,0 @@
---source ../../include/deinit_spider.inc
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_3.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_3.inc
deleted file mode 100644
index c19e376d10a..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_child3_3.inc
+++ /dev/null
@@ -1 +0,0 @@
---source ../../include/deinit_spider.inc
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_deinit_master_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_deinit_master_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_deinit_master_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child2_1.inc
deleted file mode 100644
index 2684829408d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_1.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-let $CHILD2_1_HA_AS_DROP_TABLES=
- $CHILD2_1_DROP_TABLES;
-let $CHILD2_1_HA_AS_CREATE_TABLES=
- $CHILD2_1_CREATE_TABLES;
-let $CHILD2_1_HA_AS_DROP_TABLES2=
- $CHILD2_1_DROP_TABLES2;
-let $CHILD2_1_HA_AS_CREATE_TABLES2=
- $CHILD2_1_CREATE_TABLES2;
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child2_2.inc
deleted file mode 100644
index 205eaa6fe35..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_2.inc
+++ /dev/null
@@ -1,4 +0,0 @@
-let $CHILD2_2_HA_DROP_TABLES=
- $CHILD2_2_DROP_TABLES;
-let $CHILD2_2_HA_CREATE_TABLES=
- $CHILD2_2_CREATE_TABLES;
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child2_3.inc
deleted file mode 100644
index 55cb858372c..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child2_3.inc
+++ /dev/null
@@ -1,4 +0,0 @@
-let $CHILD2_3_HA_DROP_TABLES=
- $CHILD2_3_DROP_TABLES;
-let $CHILD2_3_HA_CREATE_TABLES=
- $CHILD2_3_CREATE_TABLES;
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child3_1.inc
deleted file mode 100644
index 3ac4f97b1e0..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_1.inc
+++ /dev/null
@@ -1,140 +0,0 @@
---let $CHILD3_1_ENGINE_TYPE=Spider
---let $CHILD3_1_ENGINE=ENGINE=Spider
---source ../../include/init_spider.inc
-eval INSERT INTO mysql.spider_link_mon_servers
-(db_name, table_name, link_id, sid, server, scheme, host, port, socket,
- username, password, ssl_ca, ssl_capath, ssl_cert, ssl_cipher, ssl_key,
- ssl_verify_server_cert, default_file, default_group) VALUES
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_1_SERVER_ID, 's_3_1', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_2_SERVER_ID, 's_3_2', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_3_SERVER_ID, 's_3_3', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL);
-let $CHILD3_1_CHECK_LINK_STATUS=
- SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
- ORDER BY db_name, table_name, link_id;
-let $CHILD3_1_CHECK_LINK_FAILED_LOG=
- SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-let $CHILD3_1_SET_RECOVERY_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 2"';
-let $CHILD3_1_SET_OK_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 1"';
-let $CHILD3_1_SET_OK_STATUS_AS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2", lst "1 0"';
-
-let $CHILD3_1_DROP_TABLES_HA_2_1=
- DROP TABLE IF EXISTS ta_l;
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_1_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_1_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_1_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_1_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-let $CHILD3_1_DROP_TABLES_HA_P_2_1=
- DROP TABLE IF EXISTS ta_l2;
-let $CHILD3_1_CREATE_TABLES_HA_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_1_CREATE_TABLES_HA_AS_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_1_ENGINE $CHILD3_1_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_1_SET_RECOVERY_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 2"'
- );
-let $CHILD3_1_SET_OK_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 1"'
- );
-let $CHILD3_1_SET_OK_STATUS_AS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "1 0"'
- );
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_2.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child3_2.inc
deleted file mode 100644
index cf47099f439..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_2.inc
+++ /dev/null
@@ -1,140 +0,0 @@
---let $CHILD3_2_ENGINE_TYPE=Spider
---let $CHILD3_2_ENGINE=ENGINE=Spider
---source ../../include/init_spider.inc
-eval INSERT INTO mysql.spider_link_mon_servers
-(db_name, table_name, link_id, sid, server, scheme, host, port, socket,
- username, password, ssl_ca, ssl_capath, ssl_cert, ssl_cipher, ssl_key,
- ssl_verify_server_cert, default_file, default_group) VALUES
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_1_SERVER_ID, 's_3_1', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_2_SERVER_ID, 's_3_2', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_3_SERVER_ID, 's_3_3', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL);
-let $CHILD3_2_CHECK_LINK_STATUS=
- SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
- ORDER BY db_name, table_name, link_id;
-let $CHILD3_2_CHECK_LINK_FAILED_LOG=
- SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-let $CHILD3_2_SET_RECOVERY_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 2"';
-let $CHILD3_2_SET_OK_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 1"';
-let $CHILD3_2_SET_OK_STATUS_AS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2", lst "1 0"';
-
-let $CHILD3_2_DROP_TABLES_HA_2_1=
- DROP TABLE IF EXISTS ta_l;
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_2_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_2_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_2_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_2_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-let $CHILD3_2_DROP_TABLES_HA_P_2_1=
- DROP TABLE IF EXISTS ta_l2;
-let $CHILD3_2_CREATE_TABLES_HA_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_2_CREATE_TABLES_HA_AS_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_2_ENGINE $CHILD3_2_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_2_SET_RECOVERY_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 2"'
- );
-let $CHILD3_2_SET_OK_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 1"'
- );
-let $CHILD3_2_SET_OK_STATUS_AS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "1 0"'
- );
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_3.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_child3_3.inc
deleted file mode 100644
index 094d26b62c6..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_child3_3.inc
+++ /dev/null
@@ -1,140 +0,0 @@
---let $CHILD3_3_ENGINE_TYPE=Spider
---let $CHILD3_3_ENGINE=ENGINE=Spider
---source ../../include/init_spider.inc
-eval INSERT INTO mysql.spider_link_mon_servers
-(db_name, table_name, link_id, sid, server, scheme, host, port, socket,
- username, password, ssl_ca, ssl_capath, ssl_cert, ssl_cipher, ssl_key,
- ssl_verify_server_cert, default_file, default_group) VALUES
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_1_SERVER_ID, 's_3_1', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_2_SERVER_ID, 's_3_2', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_3_SERVER_ID, 's_3_3', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL);
-let $CHILD3_3_CHECK_LINK_STATUS=
- SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
- ORDER BY db_name, table_name, link_id;
-let $CHILD3_3_CHECK_LINK_FAILED_LOG=
- SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-let $CHILD3_3_SET_RECOVERY_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 2"';
-let $CHILD3_3_SET_OK_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 1"';
-let $CHILD3_3_SET_OK_STATUS_AS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2", lst "1 0"';
-
-let $CHILD3_3_DROP_TABLES_HA_2_1=
- DROP TABLE IF EXISTS ta_l;
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_3_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_3_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $CHILD3_3_CREATE_TABLES_HA_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $CHILD3_3_CREATE_TABLES_HA_AS_2_1=
- CREATE TABLE ta_l (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-let $CHILD3_3_DROP_TABLES_HA_P_2_1=
- DROP TABLE IF EXISTS ta_l2;
-let $CHILD3_3_CREATE_TABLES_HA_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_3_CREATE_TABLES_HA_AS_P_2_1=
- CREATE TABLE ta_l2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD3_3_ENGINE $CHILD3_3_CHARSET
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $CHILD3_3_SET_RECOVERY_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 2"'
- );
-let $CHILD3_3_SET_OK_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 1"'
- );
-let $CHILD3_3_SET_OK_STATUS_AS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "1 0"'
- );
diff --git a/storage/spider/mysql-test/spider/handler/include/ha_init_master_1.inc b/storage/spider/mysql-test/spider/handler/include/ha_init_master_1.inc
deleted file mode 100644
index 78797d80ce7..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/ha_init_master_1.inc
+++ /dev/null
@@ -1,105 +0,0 @@
-eval INSERT INTO mysql.spider_link_mon_servers
-(db_name, table_name, link_id, sid, server, scheme, host, port, socket,
- username, password, ssl_ca, ssl_capath, ssl_cert, ssl_cipher, ssl_key,
- ssl_verify_server_cert, default_file, default_group) VALUES
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_1_SERVER_ID, 's_3_1', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_2_SERVER_ID, 's_3_2', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL),
-('%auto_test_local%', '%ta_l%', '%', $CHILD3_3_SERVER_ID, 's_3_3', NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL);
-let $MASTER_1_CHECK_LINK_STATUS=
- SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
- ORDER BY db_name, table_name, link_id;
-let $MASTER_1_CHECK_LINK_FAILED_LOG=
- SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-let $MASTER_1_SET_RECOVERY_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 2"';
-let $MASTER_1_SET_OK_STATUS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 1"';
-let $MASTER_1_SET_OK_STATUS_AS_2_1=
- ALTER TABLE ta_l
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2", lst "1 0"';
-let $MASTER_1_COPY_TABLES_2_1=
- SELECT spider_copy_tables('ta_l', '0', '1');
-
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_HA_2_1=
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $MASTER_1_COMMENT_HA_AS_2_1=
- COMMENT='port "$CHILD2_1_MYPORT $CHILD2_2_MYPORT", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_HA_2_1=
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2",
- database "auto_test_remote auto_test_remote2"';
- let $MASTER_1_COMMENT_HA_AS_2_1=
- COMMENT='socket "$CHILD2_1_MYSOCK $CHILD2_2_MYSOCK", table "ta_r ta_r3"'
- CONNECTION='host "localhost", user "root", password "",
- msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2"';
-}
-let $MASTER_1_COMMENT_HA_P_2_1=
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $MASTER_1_COMMENT_HA_AS_P_2_1=
- COMMENT='msi "$CHILD3_1_SERVER_ID", mkd "2", alc "1"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001"'
- );
-let $MASTER_1_SET_RECOVERY_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 2"'
- );
-let $MASTER_1_SET_OK_STATUS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 1"'
- );
-let $MASTER_1_SET_OK_STATUS_AS_P_2_1=
- ALTER TABLE ta_l2
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "1 0"'
- );
-let $MASTER_1_COPY_TABLES_P_2_1=
- SELECT spider_copy_tables('ta_l2#P#pt2', '0', '1');
-let $MASTER_1_CHECK_HA_STATUS=
- SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-let $MASTER_1_CHANGE_HA_MON=
- SELECT spider_flush_table_mon_cache();
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_2.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_2.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_deinit_child2_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_deinit_master_1.inc b/storage/spider/mysql-test/spider/handler/include/hs_deinit_master_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_deinit_master_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/hs_init_child2_1.inc
deleted file mode 100644
index ee006858b06..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_1.inc
+++ /dev/null
@@ -1,24 +0,0 @@
-let $CHILD2_1_HS_DROP_TABLES=
- DROP TABLE IF EXISTS hs_r;
-let $CHILD2_1_HS_CREATE_TABLES=
- CREATE TABLE hs_r (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- d INT DEFAULT 11,
- PRIMARY KEY(a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_HS_SELECT_TABLES=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s'), d FROM hs_r ORDER BY a;
-let $CHILD2_1_HS_DROP_TABLES2=
- DROP TABLE IF EXISTS hs_r2;
-let $CHILD2_1_HS_CREATE_TABLES2=
- CREATE TABLE hs_r2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- d INT DEFAULT 11,
- PRIMARY KEY(a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_HS_SELECT_TABLES2=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s'), d FROM hs_r2 ORDER BY a;
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/hs_init_child2_2.inc
deleted file mode 100644
index 1c5a02d50c8..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_2.inc
+++ /dev/null
@@ -1,12 +0,0 @@
-let $CHILD2_2_HS_DROP_TABLES=
- DROP TABLE IF EXISTS hs_r3;
-let $CHILD2_2_HS_CREATE_TABLES=
- CREATE TABLE hs_r3 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- d INT DEFAULT 11,
- PRIMARY KEY(a)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_HS_SELECT_TABLES=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s'), d FROM hs_r3 ORDER BY a;
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/hs_init_child2_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_init_child2_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/hs_init_master_1.inc b/storage/spider/mysql-test/spider/handler/include/hs_init_master_1.inc
deleted file mode 100644
index 0ff5e2a10d9..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/hs_init_master_1.inc
+++ /dev/null
@@ -1,12 +0,0 @@
-let $MASTER_1_HS_COMMENT_TMP=
- COMMENT='';
-let $MASTER_1_HS_COMMENT_2_1=
- COMMENT='srv "s_2_1", table "hs_r", uhr "1", uhw "1", hrp "$CHILD2_1_HSRPORT", hwp "$CHILD2_1_HSWPORT"';
-let $MASTER_1_HS_COMMENT_P_2_1=
- COMMENT='uhr "1", uhw "1"'
- PARTITION BY RANGE(a) (
- PARTITION pt1 VALUES LESS THAN (4)
- COMMENT='srv "s_2_1", table "hs_r2", hrp "$CHILD2_1_HSRPORT", hwp "$CHILD2_1_HSWPORT"',
- PARTITION pt2 VALUES LESS THAN MAXVALUE
- COMMENT='srv "s_2_2", table "hs_r3", hrp "$CHILD2_2_HSRPORT", hwp "$CHILD2_2_HSWPORT"'
- );
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child2_1.inc b/storage/spider/mysql-test/spider/handler/include/init_child2_1.inc
deleted file mode 100644
index b8b8ceb9875..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child2_1.inc
+++ /dev/null
@@ -1,176 +0,0 @@
-let $CHILD2_1_DROP_TABLES=
- DROP TABLE IF EXISTS ta_r;
-let $CHILD2_1_CREATE_TABLES=
- CREATE TABLE ta_r (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a),
- KEY idx1(b)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r ORDER BY a;
-let $CHILD2_1_DROP_TABLES2=
- DROP TABLE IF EXISTS ta_r2;
-let $CHILD2_1_CREATE_TABLES2=
- CREATE TABLE ta_r2 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES2=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r2 ORDER BY a;
-let $CHILD2_1_DROP_TABLES3=
- DROP TABLE IF EXISTS ta_r_no_idx;
-let $CHILD2_1_CREATE_TABLES3=
- CREATE TABLE ta_r_no_idx (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10'
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES3=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r_no_idx ORDER BY a;
-let $CHILD2_1_DROP_TABLES4=
- DROP TABLE IF EXISTS ta_r_auto_inc;
-let $CHILD2_1_CREATE_TABLES4=
- CREATE TABLE ta_r_auto_inc (
- a INT AUTO_INCREMENT,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES4=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r_auto_inc
- ORDER BY a;
-let $CHILD2_1_DROP_TABLES5=
- DROP TABLE IF EXISTS ta_r_int;
-let $CHILD2_1_CREATE_TABLES5=
- CREATE TABLE ta_r_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES5=
- SELECT a, b, c FROM ta_r_int ORDER BY a;
-let $CHILD2_1_DROP_TABLES6=
- DROP TABLE IF EXISTS ta_r_3;
-let $CHILD2_1_CREATE_TABLES6=
- CREATE TABLE ta_r_3 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TABLES6=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r_3 ORDER BY a;
-let $CHILD2_1_DROP_FT_TABLES=
- DROP TABLE IF EXISTS ft_r;
-let $CHILD2_1_CREATE_FT_TABLES=
- CREATE TABLE ft_r (
- a INT DEFAULT 0,
- b TEXT,
- c TEXT,
- d TEXT,
- PRIMARY KEY(a),
- FULLTEXT INDEX ft_idx1(b),
- FULLTEXT INDEX ft_idx2(c)
- ) $CHILD2_1_FT_ENGINE $CHILD2_1_FT_CHARSET;
-let $CHILD2_1_SELECT_FT_TABLES=
- SELECT a, b, c, d FROM ft_r ORDER BY a;
-let $CHILD2_1_DROP_FT_TABLES2=
- DROP TABLE IF EXISTS ft_r2;
-let $CHILD2_1_CREATE_FT_TABLES2=
- CREATE TABLE ft_r2 (
- a INT DEFAULT 0,
- b TEXT,
- c TEXT,
- d TEXT,
- PRIMARY KEY(a),
- FULLTEXT INDEX ft_idx1(b),
- FULLTEXT INDEX ft_idx2(c)
- ) $CHILD2_1_FT_ENGINE $CHILD2_1_FT_CHARSET;
-let $CHILD2_1_SELECT_FT_TABLES2=
- SELECT a, b, c, d FROM ft_r2 ORDER BY a;
-let $CHILD2_1_DROP_GM_TABLES=
- DROP TABLE IF EXISTS gm_r;
-let $CHILD2_1_CREATE_GM_TABLES=
- CREATE TABLE gm_r (
- a INT DEFAULT 0,
- b GEOMETRY NOT NULL,
- c GEOMETRY NOT NULL,
- PRIMARY KEY(a),
- SPATIAL INDEX sp_idx1(b),
- SPATIAL INDEX sp_idx2(c)
- ) $CHILD2_1_GM_ENGINE $CHILD2_1_GM_CHARSET;
-let $CHILD2_1_SELECT_GM_TABLES=
- SELECT a, b, c FROM gm_r ORDER BY a;
-let $CHILD2_1_DROP_GM_TABLES2=
- DROP TABLE IF EXISTS gm_r2;
-let $CHILD2_1_CREATE_GM_TABLES2=
- CREATE TABLE gm_r2 (
- a INT DEFAULT 0,
- b GEOMETRY NOT NULL,
- c GEOMETRY NOT NULL,
- PRIMARY KEY(a),
- SPATIAL INDEX sp_idx1(b),
- SPATIAL INDEX sp_idx2(c)
- ) $CHILD2_1_GM_ENGINE $CHILD2_1_GM_CHARSET;
-let $CHILD2_1_SELECT_GM_TABLES2=
- SELECT a, b, c FROM gm_r2 ORDER BY a;
-let $CHILD2_1_DROP_LOCK_TABLES1=
- DROP TABLE IF EXISTS t1_1;
-let $CHILD2_1_CREATE_LOCK_TABLES1=
- CREATE TABLE t1_1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_DROP_LOCK_TABLES2=
- DROP TABLE IF EXISTS t2_2;
-let $CHILD2_1_CREATE_LOCK_TABLES2=
- CREATE TABLE t2_2 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_DROP_INCREMENT_TABLES1=
- DROP TABLE IF EXISTS t1_1;
-let $CHILD2_1_CREATE_INCREMENT_TABLES1=
- CREATE TABLE t1_1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_INCREMENT_TABLES1=
- SELECT id FROM t1_1 ORDER BY id;
-let $CHILD2_1_DROP_TEXT_PK_TABLES1=
- DROP TABLE IF EXISTS t1;
-let $CHILD2_1_CREATE_TEXT_PK_TABLES1=
- CREATE TABLE t1 (
- a VARCHAR(255),
- PRIMARY KEY (a)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET2;
-let $CHILD2_1_SELECT_TEXT_PK_TABLES1=
- SELECT a FROM t1 ORDER BY a;
-let $CHILD2_1_DROP_TEXT_KEY_TABLES1=
- DROP TABLE IF EXISTS t1;
-let $CHILD2_1_CREATE_TEXT_KEY_TABLES1=
- CREATE TABLE t1 (
- a VARCHAR(255),
- b VARCHAR(255),
- c VARCHAR(255),
- KEY idx1(a,b),
- KEY idx2(b),
- PRIMARY KEY(c)
- ) $CHILD2_1_ENGINE $CHILD2_1_CHARSET;
-let $CHILD2_1_SELECT_TEXT_KEY_TABLES1=
- SELECT a, b FROM t1 ORDER BY a, b;
-let $CHILD2_1_AUTO_INCREMENT_INCREMENT1=
- SET GLOBAL AUTO_INCREMENT_INCREMENT = 1;
-let $CHILD2_1_AUTO_INCREMENT_INCREMENT2=
- SET GLOBAL AUTO_INCREMENT_INCREMENT = 4;
-let $CHILD2_1_AUTO_INCREMENT_OFFSET1=
- SET GLOBAL AUTO_INCREMENT_OFFSET = 1;
-let $CHILD2_1_AUTO_INCREMENT_OFFSET2=
- SET GLOBAL AUTO_INCREMENT_OFFSET = 2;
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child2_2.inc b/storage/spider/mysql-test/spider/handler/include/init_child2_2.inc
deleted file mode 100644
index 9f0b5e2fe5a..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child2_2.inc
+++ /dev/null
@@ -1,80 +0,0 @@
-let $CHILD2_2_DROP_TABLES=
- DROP TABLE IF EXISTS ta_r3;
-let $CHILD2_2_CREATE_TABLES=
- CREATE TABLE ta_r3 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_DROP_TABLES5=
- DROP TABLE IF EXISTS ta_r_int;
-let $CHILD2_2_CREATE_TABLES5=
- CREATE TABLE ta_r_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_SELECT_TABLES=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r3 ORDER BY a;
-let $CHILD2_2_DROP_FT_TABLES=
- DROP TABLE IF EXISTS ft_r3;
-let $CHILD2_2_CREATE_FT_TABLES=
- CREATE TABLE ft_r3 (
- a INT DEFAULT 0,
- b TEXT,
- c TEXT,
- d TEXT,
- PRIMARY KEY(a),
- FULLTEXT INDEX ft_idx1(b),
- FULLTEXT INDEX ft_idx2(c)
- ) $CHILD2_2_FT_ENGINE $CHILD2_2_FT_CHARSET;
-let $CHILD2_2_SELECT_FT_TABLES=
- SELECT a, b, c, d FROM ft_r3 ORDER BY a;
-let $CHILD2_2_DROP_GM_TABLES=
- DROP TABLE IF EXISTS gm_r3;
-let $CHILD2_2_CREATE_GM_TABLES=
- CREATE TABLE gm_r3 (
- a INT DEFAULT 0,
- b GEOMETRY NOT NULL,
- c GEOMETRY NOT NULL,
- PRIMARY KEY(a),
- SPATIAL INDEX sp_idx1(b),
- SPATIAL INDEX sp_idx2(c)
- ) $CHILD2_2_GM_ENGINE $CHILD2_2_GM_CHARSET;
-let $CHILD2_2_SELECT_GM_TABLES=
- SELECT a, b, c FROM gm_r3 ORDER BY a;
-let $CHILD2_2_DROP_LOCK_TABLES1=
- DROP TABLE IF EXISTS t1_2;
-let $CHILD2_2_CREATE_LOCK_TABLES1=
- CREATE TABLE t1_2 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_DROP_LOCK_TABLES2=
- DROP TABLE IF EXISTS t2_1;
-let $CHILD2_2_CREATE_LOCK_TABLES2=
- CREATE TABLE t2_1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_DROP_INCREMENT_TABLES1=
- DROP TABLE IF EXISTS t1_2;
-let $CHILD2_2_CREATE_INCREMENT_TABLES1=
- CREATE TABLE t1_2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $CHILD2_2_ENGINE $CHILD2_2_CHARSET;
-let $CHILD2_2_SELECT_INCREMENT_TABLES1=
- SELECT id FROM t1_2 ORDER BY id;
-let $CHILD2_2_AUTO_INCREMENT_INCREMENT1=
- SET GLOBAL AUTO_INCREMENT_INCREMENT = 1;
-let $CHILD2_2_AUTO_INCREMENT_INCREMENT2=
- SET GLOBAL AUTO_INCREMENT_INCREMENT = 4;
-let $CHILD2_2_AUTO_INCREMENT_OFFSET1=
- SET GLOBAL AUTO_INCREMENT_OFFSET = 1;
-let $CHILD2_2_AUTO_INCREMENT_OFFSET2=
- SET GLOBAL AUTO_INCREMENT_OFFSET = 3;
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child2_3.inc b/storage/spider/mysql-test/spider/handler/include/init_child2_3.inc
deleted file mode 100644
index 05dbb1c3dd1..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child2_3.inc
+++ /dev/null
@@ -1,11 +0,0 @@
-let $CHILD2_3_DROP_TABLES=
- DROP TABLE IF EXISTS ta_r4;
-let $CHILD2_3_CREATE_TABLES=
- CREATE TABLE ta_r4 (
- a INT DEFAULT 10,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $CHILD2_3_ENGINE $CHILD2_3_CHARSET;
-let $CHILD2_3_SELECT_TABLES=
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_r4 ORDER BY a;
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child3_1.inc b/storage/spider/mysql-test/spider/handler/include/init_child3_1.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child3_1.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child3_2.inc b/storage/spider/mysql-test/spider/handler/include/init_child3_2.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child3_2.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/init_child3_3.inc b/storage/spider/mysql-test/spider/handler/include/init_child3_3.inc
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_child3_3.inc
+++ /dev/null
diff --git a/storage/spider/mysql-test/spider/handler/include/init_master_1.inc b/storage/spider/mysql-test/spider/handler/include/init_master_1.inc
deleted file mode 100644
index 9c487bc73fe..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_master_1.inc
+++ /dev/null
@@ -1,186 +0,0 @@
---source ../../include/init_spider.inc
-SET spider_internal_sql_log_off= 0;
-SET spider_use_handler= 3;
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_2_1=
- COMMENT='database "auto_test_remote", table "ta_r"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password ""';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_2_1=
- COMMENT='database "auto_test_remote", table "ta_r"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password ""';
-}
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT2_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_no_idx"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password "", prt "2000000"';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT2_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_no_idx"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password "", prt "2000000"';
-}
-let $MASTER_1_COMMENT_P_2_1=
- COMMENT='table "ta_r3"'
- PARTITION BY KEY(a) (
- PARTITION pt1 COMMENT='srv "s_2_1", table "ta_r2",
- priority "1000"',
- PARTITION pt2 COMMENT='srv "s_2_2", priority "1000001"'
- );
-let $MASTER_1_COMMENT2_P_2_1=
- COMMENT='table "ta_r3"'
- PARTITION BY RANGE(a) (
- PARTITION pt1 VALUES LESS THAN (4) COMMENT='srv "s_2_1",
- table "ta_r2", priority "1000"',
- PARTITION pt2 VALUES LESS THAN MAXVALUE
- COMMENT='srv "s_2_2", priority "1000001"'
- );
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT3_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_auto_inc"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password ""';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT3_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_auto_inc"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password ""';
-}
-let $MASTER_1_COMMENT3_P_2_1=
- COMMENT='table "ta_r_int"'
- PARTITION BY LIST(MOD(a, 2)) (
- PARTITION pt1 VALUES IN (0)
- COMMENT='srv "s_2_1", priority "1000"',
- PARTITION pt2 VALUES IN (1)
- COMMENT='srv "s_2_2", priority "1000001"'
- );
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT4_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_int"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password ""';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT4_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_int"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password ""';
-}
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT5_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_3"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password ""';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT5_2_1=
- COMMENT='database "auto_test_remote", table "ta_r_3"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password ""';
-}
-if ($VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_FT_2_1=
- COMMENT='database "auto_test_remote", table "ft_r"'
- CONNECTION='host "localhost", port "$CHILD2_1_MYPORT", user "root",
- password ""';
-}
-if (!$VERSION_COMPILE_OS_WIN)
-{
- let $MASTER_1_COMMENT_FT_2_1=
- COMMENT='database "auto_test_remote", table "ft_r"'
- CONNECTION='host "localhost", socket "$CHILD2_1_MYSOCK", user "root",
- password ""';
-}
-let $MASTER_1_COMMENT2_FT_P_2_1=
- COMMENT='table "ft_r3"'
- PARTITION BY RANGE(a) (
- PARTITION pt1 VALUES LESS THAN (4) COMMENT='srv "s_2_1",
- table "ft_r2", priority "1000"',
- PARTITION pt2 VALUES LESS THAN MAXVALUE
- COMMENT='srv "s_2_2", priority "1000001"'
- );
-let $MASTER_1_COMMENT_GM_2_1=
- COMMENT='srv "s_2_1", table "gm_r"';
-let $MASTER_1_COMMENT2_GM_P_2_1=
- COMMENT='table "gm_r3"'
- PARTITION BY RANGE(a) (
- PARTITION pt1 VALUES LESS THAN (4) COMMENT='srv "s_2_1",
- table "gm_r2", priority "1000"',
- PARTITION pt2 VALUES LESS THAN MAXVALUE
- COMMENT='srv "s_2_2", priority "1000001"'
- );
-let $MASTER_1_COMMENT_LOCK1=
- COMMENT 'tbl "t1_1 t1_2", srv "s_2_1 s_2_2"';
-let $MASTER_1_COMMENT_LOCK2=
- COMMENT 'tbl "t2_1 t2_2", srv "s_2_2 s_2_1"';
-let $MASTER_1_COMMENT_INCREMENT1_1=
- COMMENT 'aim "2", tbl "t1_1", srv "s_2_1"';
-let $MASTER_1_COMMENT_INCREMENT1_P_1=
- COMMENT 'aim "2"'
- PARTITION BY LIST(MOD(id, 2)) (
- PARTITION pt1 VALUES IN (0)
- COMMENT='tbl "t1_1", srv "s_2_1"',
- PARTITION pt2 VALUES IN (1)
- COMMENT='tbl "t1_2", srv "s_2_2"'
- );
-let $MASTER_1_COMMENT_READONLY1_1=
- COMMENT 'read_only_mode "1", tbl "t1_1", srv "s_2_1"';
-let $MASTER_1_COMMENT_ERROR_MODE1_1=
- COMMENT 'erm "1", ewm "1", tbl "ter1_1", srv "s_2_1"';
-let $MASTER_1_COMMENT_TEXT_PK1_1=
- COMMENT 'tbl "t1", srv "s_2_1"';
-let $MASTER_1_COMMENT_TEXT_KEY1_1=
- COMMENT 'tbl "t1", srv "s_2_1"';
-let $MASTER_1_CHECK_DIRECT_UPDATE_STATUS=
- SHOW STATUS LIKE 'Spider_direct_update';
-let $MASTER_1_CHECK_DIRECT_DELETE_STATUS=
- SHOW STATUS LIKE 'Spider_direct_delete';
-let $MASTER_1_CHECK_DIRECT_ORDER_LIMIT_STATUS=
- SHOW STATUS LIKE 'Spider_direct_order_limit';
-let $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS=
- SHOW STATUS LIKE 'Spider_direct_aggregate';
-let $MASTER_1_AUTO_INCREMENT_INCREMENT1=
- SET SESSION AUTO_INCREMENT_INCREMENT = 1 $STR_SEMICOLON
- SELECT spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 1', '',
- 'srv "s_2_1"') $STR_SEMICOLON
- SELECT spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 1', '',
- 'srv "s_2_2"');
-let $MASTER_1_AUTO_INCREMENT_INCREMENT2=
- SET SESSION AUTO_INCREMENT_INCREMENT = 777 $STR_SEMICOLON
- SELECT spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
- 'srv "s_2_1"') $STR_SEMICOLON
- SELECT spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
- 'srv "s_2_2"');
-let $MASTER_1_AUTO_INCREMENT_OFFSET1=
- SET SESSION AUTO_INCREMENT_OFFSET = 1 $STR_SEMICOLON
- SELECT spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 1', '',
- 'srv "s_2_1"') $STR_SEMICOLON
- SELECT spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 1', '',
- 'srv "s_2_2"');
-let $MASTER_1_AUTO_INCREMENT_OFFSET2=
- SET SESSION AUTO_INCREMENT_OFFSET = 777 $STR_SEMICOLON
- SELECT spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 2', '',
- 'srv "s_2_1"') $STR_SEMICOLON
- SELECT spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 3', '',
- 'srv "s_2_2"');
-let $MASTER_1_AUTO_INCREMENT_OFFSET3=
- SET SESSION AUTO_INCREMENT_OFFSET = 1;
-let $MASTER_1_AUTO_INCREMENT_OFFSET4=
- SET SESSION AUTO_INCREMENT_OFFSET = 777;
diff --git a/storage/spider/mysql-test/spider/handler/include/init_slave1_1.inc b/storage/spider/mysql-test/spider/handler/include/init_slave1_1.inc
deleted file mode 100644
index 73c3c6b9ef2..00000000000
--- a/storage/spider/mysql-test/spider/handler/include/init_slave1_1.inc
+++ /dev/null
@@ -1,10 +0,0 @@
-let $SLAVE1_1_COMMENT_INCREMENT1_1=
- COMMENT '';
-let $SLAVE1_1_COMMENT_INCREMENT1_P_1=
- COMMENT ''
- PARTITION BY LIST(MOD(id, 2)) (
- PARTITION pt1 VALUES IN (0)
- COMMENT='',
- PARTITION pt2 VALUES IN (1)
- COMMENT=''
- );
diff --git a/storage/spider/mysql-test/spider/handler/my.cnf b/storage/spider/mysql-test/spider/handler/my.cnf
deleted file mode 100644
index 89b91e6a5bd..00000000000
--- a/storage/spider/mysql-test/spider/handler/my.cnf
+++ /dev/null
@@ -1,176 +0,0 @@
-# Use default setting for mysqld processes
-!include include/default_mysqld.cnf
-
-[mysqld.1.1]
-loose_handlersocket_port= 20000
-loose_handlersocket_port_wr= 20001
-loose_handlersocket_threads= 2
-loose_handlersocket_threads_wr= 1
-loose_handlersocket_support_merge_table= 0
-loose_handlersocket_direct_update_mode= 0
-loose_handlersocket_unlimited_boundary= 65536
-loose_handlersocket_bulk_insert= 0
-loose_handlersocket_bulk_insert_timeout= 0
-loose_handlersocket_general_log= 1
-loose_handlersocket_timeout= 30
-loose_handlersocket_close_table_interval=2
-open_files_limit= 4096
-loose_partition= 1
-
-[mysqld.2.1]
-loose_handlersocket_port= 20002
-loose_handlersocket_port_wr= 20003
-loose_handlersocket_threads= 2
-loose_handlersocket_threads_wr= 1
-loose_handlersocket_support_merge_table= 0
-loose_handlersocket_direct_update_mode= 0
-loose_handlersocket_unlimited_boundary= 65536
-loose_handlersocket_bulk_insert= 0
-loose_handlersocket_bulk_insert_timeout= 0
-loose_handlersocket_general_log= 1
-loose_handlersocket_timeout= 30
-loose_handlersocket_close_table_interval=2
-open_files_limit= 4096
-
-[mysqld.2.2]
-loose_handlersocket_port= 20004
-loose_handlersocket_port_wr= 20005
-loose_handlersocket_threads= 2
-loose_handlersocket_threads_wr= 1
-loose_handlersocket_support_merge_table= 0
-loose_handlersocket_direct_update_mode= 0
-loose_handlersocket_unlimited_boundary= 65536
-loose_handlersocket_bulk_insert= 0
-loose_handlersocket_bulk_insert_timeout= 0
-loose_handlersocket_general_log= 1
-loose_handlersocket_timeout= 30
-loose_handlersocket_close_table_interval=2
-open_files_limit= 4096
-
-[mysqld.2.3]
-
-[mysqld.3.1]
-loose_partition= 1
-
-[mysqld.3.2]
-loose_partition= 1
-
-[mysqld.3.3]
-loose_partition= 1
-
-[mysqld.4.1]
-loose_partition= 1
-
-
-[ENV]
-USE_GEOMETRY_TEST= 1
-USE_FULLTEXT_TEST= 1
-USE_HA_TEST= 1
-USE_GENERAL_LOG= 1
-USE_REPLICATION= 1
-MASTER_1_MYPORT= @mysqld.1.1.port
-MASTER_1_HSRPORT= 20000
-MASTER_1_HSWPORT= 20001
-MASTER_1_MYSOCK= @mysqld.1.1.socket
-MASTER_1_ENGINE_TYPE= Spider
-#MASTER_1_ENGINE_TYPE= MyISAM
-MASTER_1_ENGINE= ENGINE=Spider
-MASTER_1_CHARSET= DEFAULT CHARSET=utf8
-MASTER_1_ENGINE2= ENGINE=MyISAM
-MASTER_1_CHARSET2= DEFAULT CHARSET=utf8
-MASTER_1_CHARSET3= DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
-SLAVE1_1_MYPORT= @mysqld.4.1.port
-SLAVE1_1_MYSOCK= @mysqld.4.1.socket
-SLAVE1_1_ENGINE_TYPE= MyISAM
-SLAVE1_1_ENGINE= ENGINE=MyISAM
-SLAVE1_1_CHARSET= DEFAULT CHARSET=utf8
-USE_CHILD_GROUP2= 1
-OUTPUT_CHILD_GROUP2= 0
-CHILD2_1_MYPORT= @mysqld.2.1.port
-CHILD2_1_HSRPORT= 20002
-CHILD2_1_HSWPORT= 20003
-CHILD2_1_MYSOCK= @mysqld.2.1.socket
-CHILD2_1_ENGINE_TYPE= InnoDB
-CHILD2_1_ENGINE= ENGINE=InnoDB
-CHILD2_1_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_1_CHARSET2= DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
-CHILD2_2_MYPORT= @mysqld.2.2.port
-CHILD2_2_HSRPORT= 20004
-CHILD2_2_HSWPORT= 20005
-CHILD2_2_MYSOCK= @mysqld.2.2.socket
-CHILD2_2_ENGINE_TYPE= InnoDB
-CHILD2_2_ENGINE= ENGINE=InnoDB
-CHILD2_2_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_3_MYPORT= @mysqld.2.3.port
-CHILD2_3_MYSOCK= @mysqld.2.3.socket
-CHILD2_3_ENGINE_TYPE= InnoDB
-CHILD2_3_ENGINE= ENGINE=InnoDB
-CHILD2_3_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_1_FT_MYPORT= @mysqld.1.1.port
-CHILD2_1_FT_MYSOCK= @mysqld.1.1.socket
-CHILD2_1_FT_ENGINE_TYPE= MyISAM
-CHILD2_1_FT_ENGINE= ENGINE=MyISAM
-CHILD2_1_FT_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_2_FT_MYPORT= @mysqld.2.2.port
-CHILD2_2_FT_MYSOCK= @mysqld.2.2.socket
-CHILD2_2_FT_ENGINE_TYPE= MyISAM
-CHILD2_2_FT_ENGINE= ENGINE=MyISAM
-CHILD2_2_FT_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_1_GM_MYPORT= @mysqld.2.1.port
-CHILD2_1_GM_MYSOCK= @mysqld.2.1.socket
-CHILD2_1_GM_ENGINE_TYPE= MyISAM
-CHILD2_1_GM_ENGINE= ENGINE=MyISAM
-CHILD2_1_GM_CHARSET= DEFAULT CHARSET=utf8
-CHILD2_2_GM_MYPORT= @mysqld.2.2.port
-CHILD2_2_GM_MYSOCK= @mysqld.2.2.socket
-CHILD2_2_GM_ENGINE_TYPE= MyISAM
-CHILD2_2_GM_ENGINE= ENGINE=MyISAM
-CHILD2_2_GM_CHARSET= DEFAULT CHARSET=utf8
-USE_CHILD_GROUP3= 1
-OUTPUT_CHILD_GROUP3= 0
-CHILD3_1_MYPORT= @mysqld.3.1.port
-CHILD3_1_MYSOCK= @mysqld.3.1.socket
-CHILD3_1_ENGINE_TYPE= InnoDB
-CHILD3_1_ENGINE= ENGINE=InnoDB
-CHILD3_1_CHARSET= DEFAULT CHARSET=utf8
-CHILD3_2_MYPORT= @mysqld.3.2.port
-CHILD3_2_MYSOCK= @mysqld.3.2.socket
-CHILD3_2_ENGINE_TYPE= InnoDB
-CHILD3_2_ENGINE= ENGINE=InnoDB
-CHILD3_2_CHARSET= DEFAULT CHARSET=utf8
-CHILD3_3_MYPORT= @mysqld.3.3.port
-CHILD3_3_MYSOCK= @mysqld.3.3.socket
-CHILD3_3_ENGINE_TYPE= InnoDB
-CHILD3_3_ENGINE= ENGINE=InnoDB
-CHILD3_3_CHARSET= DEFAULT CHARSET=utf8
-
-STR_SEMICOLON= ;
-
-#The followings are set in include/init_xxx.inc files
-# MASTER_1_COMMENT_2_1
-# MASTER_1_COMMENT2_2_1
-# MASTER_1_COMMENT3_2_1
-# MASTER_1_COMMENT4_2_1
-# MASTER_1_COMMENT5_2_1
-# MASTER_1_COMMENT_P_2_1
-# CHILD2_1_DROP_TABLES
-# CHILD2_1_CREATE_TABLES
-# CHILD2_1_SELECT_TABLES
-# CHILD2_1_DROP_TABLES2
-# CHILD2_1_CREATE_TABLES2
-# CHILD2_1_SELECT_TABLES2
-# CHILD2_1_DROP_TABLES3
-# CHILD2_1_CREATE_TABLES3
-# CHILD2_1_SELECT_TABLES3
-# CHILD2_1_DROP_TABLES4
-# CHILD2_1_CREATE_TABLES4
-# CHILD2_1_SELECT_TABLES4
-# CHILD2_1_DROP_TABLES5
-# CHILD2_1_CREATE_TABLES5
-# CHILD2_1_SELECT_TABLES5
-# CHILD2_1_DROP_TABLES6
-# CHILD2_1_CREATE_TABLES6
-# CHILD2_1_SELECT_TABLES6
-# CHILD2_2_DROP_TABLES
-# CHILD2_2_CREATE_TABLES
-# CHILD2_2_SELECT_TABLES
diff --git a/storage/spider/mysql-test/spider/handler/r/basic_sql.result b/storage/spider/mysql-test/spider/handler/r/basic_sql.result
deleted file mode 100644
index 94a09fc317b..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/basic_sql.result
+++ /dev/null
@@ -1,738 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table select test
-connection master_1;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-SELECT a, b, c FROM tb_l
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-create table ignore select test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'f', '2008-07-01 10:21:39'),
-(2, 'g', '2000-02-01 00:00:00'),
-(3, 'j', '2007-05-04 20:03:11'),
-(4, 'i', '2003-10-30 05:01:03'),
-(5, 'h', '2001-10-31 23:59:59');
-CREATE TABLE ta_l (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-IGNORE SELECT a, b, c FROM tb_l
-Warnings:
-Warning 1062 Duplicate entry '1' for key 'PRIMARY'
-Warning 1062 Duplicate entry '2' for key 'PRIMARY'
-Warning 1062 Duplicate entry '3' for key 'PRIMARY'
-Warning 1062 Duplicate entry '4' for key 'PRIMARY'
-Warning 1062 Duplicate entry '5' for key 'PRIMARY'
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-create table ignore select test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-REPLACE SELECT a, b, c FROM tb_l
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-create no index table
-connection master_1;
-DROP TABLE IF EXISTS ta_l_no_idx;
-CREATE TABLE ta_l_no_idx
-MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT2_2_1
-SELECT a, b, c FROM tb_l
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l_no_idx ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select table
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select table shared mode
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a
-LOCK IN SHARE MODE;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select table for update
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a
-FOR UPDATE;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select table join
-connection master_1;
-SELECT a.a, a.b, date_format(b.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a, tb_l b
-WHERE a.a = b.a ORDER BY a.a;
-a b date_format(b.c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select table straight_join
-connection master_1;
-SELECT STRAIGHT_JOIN a.a, a.b, date_format(b.c, '%Y-%m-%d %H:%i:%s')
-FROM ta_l a, tb_l b WHERE a.a = b.a ORDER BY a.a;
-a b date_format(b.c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_small_result
-connection master_1;
-SELECT SQL_SMALL_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_big_result
-connection master_1;
-SELECT SQL_BIG_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_buffer_result
-connection master_1;
-SELECT SQL_BUFFER_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_cache
-connection master_1;
-SELECT SQL_CACHE a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_no_cache
-connection master_1;
-SELECT SQL_NO_CACHE a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select sql_calc_found_rows
-connection master_1;
-SELECT SQL_CALC_FOUND_ROWS a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a LIMIT 4;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-connection master_1;
-SELECT found_rows();
-found_rows()
-5
-
-select high_priority
-connection master_1;
-SELECT HIGH_PRIORITY a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select distinct
-connection master_1;
-SELECT DISTINCT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select count
-connection master_1;
-SELECT count(*) FROM ta_l ORDER BY a;
-count(*)
-5
-
-select table join not use index
-connection master_1;
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM tb_l a WHERE
-EXISTS (SELECT * FROM ta_l b WHERE b.b = a.b) ORDER BY a.a;
-a b date_format(a.c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select using pushdown
-connection master_1;
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a WHERE
-a.b = 'g' ORDER BY a.a;
-a b date_format(a.c, '%Y-%m-%d %H:%i:%s')
-2 g 2000-02-01 00:00:00
-
-select using index and pushdown
-connection master_1;
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a WHERE
-a.a > 0 AND a.b = 'g' ORDER BY a.a;
-a b date_format(a.c, '%Y-%m-%d %H:%i:%s')
-2 g 2000-02-01 00:00:00
-
-insert
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-
-insert select
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT INTO ta_l (a, b, c) SELECT a, b, c FROM tb_l;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-insert select a
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT INTO ta_l (a, b, c) VALUES ((SELECT a FROM tb_l ORDER BY a LIMIT 1),
-'e', '2008-01-01 23:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-
-insert low_priority
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT LOW_PRIORITY INTO ta_l (a, b, c) values (2, 'e', '2008-01-01 23:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-
-insert high_priority
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT HIGH_PRIORITY INTO ta_l (a, b, c) VALUES (2, 'e',
-'2008-01-01 23:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-
-insert ignore
-connection master_1;
-INSERT IGNORE INTO ta_l (a, b, c) VALUES (2, 'd', '2009-02-02 01:01:01');
-Warnings:
-Warning 1062 Duplicate entry '2' for key 'PRIMARY'
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-
-insert update (insert)
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59') ON DUPLICATE
-KEY UPDATE b = 'f', c = '2005-08-08 11:11:11';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-
-insert update (update)
-connection master_1;
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59') ON DUPLICATE
-KEY UPDATE b = 'f', c = '2005-08-08 11:11:11';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 f 2005-08-08 11:11:11
-
-replace
-connection master_1;
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59');
-connection master_1;
-REPLACE INTO ta_l (a, b, c) VALUES (2, 'f', '2008-02-02 02:02:02');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 f 2008-02-02 02:02:02
-
-replace select
-connection master_1;
-REPLACE INTO ta_l (a, b, c) SELECT a, b, c FROM tb_l;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-replace select a
-connection master_1;
-REPLACE INTO ta_l (a, b, c) VALUES ((SELECT a FROM tb_l ORDER BY a LIMIT 1),
-'e', '2008-01-01 23:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-replace low_priority
-connection master_1;
-REPLACE LOW_PRIORITY INTO ta_l (a, b, c) VALUES (3, 'g',
-'2009-03-03 03:03:03');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-2 g 2000-02-01 00:00:00
-3 g 2009-03-03 03:03:03
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-update
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59');
-connection master_1;
-UPDATE ta_l SET b = 'f', c = '2008-02-02 02:02:02' WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-2 f 2008-02-02 02:02:02
-
-update select
-connection master_1;
-UPDATE ta_l SET b = 'g', c = '2009-03-03 03:03:03' WHERE a IN (SELECT a FROM
-tb_l);
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 g 2009-03-03 03:03:03
-
-update select a
-connection master_1;
-UPDATE ta_l SET b = 'h', c = '2010-04-04 04:04:04' WHERE a = (SELECT a FROM
-tb_l ORDER BY a LIMIT 1);
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 h 2010-04-04 04:04:04
-2 g 2009-03-03 03:03:03
-
-update join
-connection master_1;
-UPDATE ta_l a, tb_l b SET a.b = b.b, a.c = b.c WHERE a.a = b.a;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-
-update join a
-connection master_1;
-UPDATE ta_l a, tb_l b SET a.b = 'g', a.c = '2009-03-03 03:03:03' WHERE
-a.a = b.a;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 g 2009-03-03 03:03:03
-
-update low_priority
-connection master_1;
-UPDATE LOW_PRIORITY ta_l SET b = 'f', c = '2008-02-02 02:02:02' WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 f 2008-02-02 02:02:02
-
-update ignore
-connection master_1;
-UPDATE IGNORE ta_l SET a = 1, b = 'g', c = '2009-03-03 03:03:03' WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 f 2008-02-02 02:02:02
-
-update pushdown
-connection master_1;
-update ta_l set b = 'j', c = '2009-03-03 03:03:03' where b = 'f';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 j 2009-03-03 03:03:03
-
-update index pushdown
-connection master_1;
-UPDATE ta_l SET b = 'g', c = '2009-03-03 03:03:03' WHERE a > 0 AND b = 'j';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 g 2009-03-03 03:03:03
-2 g 2009-03-03 03:03:03
-
-delete
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE FROM ta_l WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-3 e 2008-01-01 23:59:59
-4 e 2008-01-01 23:59:59
-5 e 2008-01-01 23:59:59
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete all
-connection master_1;
-DELETE FROM ta_l;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-
-delete select
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE FROM ta_l WHERE a IN (SELECT a FROM tb_l);
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete select a
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE FROM ta_l WHERE a = (SELECT a FROM tb_l ORDER BY a LIMIT 1);
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 e 2008-01-01 23:59:59
-3 e 2008-01-01 23:59:59
-4 e 2008-01-01 23:59:59
-5 e 2008-01-01 23:59:59
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete join
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE a FROM ta_l a, (SELECT a FROM tb_l ORDER BY a) b WHERE a.a = b.a;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete low_priority
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE LOW_PRIORITY FROM ta_l WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-3 e 2008-01-01 23:59:59
-4 e 2008-01-01 23:59:59
-5 e 2008-01-01 23:59:59
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete ignore
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE IGNORE FROM ta_l WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-3 e 2008-01-01 23:59:59
-4 e 2008-01-01 23:59:59
-5 e 2008-01-01 23:59:59
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete quick
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE QUICK FROM ta_l WHERE a = 2;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 e 2008-01-01 23:59:59
-3 e 2008-01-01 23:59:59
-4 e 2008-01-01 23:59:59
-5 e 2008-01-01 23:59:59
-6 e 2008-01-01 23:59:59
-7 e 2008-01-01 23:59:59
-8 e 2008-01-01 23:59:59
-9 e 2008-01-01 23:59:59
-10 j 2008-01-01 23:59:59
-
-delete pushdown
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE FROM ta_l WHERE b = 'e';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-10 j 2008-01-01 23:59:59
-
-delete index pushdown
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-connection master_1;
-DELETE FROM ta_l WHERE a > 0 AND b = 'e';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-10 j 2008-01-01 23:59:59
-
-truncate
-connection master_1;
-TRUNCATE TABLE ta_l;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/basic_sql_part.result b/storage/spider/mysql-test/spider/handler/r/basic_sql_part.result
deleted file mode 100644
index 0f4029404a7..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/basic_sql_part.result
+++ /dev/null
@@ -1,141 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-connection master_1;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'f', '2008-07-01 10:21:39'),
-(2, 'g', '2000-02-01 00:00:00'),
-(3, 'j', '2007-05-04 20:03:11'),
-(4, 'i', '2003-10-30 05:01:03'),
-(5, 'h', '2001-10-31 23:59:59');
-
-create table with partition and select test
-connection master_1;
-CREATE TABLE ta_l2 (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_COMMENT_P_2_1
-SELECT a, b, c FROM tb_l
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-select partition using pushdown
-connection master_1;
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 a WHERE
-a.b = 'g' ORDER BY a.a;
-a b date_format(a.c, '%Y-%m-%d %H:%i:%s')
-2 g 2000-02-01 00:00:00
-
-select partition using index pushdown
-connection master_1;
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 a WHERE
-a.a > 0 AND a.b = 'g' ORDER BY a.a;
-a b date_format(a.c, '%Y-%m-%d %H:%i:%s')
-2 g 2000-02-01 00:00:00
-
-update partition pushdown
-connection master_1;
-UPDATE ta_l2 SET b = 'e', c = '2009-03-03 03:03:03' WHERE b = 'j';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 e 2009-03-03 03:03:03
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-update partition index pushdown
-connection master_1;
-UPDATE ta_l2 SET b = 'j', c = '2009-03-03 03:03:03' WHERE a > 0 AND b = 'e';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-2 g 2000-02-01 00:00:00
-3 j 2009-03-03 03:03:03
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-delete partition pushdown
-TRUNCATE TABLE ta_l2;
-INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
-connection master_1;
-DELETE FROM ta_l2 WHERE b = 'g';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-delete partition index pushdown
-TRUNCATE TABLE ta_l2;
-INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
-connection master_1;
-DELETE FROM ta_l2 WHERE a > 0 AND b = 'g';
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 f 2008-07-01 10:21:39
-3 j 2007-05-04 20:03:11
-4 i 2003-10-30 05:01:03
-5 h 2001-10-31 23:59:59
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/direct_aggregate.result b/storage/spider/mysql-test/spider/handler/r/direct_aggregate.result
deleted file mode 100644
index 9a8660ba79e..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/direct_aggregate.result
+++ /dev/null
@@ -1,100 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table select test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-INSERT INTO ta_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-direct_aggregating test
-connection master_1;
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT COUNT(*) FROM ta_l;
-COUNT(*)
-5
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MAX(a) FROM ta_l;
-MAX(a)
-5
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MIN(a) FROM ta_l;
-MIN(a)
-1
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MAX(a) FROM ta_l WHERE a < 5;
-MAX(a)
-4
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MIN(a) FROM ta_l WHERE a > 1;
-MIN(a)
-2
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/direct_aggregate_part.result b/storage/spider/mysql-test/spider/handler/r/direct_aggregate_part.result
deleted file mode 100644
index 760b39e16d5..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/direct_aggregate_part.result
+++ /dev/null
@@ -1,90 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-with partition test
-connection master_1;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT COUNT(*) FROM ta_l2;
-COUNT(*)
-5
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MAX(a) FROM ta_l2;
-MAX(a)
-5
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MIN(a) FROM ta_l2;
-MIN(a)
-1
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MAX(a) FROM ta_l2 WHERE a < 5;
-MAX(a)
-4
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-SELECT MIN(a) FROM ta_l2 WHERE a > 1;
-MIN(a)
-2
-SHOW STATUS LIKE 'Spider_direct_aggregate';
-Variable_name Value
-Spider_direct_aggregate 0
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/direct_update.result b/storage/spider/mysql-test/spider/handler/r/direct_update.result
deleted file mode 100644
index 0e536d48617..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/direct_update.result
+++ /dev/null
@@ -1,155 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table select test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-INSERT INTO ta_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-direct_updating test
-connection master_1;
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 0
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-update all rows with function
-UPDATE ta_l SET c = ADDDATE(c, 1);
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 e 2007-06-05 20:03:11
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by primary key
-UPDATE ta_l SET b = 'x' WHERE a = 3;
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 2
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2007-06-05 20:03:11
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by a column without index
-UPDATE ta_l SET c = '2011-10-17' WHERE b = 'x';
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 3
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2011-10-17 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by primary key with order and limit
-UPDATE ta_l SET c = ADDDATE(c, 1) WHERE a < 4 ORDER BY b DESC LIMIT 1;
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 4
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-delete by primary key with order and limit
-DELETE FROM ta_l WHERE a < 4 ORDER BY c LIMIT 1;
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-delete by a column without index
-DELETE FROM ta_l WHERE b = 'c';
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 2
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-delete by primary key
-DELETE FROM ta_l WHERE a = 3;
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 3
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-4 d 2003-12-01 05:01:03
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/direct_update_part.result b/storage/spider/mysql-test/spider/handler/r/direct_update_part.result
deleted file mode 100644
index 7069cd72fda..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/direct_update_part.result
+++ /dev/null
@@ -1,145 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-with partition test
-connection master_1;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 0
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-update all rows with function
-UPDATE ta_l2 SET c = ADDDATE(c, 1);
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 2
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 e 2007-06-05 20:03:11
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by primary key
-UPDATE ta_l2 SET b = 'x' WHERE a = 3;
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 3
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2007-06-05 20:03:11
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by a column without index
-UPDATE ta_l2 SET c = '2011-10-17' WHERE b = 'x';
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 5
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2011-10-17 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-update by primary key with order and limit
-UPDATE ta_l2 SET c = ADDDATE(c, 1) WHERE a < 4 ORDER BY b DESC LIMIT 1;
-SHOW STATUS LIKE 'Spider_direct_update';
-Variable_name Value
-Spider_direct_update 6
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-2 b 2000-01-02 00:00:00
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-delete by primary key with order and limit
-DELETE FROM ta_l2 WHERE a < 4 ORDER BY c LIMIT 1;
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-5 c 2002-01-01 23:59:59
-delete by a column without index
-DELETE FROM ta_l2 WHERE b = 'c';
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 3
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-3 x 2011-10-18 00:00:00
-4 d 2003-12-01 05:01:03
-delete by primary key
-DELETE FROM ta_l2 WHERE a = 3;
-SHOW STATUS LIKE 'Spider_direct_delete';
-Variable_name Value
-Spider_direct_delete 4
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-02 10:21:39
-4 d 2003-12-01 05:01:03
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/function.result b/storage/spider/mysql-test/spider/handler/r/function.result
deleted file mode 100644
index c088a8a9541..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/function.result
+++ /dev/null
@@ -1,160 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-in()
-connection master_1;
-CREATE TABLE t1 (
-a VARCHAR(255),
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET3 MASTER_1_COMMENT_TEXT_PK1_1
-insert into t1 values ('1');
-insert into t1 select a + 1 from t1;
-insert into t1 select a + 2 from t1;
-insert into t1 select a + 4 from t1;
-insert into t1 select a + 8 from t1;
-insert into t1 select a + 16 from t1;
-insert into t1 select a + 32 from t1;
-insert into t1 select a + 64 from t1;
-insert into t1 select a + 128 from t1;
-insert into t1 select a + 256 from t1;
-insert into t1 select a + 512 from t1;
-flush tables;
-connection master_1;
-select a from t1 where a in ('15', '120');
-a
-120
-15
-
-date_sub()
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-INSERT INTO ta_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 YEAR);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-08-01 10:21:39
-2 b 1999-01-01 00:00:00
-3 e 2006-06-04 20:03:11
-4 d 2002-11-30 05:01:03
-5 c 2000-12-31 23:59:59
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 QUARTER);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-11-01 10:21:39
-2 b 1999-04-01 00:00:00
-3 e 2006-09-04 20:03:11
-4 d 2003-02-28 05:01:03
-5 c 2001-03-31 23:59:59
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 MONTH);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-01 10:21:39
-2 b 1999-03-01 00:00:00
-3 e 2006-08-04 20:03:11
-4 d 2003-01-28 05:01:03
-5 c 2001-02-28 23:59:59
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 WEEK);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-08 10:21:39
-2 b 1999-03-08 00:00:00
-3 e 2006-08-11 20:03:11
-4 d 2003-02-04 05:01:03
-5 c 2001-03-07 23:59:59
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 DAY);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-07 10:21:39
-2 b 1999-03-07 00:00:00
-3 e 2006-08-10 20:03:11
-4 d 2003-02-03 05:01:03
-5 c 2001-03-06 23:59:59
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 HOUR);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-07 11:21:39
-2 b 1999-03-07 01:00:00
-3 e 2006-08-10 21:03:11
-4 d 2003-02-03 06:01:03
-5 c 2001-03-07 00:59:59
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 MINUTE);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-07 11:20:39
-2 b 1999-03-07 00:59:00
-3 e 2006-08-10 21:02:11
-4 d 2003-02-03 06:00:03
-5 c 2001-03-07 00:58:59
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 SECOND);
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2007-10-07 11:20:40
-2 b 1999-03-07 00:59:01
-3 e 2006-08-10 21:02:12
-4 d 2003-02-03 06:00:04
-5 c 2001-03-07 00:59:00
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/ha.result b/storage/spider/mysql-test/spider/handler/r/ha.result
deleted file mode 100644
index f8833c229ef..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/ha.result
+++ /dev/null
@@ -1,266 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-connection child2_3;
-DROP DATABASE IF EXISTS auto_test_remote3;
-CREATE DATABASE auto_test_remote3;
-USE auto_test_remote3;
-connection child3_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child3_2;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child3_3;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_2_1
-INSERT INTO ta_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-select test
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-fail-over test
-connection master_1;
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 0
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-ERROR HY000: Table 'auto_test_remote2.ta_r3' get a problem
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l 0 1
-auto_test_local ta_l 1 3
-SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-db_name table_name link_id
-auto_test_local ta_l 1
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 1
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-6 e 2011-05-05 20:04:05
-
-recovery test
-connection master_1;
-ALTER TABLE ta_l
-CONNECTION='host "localhost", user "root", password "",
- msi "5", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 2"';
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l 0 1
-auto_test_local ta_l 1 2
-SELECT spider_copy_tables('ta_l', '0', '1');
-spider_copy_tables('ta_l', '0', '1')
-1
-connection master_1;
-ALTER TABLE ta_l
-CONNECTION='host "localhost", user "root", password "",
- msi "5", mkd "2",
- database "auto_test_remote auto_test_remote2", lst "0 1"';
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l 0 1
-auto_test_local ta_l 1 1
-INSERT INTO ta_l (a, b, c) VALUES
-(8, 'g', '2011-05-05 21:33:30');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-6 e 2011-05-05 20:04:05
-8 g 2011-05-05 21:33:30
-DROP TABLE ta_l;
-connection master_1;
-SELECT spider_flush_table_mon_cache();
-spider_flush_table_mon_cache()
-1
-
-active standby test
-create table test
-connection master_1;
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_AS_2_1
-INSERT INTO ta_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-select test
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-fail-over test
-connection master_1;
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 1
-Spider_mon_table_cache_version_req 2
-INSERT INTO ta_l (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-ERROR HY000: Table 'auto_test_remote.ta_r' get a problem
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l 0 3
-auto_test_local ta_l 1 1
-SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-db_name table_name link_id
-auto_test_local ta_l 1
-auto_test_local ta_l 0
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 2
-Spider_mon_table_cache_version_req 2
-INSERT INTO ta_l (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-6 e 2011-05-05 20:04:05
-
-recovery test
-connection master_1;
-ALTER TABLE ta_l
-CONNECTION='host "localhost", user "root", password "",
- msi "5", mkd "2", alc "1",
- database "auto_test_remote auto_test_remote2", lst "1 0"';
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l 0 1
-auto_test_local ta_l 1 1
-INSERT INTO ta_l (a, b, c) VALUES
-(8, 'g', '2011-05-05 21:33:30');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-8 g 2011-05-05 21:33:30
-DROP TABLE ta_l;
-connection master_1;
-SELECT spider_flush_table_mon_cache();
-spider_flush_table_mon_cache()
-1
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-connection child2_3;
-DROP DATABASE IF EXISTS auto_test_remote3;
-connection child3_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child3_2;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child3_3;
-DROP DATABASE IF EXISTS auto_test_local;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/ha_part.result b/storage/spider/mysql-test/spider/handler/r/ha_part.result
deleted file mode 100644
index 315f37298bc..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/ha_part.result
+++ /dev/null
@@ -1,286 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-connection child2_3;
-DROP DATABASE IF EXISTS auto_test_remote3;
-CREATE DATABASE auto_test_remote3;
-USE auto_test_remote3;
-connection child3_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child3_2;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child3_3;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table with partition test
-connection master_1;
-DROP TABLE IF EXISTS ta_l2;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_P_2_1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-select test
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-fail-over test
-connection master_1;
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 0
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-ERROR HY000: Table 'auto_test_remote3.ta_r4' get a problem
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l2#P#pt1 0 1
-auto_test_local ta_l2#P#pt1 1 1
-auto_test_local ta_l2#P#pt2 0 1
-auto_test_local ta_l2#P#pt2 1 3
-SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-db_name table_name link_id
-auto_test_local ta_l2#P#pt2 1
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 1
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-6 e 2011-05-05 20:04:05
-
-recovery test
-connection master_1;
-ALTER TABLE ta_l2
-PARTITION BY KEY(a) (
-PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
-PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 2"'
- );
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l2#P#pt1 0 1
-auto_test_local ta_l2#P#pt1 1 1
-auto_test_local ta_l2#P#pt2 0 1
-auto_test_local ta_l2#P#pt2 1 2
-SELECT spider_copy_tables('ta_l2#P#pt2', '0', '1');
-spider_copy_tables('ta_l2#P#pt2', '0', '1')
-1
-connection master_1;
-ALTER TABLE ta_l2
-PARTITION BY KEY(a) (
-PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
-PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "0 1"'
- );
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l2#P#pt1 0 1
-auto_test_local ta_l2#P#pt1 1 1
-auto_test_local ta_l2#P#pt2 0 1
-auto_test_local ta_l2#P#pt2 1 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(8, 'g', '2011-05-05 21:33:30'),
-(9, 'h', '2011-05-05 22:32:10');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-6 e 2011-05-05 20:04:05
-8 g 2011-05-05 21:33:30
-9 h 2011-05-05 22:32:10
-DROP TABLE ta_l2;
-
-create table with partition test
-connection master_1;
-DROP TABLE IF EXISTS ta_l2;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_AS_P_2_1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-select test
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-fail-over test
-connection master_1;
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 1
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-ERROR HY000: Table 'auto_test_remote.ta_r2' get a problem
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l2#P#pt1 0 1
-auto_test_local ta_l2#P#pt1 1 1
-auto_test_local ta_l2#P#pt2 0 3
-auto_test_local ta_l2#P#pt2 1 1
-SELECT db_name, table_name, link_id FROM mysql.spider_link_failed_log;
-db_name table_name link_id
-auto_test_local ta_l2#P#pt2 1
-auto_test_local ta_l2#P#pt2 0
-SHOW STATUS LIKE 'Spider_mon_table_cache_version%';
-Variable_name Value
-Spider_mon_table_cache_version 1
-Spider_mon_table_cache_version_req 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-3 e 2007-06-04 20:03:11
-5 c 2001-12-31 23:59:59
-6 e 2011-05-05 20:04:05
-
-recovery test
-connection master_1;
-ALTER TABLE ta_l2
-PARTITION BY KEY(a) (
-PARTITION pt1 COMMENT='srv "s_2_1 s_2_2", tbl "ta_r ta_r3",
- priority "1000"',
-PARTITION pt2 COMMENT='srv "s_2_1 s_2_3", tbl "ta_r2 ta_r4",
- priority "1000001", lst "1 0"'
- );
-SELECT db_name, table_name, link_id, link_status FROM mysql.spider_tables
-ORDER BY db_name, table_name, link_id;
-db_name table_name link_id link_status
-auto_test_local ta_l2#P#pt1 0 1
-auto_test_local ta_l2#P#pt1 1 1
-auto_test_local ta_l2#P#pt2 0 1
-auto_test_local ta_l2#P#pt2 1 1
-INSERT INTO ta_l2 (a, b, c) VALUES
-(8, 'g', '2011-05-05 21:33:30'),
-(9, 'h', '2011-05-05 22:32:10');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-3 e 2007-06-04 20:03:11
-5 c 2001-12-31 23:59:59
-8 g 2011-05-05 21:33:30
-9 h 2011-05-05 22:32:10
-DROP TABLE ta_l2;
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-connection child2_3;
-DROP DATABASE IF EXISTS auto_test_remote3;
-connection child3_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child3_2;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child3_3;
-DROP DATABASE IF EXISTS auto_test_local;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/spider3_fixes.result b/storage/spider/mysql-test/spider/handler/r/spider3_fixes.result
deleted file mode 100644
index abe543fe193..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/spider3_fixes.result
+++ /dev/null
@@ -1,245 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for slave1_1
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-3.1
-auto_increment
-connection master_1;
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-connection slave1_1;
-connection master_1;
-DROP TABLE IF EXISTS t1, t2;
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1
-CREATE TABLE t2 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1
-MASTER_1_AUTO_INCREMENT_INCREMENT2
-MASTER_1_AUTO_INCREMENT_OFFSET2
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_1"')
-1
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_2"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 2', '',
-'srv "s_2_1"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 3', '',
-'srv "s_2_2"')
-1
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1
-CREATE TABLE t2 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT MAX(id) FROM t1;
-MAX(id)
-2
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-6
-SELECT MAX(id) FROM t2;
-MAX(id)
-6
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-10
-SELECT MAX(id) FROM t1;
-MAX(id)
-10
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-14
-SELECT MAX(id) FROM t2;
-MAX(id)
-14
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT id FROM t1 ORDER BY id;
-id
-2
-6
-10
-14
-18
-22
-26
-30
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-34
-SELECT id FROM t2 ORDER BY id;
-id
-2
-6
-10
-14
-18
-22
-26
-30
-34
-38
-42
-46
-TRUNCATE TABLE t1;
-TRUNCATE TABLE t2;
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT id FROM t1 ORDER BY id;
-id
-2
-6
-10
-14
-INSERT INTO t2 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT id FROM t2 ORDER BY id;
-id
-2
-6
-10
-14
-18
-22
-26
-30
-SET INSERT_ID=5000;
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-34
-SELECT MAX(id) FROM t1;
-MAX(id)
-34
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-38
-SELECT MAX(id) FROM t2;
-MAX(id)
-38
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-42
-SELECT MAX(id) FROM t1;
-MAX(id)
-42
-INSERT INTO t2 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-46
-SELECT MAX(id) FROM t2;
-MAX(id)
-46
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-connection slave1_1;
-SELECT id FROM t1 ORDER BY id;
-id
-2
-34
-777
-1554
-2331
-10000
-connection master_1;
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for slave1_1
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/spider3_fixes_part.result b/storage/spider/mysql-test/spider/handler/r/spider3_fixes_part.result
deleted file mode 100644
index 6c3a1802f1d..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/spider3_fixes_part.result
+++ /dev/null
@@ -1,243 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for slave1_1
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-auto_increment with partition
-connection master_1;
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-connection slave1_1;
-connection master_1;
-DROP TABLE IF EXISTS t1, t2;
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1
-CREATE TABLE t2 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1
-MASTER_1_AUTO_INCREMENT_INCREMENT2
-MASTER_1_AUTO_INCREMENT_OFFSET2
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_1"')
-1
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_2"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 2', '',
-'srv "s_2_1"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 3', '',
-'srv "s_2_2"')
-1
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1
-CREATE TABLE t2 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-3
-SELECT MAX(id) FROM t1;
-MAX(id)
-3
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-7
-SELECT MAX(id) FROM t2;
-MAX(id)
-7
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT MAX(id) FROM t1;
-MAX(id)
-7
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-6
-SELECT MAX(id) FROM t2;
-MAX(id)
-7
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-10
-SELECT id FROM t1 ORDER BY id;
-id
-2
-3
-6
-7
-10
-11
-14
-15
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT id FROM t2 ORDER BY id;
-id
-2
-3
-6
-7
-10
-11
-14
-15
-18
-19
-22
-23
-TRUNCATE TABLE t1;
-TRUNCATE TABLE t2;
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT id FROM t1 ORDER BY id;
-id
-2
-3
-6
-7
-INSERT INTO t2 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-10
-SELECT id FROM t2 ORDER BY id;
-id
-2
-3
-6
-7
-10
-11
-14
-15
-SET INSERT_ID=5000;
-MASTER_1_AUTO_INCREMENT_OFFSET3
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT MAX(id) FROM t1;
-MAX(id)
-18
-MASTER_1_AUTO_INCREMENT_OFFSET4
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-19
-SELECT MAX(id) FROM t2;
-MAX(id)
-19
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-22
-SELECT MAX(id) FROM t1;
-MAX(id)
-22
-INSERT INTO t2 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-26
-SELECT MAX(id) FROM t2;
-MAX(id)
-26
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-connection slave1_1;
-SELECT id FROM t1 ORDER BY id;
-id
-2
-18
-777
-1554
-2331
-10000
-connection master_1;
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for slave1_1
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/spider_fixes.result b/storage/spider/mysql-test/spider/handler/r/spider_fixes.result
deleted file mode 100644
index f11b1d9b32c..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/spider_fixes.result
+++ /dev/null
@@ -1,634 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for slave1_1
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table and insert
-connection master_1;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-
-2.13
-select table with "order by desc" and "<"
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-WHERE a < 5 ORDER BY a DESC LIMIT 3;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-4 d 2003-11-30 05:01:03
-3 e 2007-06-04 20:03:11
-2 b 2000-01-01 00:00:00
-
-select table with "order by desc" and "<="
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-WHERE a <= 5 ORDER BY a DESC LIMIT 3;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-5 c 2001-12-31 23:59:59
-4 d 2003-11-30 05:01:03
-3 e 2007-06-04 20:03:11
-
-2.14
-update table with range scan and split_read
-connection master_1;
-UPDATE ta_l SET c = '2000-02-02 00:00:00' WHERE a > 1;
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-02-02 00:00:00
-3 e 2000-02-02 00:00:00
-4 d 2000-02-02 00:00:00
-5 c 2000-02-02 00:00:00
-
-2.15
-select table with range scan
-TRUNCATE TABLE ta_l;
-DROP TABLE IF EXISTS ta_l;
-connection master_1;
-CREATE TABLE ta_l (
-a int(11) NOT NULL DEFAULT '0',
-b char(1) DEFAULT NULL,
-c datetime DEFAULT NULL,
-PRIMARY KEY (a, b, c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT5_2_1
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b >= 'b'
-AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b > 'b'
-AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a >= 4 AND b = 'd'
-AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a > 4 AND b = 'c'
-AND c = '2001-12-31 23:59:59';
-a b c
-5 c 2001-12-31 23:59:59
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b <= 'd'
-AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b < 'e'
-AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a <= 4 AND b = 'b'
-AND c = '2000-01-01 00:00:00';
-a b c
-2 b 2000-01-01 00:00:00
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a < 4 AND b = 'b'
-AND c = '2000-01-01 00:00:00';
-a b c
-2 b 2000-01-01 00:00:00
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b >= 'b'
-AND b <= 'd' AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b > 'b'
-AND b < 'e' AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a <= 4 AND a >= 1
-AND b >= 'b' AND c = '2003-11-30 05:01:03';
-a b c
-4 d 2003-11-30 05:01:03
-connection master_1;
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a < 4 AND a > 1
-AND b >= 'b' AND c = '2000-01-01 00:00:00';
-a b c
-2 b 2000-01-01 00:00:00
-
-2.16
-auto_increment insert with trigger
-connection master_1;
-CREATE TABLE ta_l_auto_inc (
-a INT AUTO_INCREMENT,
-b CHAR(1) DEFAULT 'c',
-c DATETIME DEFAULT '1999-10-10 10:10:10',
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT3_2_1
-CREATE TABLE tc_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-CREATE TRIGGER ins_ta_l_auto_inc AFTER INSERT ON ta_l_auto_inc FOR EACH ROW BEGIN INSERT INTO tc_l (a, b, c) VALUES (NEW.a, NEW.b, NEW.c); END;;
-connection master_1;
-INSERT INTO ta_l_auto_inc (a, b, c) VALUES
-(NULL, 's', '2008-12-31 20:59:59');
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM tc_l ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 s 2008-12-31 20:59:59
-
-2.17
-engine-condition-pushdown with "or" and joining
-connection master_1;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l WHERE a = 1 OR a IN (SELECT a FROM tb_l);
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-1 a 2008-08-01 10:21:39
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-2.23
-index merge
-connection master_1;
-CREATE TABLE ta_l_int (
-a INT AUTO_INCREMENT,
-b INT DEFAULT 10,
-c INT DEFAULT 11,
-PRIMARY KEY(a),
-KEY idx1(b),
-KEY idx2(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1
-INSERT INTO ta_l_int (a, b, c) VALUES (1, 2, 3);
-INSERT INTO ta_l_int (a, b, c) SELECT a + 1, b + 1, c + 1 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 2, b + 2, c + 2 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 4, b + 4, c + 4 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 8, b + 8, c + 8 FROM ta_l_int;
-connection master_1;
-SELECT a, b, c FROM ta_l_int force index(primary, idx1, idx2)
-WHERE a = 5 OR b = 5 OR c = 5 ORDER BY a;
-a b c
-3 4 5
-4 5 6
-5 6 7
-
-2.24
-index scan update without PK
-connection master_1;
-DROP TABLE IF EXISTS ta_l_int;
-CREATE TABLE ta_l_int (
-a INT NOT NULL,
-b INT DEFAULT 10,
-c INT DEFAULT 11,
-KEY idx1(b),
-KEY idx2(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1
-SELECT a, b, c FROM ta_l_int ORDER BY a;
-a b c
-1 2 3
-2 3 4
-3 4 5
-4 5 6
-5 6 7
-6 7 8
-7 8 9
-8 9 10
-9 10 11
-10 11 12
-11 12 13
-12 13 14
-13 14 15
-14 15 16
-15 16 17
-16 17 18
-INSERT INTO ta_l_int (a, b, c) VALUES (0, 2, 3);
-INSERT INTO ta_l_int (a, b, c) VALUES (18, 2, 3);
-connection master_1;
-UPDATE ta_l_int SET c = 4 WHERE b = 2;
-connection master_1;
-SELECT a, b, c FROM ta_l_int ORDER BY a;
-a b c
-1 2 4
-2 3 4
-3 4 5
-4 5 6
-5 6 7
-6 7 8
-7 8 9
-8 9 10
-9 10 11
-10 11 12
-11 12 13
-12 13 14
-13 14 15
-14 15 16
-15 16 17
-16 17 18
-17 2 4
-18 2 4
-
-2.25
-direct order limit
-connection master_1;
-SHOW STATUS LIKE 'Spider_direct_order_limit';
-Variable_name Value
-Spider_direct_order_limit 2
-SELECT a, b, c FROM ta_l_int ORDER BY a LIMIT 3;
-a b c
-1 2 4
-2 3 4
-3 4 5
-SHOW STATUS LIKE 'Spider_direct_order_limit';
-Variable_name Value
-Spider_direct_order_limit 3
-
-2.26
-lock tables
-connection master_1;
-DROP TABLE IF EXISTS t1;
-DROP TABLE IF EXISTS t2;
-CREATE TABLE t1 (
-id int(11) NOT NULL,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_LOCK1
-CREATE TABLE t2 (
-id int(11) NOT NULL,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_LOCK2
-LOCK TABLES t1 READ, t2 READ;
-UNLOCK TABLES;
-
-auto_increment
-connection master_1;
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-connection slave1_1;
-connection master_1;
-DROP TABLE IF EXISTS t1;
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1
-MASTER_1_AUTO_INCREMENT_INCREMENT2
-MASTER_1_AUTO_INCREMENT_OFFSET2
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_1"')
-1
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_2"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 2', '',
-'srv "s_2_1"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 3', '',
-'srv "s_2_2"')
-1
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT MAX(id) FROM t1;
-MAX(id)
-2
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-6
-SELECT MAX(id) FROM t1;
-MAX(id)
-6
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-10
-SELECT MAX(id) FROM t1;
-MAX(id)
-10
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-14
-SELECT MAX(id) FROM t1;
-MAX(id)
-14
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT id FROM t1 ORDER BY id;
-id
-2
-6
-10
-14
-18
-22
-26
-30
-SET INSERT_ID=5000;
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-34
-SELECT MAX(id) FROM t1;
-MAX(id)
-34
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-38
-SELECT MAX(id) FROM t1;
-MAX(id)
-38
-INSERT INTO t1 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-42
-SELECT MAX(id) FROM t1;
-MAX(id)
-42
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-connection slave1_1;
-SELECT id FROM t1 ORDER BY id;
-id
-2
-6
-10
-14
-18
-34
-777
-1000
-1554
-2331
-10000
-connection master_1;
-
-read only
-connection master_1;
-SET @original_spider_read_only_mode = @@SESSION.spider_read_only_mode;
-SET SESSION spider_read_only_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-DROP TABLE IF EXISTS t1;
-CREATE TABLE t1 (
-id int(11) NOT NULL,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_READONLY1_1
-SELECT id FROM t1 ORDER BY id;
-id
-2
-6
-10
-14
-18
-22
-26
-30
-34
-38
-42
-INSERT INTO t1 (id) VALUES (1);
-ERROR HY000: Table 'auto_test_local.t1' is read only
-UPDATE t1 SET id = 4 WHERE id = 2;
-ERROR HY000: Table 'auto_test_local.t1' is read only
-DELETE FROM t1 WHERE id = 2;
-ERROR HY000: Table 'auto_test_local.t1' is read only
-DELETE FROM t1;
-ERROR HY000: Table 'auto_test_local.t1' is read only
-TRUNCATE t1;
-ERROR HY000: Table 'auto_test_local.t1' is read only
-SET SESSION spider_read_only_mode = @original_spider_read_only_mode;
-
-2.27
-error mode
-connection master_1;
-SET @original_spider_error_read_mode = @@SESSION.spider_error_read_mode;
-SET @original_spider_error_write_mode = @@SESSION.spider_error_write_mode;
-SET SESSION spider_error_read_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-SET SESSION spider_error_write_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-DROP TABLE IF EXISTS t1;
-CREATE TABLE t1 (
-id int(11) NOT NULL,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_ERROR_MODE1_1
-SELECT id FROM t1 ORDER BY id;
-id
-Warnings:
-Error 12702 Remote table 'auto_test_remote.ter1_1' is not found
-Error 1146 Table 'auto_test_remote.ter1_1' doesn't exist
-INSERT INTO t1 (id) VALUES (1);
-Warnings:
-Error 1146 Table 'auto_test_remote.ter1_1' doesn't exist
-DELETE FROM t1;
-Warnings:
-Error 12702 Remote table 'auto_test_remote.ter1_1' is not found
-Error 12702 Remote table 'auto_test_remote.ter1_1' is not found
-Error 1146 Table 'auto_test_remote.ter1_1' doesn't exist
-TRUNCATE t1;
-Warnings:
-Error 1146 Table 'auto_test_remote.ter1_1' doesn't exist
-SET SESSION spider_error_read_mode = @original_spider_error_read_mode;
-SET SESSION spider_error_write_mode = @original_spider_error_write_mode;
-
-3.0
-is null
-connection master_1;
-DROP TABLE IF EXISTS t1;
-CREATE TABLE t1 (
-a VARCHAR(255),
-b VARCHAR(255),
-c VARCHAR(255),
-KEY idx1(a,b),
-KEY idx2(b),
-PRIMARY KEY(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_TEXT_KEY1_1
-insert into t1 values (null, null, '2048');
-insert into t1 values ('1', '1', '1');
-insert into t1 select a + 1, b + 1, c + 1 from t1;
-insert into t1 select a + 2, b + 2, c + 2 from t1;
-insert into t1 select a + 4, b + 4, c + 4 from t1;
-insert into t1 select a + 8, b + 8, c + 8 from t1;
-insert into t1 select a + 16, b + 16, c + 16 from t1;
-insert into t1 select a + 32, b + 32, c + 32 from t1;
-insert into t1 select a + 64, b + 64, c + 64 from t1;
-insert into t1 select a + 128, b + 128, c + 128 from t1;
-insert into t1 select a + 256, b + 256, c + 256 from t1;
-insert into t1 select a + 512, b + 512, c + 512 from t1;
-flush tables;
-connection master_1;
-select a from t1 where a is null order by a limit 30;
-a
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-select b from t1 where b is null order by b limit 30;
-b
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-NULL
-
-direct_order_limit
-connection master_1;
-TRUNCATE TABLE t1;
-insert into t1 values ('1', '1', '1');
-insert into t1 select a + 1, b + 1, c + 1 from t1;
-insert into t1 select a + 2, b + 2, c + 2 from t1;
-insert into t1 select a + 4, b + 4, c + 4 from t1;
-insert into t1 select a + 8, b + 8, c + 8 from t1;
-insert into t1 select a + 16, b + 16, c + 16 from t1;
-insert into t1 select a, b + 32, c + 32 from t1;
-insert into t1 select a, b + 64, c + 64 from t1;
-insert into t1 select a, b + 128, c + 128 from t1;
-flush tables;
-connection master_1;
-select a, b, c from t1 where a = '10' and b <> '100' order by c desc limit 5;
-a b c
-10 74 74
-10 42 42
-10 234 234
-10 202 202
-10 170 170
-select a, c from t1 where a = '10' order by b desc limit 5;
-a c
-10 74
-10 42
-10 234
-10 202
-10 170
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for slave1_1
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/spider_fixes_part.result b/storage/spider/mysql-test/spider/handler/r/spider_fixes_part.result
deleted file mode 100644
index 249f39520c2..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/spider_fixes_part.result
+++ /dev/null
@@ -1,246 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-for slave1_1
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-connection master_1;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-
-2.17
-partition with sort
-connection master_1;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1
-INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 WHERE a > 1
-ORDER BY a;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-2 b 2000-01-01 00:00:00
-3 e 2007-06-04 20:03:11
-4 d 2003-11-30 05:01:03
-5 c 2001-12-31 23:59:59
-
-2.23
-partition update with moving partition
-connection master_1;
-DROP TABLE IF EXISTS ta_l2;
-connection master_1;
-CREATE TABLE ta_l2 (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1
-INSERT INTO ta_l2 (a, b, c) VALUES (3, 'B', '2010-09-26 00:00:00');
-UPDATE ta_l2 SET a = 4 WHERE a = 3;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2;
-a b date_format(c, '%Y-%m-%d %H:%i:%s')
-4 B 2010-09-26 00:00:00
-index merge with partition
-connection master_1;
-DROP TABLE IF EXISTS ta_l_int;
-connection master_1;
-CREATE TABLE ta_l_int (
-a INT AUTO_INCREMENT,
-b INT DEFAULT 10,
-c INT DEFAULT 11,
-PRIMARY KEY(a),
-KEY idx1(b),
-KEY idx2(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT3_P_2_1
-INSERT INTO ta_l_int (a, b, c) VALUES (1, 2, 3);
-INSERT INTO ta_l_int (a, b, c) SELECT a + 1, b + 1, c + 1 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 2, b + 2, c + 2 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 4, b + 4, c + 4 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 8, b + 8, c + 8 FROM ta_l_int;
-connection master_1;
-SELECT a, b, c FROM ta_l_int force index(primary, idx1, idx2)
-WHERE a = 5 OR b = 5 OR c = 5 ORDER BY a;
-a b c
-3 4 5
-4 5 6
-5 6 7
-
-2.26
-auto_increment with partition
-connection master_1;
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-Warnings:
-Warning 138 The option value -1 (use table value) is deprecated and will be removed in a future release
-connection slave1_1;
-connection master_1;
-DROP TABLE IF EXISTS t1;
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1
-MASTER_1_AUTO_INCREMENT_INCREMENT2
-MASTER_1_AUTO_INCREMENT_OFFSET2
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_1"')
-1
-spider_direct_sql('SET SESSION AUTO_INCREMENT_INCREMENT = 4', '',
-'srv "s_2_2"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 2', '',
-'srv "s_2_1"')
-1
-spider_bg_direct_sql('SET SESSION AUTO_INCREMENT_OFFSET = 3', '',
-'srv "s_2_2"')
-1
-CREATE TABLE t1 (
-id int(11) NOT NULL AUTO_INCREMENT,
-PRIMARY KEY (id)
-) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-3
-SELECT MAX(id) FROM t1;
-MAX(id)
-3
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-2
-SELECT MAX(id) FROM t1;
-MAX(id)
-3
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-7
-SELECT MAX(id) FROM t1;
-MAX(id)
-7
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-6
-SELECT MAX(id) FROM t1;
-MAX(id)
-7
-INSERT INTO t1 () VALUES (),(),(),();
-Warnings:
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-Note 12520 Binlog's auto-inc value is probably different from linked table's auto-inc value
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-10
-SELECT id FROM t1 ORDER BY id;
-id
-2
-3
-6
-7
-10
-11
-14
-15
-SET INSERT_ID=5000;
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-18
-SELECT MAX(id) FROM t1;
-MAX(id)
-18
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-22
-SELECT MAX(id) FROM t1;
-MAX(id)
-22
-INSERT INTO t1 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-LAST_INSERT_ID()
-26
-SELECT MAX(id) FROM t1;
-MAX(id)
-26
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-connection slave1_1;
-SELECT id FROM t1 ORDER BY id;
-id
-2
-3
-6
-7
-10
-18
-777
-1000
-1554
-2331
-10000
-connection master_1;
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection slave1_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for slave1_1
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/r/vp_fixes.result b/storage/spider/mysql-test/spider/handler/r/vp_fixes.result
deleted file mode 100644
index cc0e4105d61..00000000000
--- a/storage/spider/mysql-test/spider/handler/r/vp_fixes.result
+++ /dev/null
@@ -1,93 +0,0 @@
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-drop and create databases
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-CREATE DATABASE auto_test_remote;
-USE auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-CREATE DATABASE auto_test_remote2;
-USE auto_test_remote2;
-
-test select 1
-connection master_1;
-SELECT 1;
-1
-1
-
-create table and insert
-connection master_1;
-DROP TABLE IF EXISTS tb_l;
-CREATE TABLE tb_l (
-a INT,
-b CHAR(1),
-c DATETIME,
-PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2
-INSERT INTO tb_l (a, b, c) VALUES
-(1, 'a', '2008-08-01 10:21:39'),
-(2, 'b', '2000-01-01 00:00:00'),
-(3, 'e', '2007-06-04 20:03:11'),
-(4, 'd', '2003-11-30 05:01:03'),
-(5, 'c', '2001-12-31 23:59:59');
-DROP TABLE IF EXISTS ta_l;
-CREATE TABLE ta_l (
-PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-
-0.9
-create different primary key table
-connection master_1;
-CREATE TABLE ta_l_int (
-a INT DEFAULT 10,
-b INT AUTO_INCREMENT,
-c INT DEFAULT 11,
-PRIMARY KEY(b)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1
-connection master_1;
-INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
-create un-correspond primary key table
-connection master_1;
-DROP TABLE IF EXISTS ta_l_int;
-connection master_1;
-CREATE TABLE ta_l_int (
-a INT DEFAULT 10,
-b INT DEFAULT 12,
-c INT DEFAULT 11,
-PRIMARY KEY(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1
-connection master_1;
-INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
-
-deinit
-connection master_1;
-DROP DATABASE IF EXISTS auto_test_local;
-connection child2_1;
-DROP DATABASE IF EXISTS auto_test_remote;
-connection child2_2;
-DROP DATABASE IF EXISTS auto_test_remote2;
-for master_1
-for child2
-child2_1
-child2_2
-child2_3
-for child3
-child3_1
-child3_2
-child3_3
-
-end of test
diff --git a/storage/spider/mysql-test/spider/handler/suite.opt b/storage/spider/mysql-test/spider/handler/suite.opt
deleted file mode 100644
index 48457b17309..00000000000
--- a/storage/spider/mysql-test/spider/handler/suite.opt
+++ /dev/null
@@ -1 +0,0 @@
---loose-innodb
diff --git a/storage/spider/mysql-test/spider/handler/suite.pm b/storage/spider/mysql-test/spider/handler/suite.pm
deleted file mode 100644
index af267d047a4..00000000000
--- a/storage/spider/mysql-test/spider/handler/suite.pm
+++ /dev/null
@@ -1,10 +0,0 @@
-package My::Suite::Spider;
-
-@ISA = qw(My::Suite);
-
-return "No Spider engine" unless $ENV{HA_SPIDER_SO};
-return "Not run for embedded server" if $::opt_embedded_server;
-
-sub is_default { 1 }
-
-bless { };
diff --git a/storage/spider/mysql-test/spider/handler/t/basic_sql.test b/storage/spider/mysql-test/spider/handler/t/basic_sql.test
deleted file mode 100644
index 9cf4ce99dc3..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/basic_sql.test
+++ /dev/null
@@ -1,2699 +0,0 @@
-# This test tests by executing basic SQL
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-SELECT a, b, c FROM tb_l;
-if ($MASTER_1_MERGE)
-{
- --error ER_WRONG_OBJECT
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
- INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-}
-if (!$MASTER_1_MERGE)
-{
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- SELECT a, b, c FROM tb_l;
-}
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo create table ignore select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'f', '2008-07-01 10:21:39'),
- (2, 'g', '2000-02-01 00:00:00'),
- (3, 'j', '2007-05-04 20:03:11'),
- (4, 'i', '2003-10-30 05:01:03'),
- (5, 'h', '2001-10-31 23:59:59');
---disable_query_log
-echo CREATE TABLE ta_l (
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-IGNORE SELECT a, b, c FROM tb_l;
-if ($MASTER_1_MERGE)
-{
- --error ER_WRONG_OBJECT
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- IGNORE SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
- INSERT IGNORE INTO ta_l SELECT a, b, c FROM tb_l;
-}
-if (!$MASTER_1_MERGE)
-{
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- IGNORE SELECT a, b, c FROM tb_l;
-}
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo create table ignore select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1
-REPLACE SELECT a, b, c FROM tb_l;
-if ($MASTER_1_MERGE)
-{
- --error ER_WRONG_OBJECT
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- REPLACE SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
- REPLACE INTO ta_l SELECT a, b, c FROM tb_l;
-}
-if (!$MASTER_1_MERGE)
-{
- eval CREATE TABLE ta_l (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1
- REPLACE SELECT a, b, c FROM tb_l;
-}
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%replace %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo create no index table
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES3;
- echo CHILD2_1_CREATE_TABLES3;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES3;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES3;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l_no_idx;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l_no_idx
-MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT2_2_1
-SELECT a, b, c FROM tb_l;
-if ($MASTER_1_NEEDPK)
-{
- --error ER_REQUIRES_PRIMARY_KEY
- eval CREATE TABLE ta_l_no_idx
- $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT2_2_1
- SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l_no_idx (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT2_2_1;
- INSERT INTO ta_l_no_idx SELECT a, b, c FROM tb_l;
-}
-if (!$MASTER_1_NEEDPK)
-{
- if ($MASTER_1_MERGE)
- {
- --error ER_WRONG_OBJECT
- eval CREATE TABLE ta_l_no_idx
- $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT2_2_1
- SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l_no_idx (
- a INT,
- b CHAR(1),
- c DATETIME
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT2_2_1;
- INSERT INTO ta_l_no_idx SELECT a, b, c FROM tb_l;
- }
- if (!$MASTER_1_MERGE)
- {
- eval CREATE TABLE ta_l_no_idx
- $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT2_2_1
- SELECT a, b, c FROM tb_l;
- }
-}
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES3;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l_no_idx ORDER BY a;
-
---echo
---echo select table
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table shared mode
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a
-LOCK IN SHARE MODE;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table for update
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a
-FOR UPDATE;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table join
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a.a, a.b, date_format(b.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a, tb_l b
-WHERE a.a = b.a ORDER BY a.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table straight_join
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT STRAIGHT_JOIN a.a, a.b, date_format(b.c, '%Y-%m-%d %H:%i:%s')
-FROM ta_l a, tb_l b WHERE a.a = b.a ORDER BY a.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_small_result
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_SMALL_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_big_result
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_BIG_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_buffer_result
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_BUFFER_RESULT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_cache
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_CACHE a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_no_cache
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_NO_CACHE a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select sql_calc_found_rows
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT SQL_CALC_FOUND_ROWS a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a LIMIT 4;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT found_rows();
-
---echo
---echo select high_priority
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT HIGH_PRIORITY a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select distinct
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT DISTINCT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select count
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT count(*) FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table join not use index
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM tb_l a WHERE
-EXISTS (SELECT * FROM ta_l b WHERE b.b = a.b) ORDER BY a.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select using pushdown
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a WHERE
-a.b = 'g' ORDER BY a.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select using index and pushdown
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l a WHERE
-a.a > 0 AND a.b = 'g' ORDER BY a.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo insert
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert select
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT INTO ta_l (a, b, c) SELECT a, b, c FROM tb_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert select a
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT INTO ta_l (a, b, c) VALUES ((SELECT a FROM tb_l ORDER BY a LIMIT 1),
-'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert low_priority
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT LOW_PRIORITY INTO ta_l (a, b, c) values (2, 'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert high_priority
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT HIGH_PRIORITY INTO ta_l (a, b, c) VALUES (2, 'e',
-'2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert ignore
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT IGNORE INTO ta_l (a, b, c) VALUES (2, 'd', '2009-02-02 01:01:01');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert update (insert)
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59') ON DUPLICATE
-KEY UPDATE b = 'f', c = '2005-08-08 11:11:11';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo insert update (update)
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59') ON DUPLICATE
-KEY UPDATE b = 'f', c = '2005-08-08 11:11:11';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo replace
---connection master_1
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (2, 'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-REPLACE INTO ta_l (a, b, c) VALUES (2, 'f', '2008-02-02 02:02:02');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'replace %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo replace select
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-REPLACE INTO ta_l (a, b, c) SELECT a, b, c FROM tb_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'replace %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo replace select a
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-REPLACE INTO ta_l (a, b, c) VALUES ((SELECT a FROM tb_l ORDER BY a LIMIT 1),
-'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'replace %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo replace low_priority
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-REPLACE LOW_PRIORITY INTO ta_l (a, b, c) VALUES (3, 'g',
-'2009-03-03 03:03:03');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'replace %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l SET b = 'f', c = '2008-02-02 02:02:02' WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update select
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l SET b = 'g', c = '2009-03-03 03:03:03' WHERE a IN (SELECT a FROM
-tb_l);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update select a
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l SET b = 'h', c = '2010-04-04 04:04:04' WHERE a = (SELECT a FROM
-tb_l ORDER BY a LIMIT 1);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update join
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l a, tb_l b SET a.b = b.b, a.c = b.c WHERE a.a = b.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update join a
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l a, tb_l b SET a.b = 'g', a.c = '2009-03-03 03:03:03' WHERE
-a.a = b.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update low_priority
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE LOW_PRIORITY ta_l SET b = 'f', c = '2008-02-02 02:02:02' WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update ignore
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE IGNORE ta_l SET a = 1, b = 'g', c = '2009-03-03 03:03:03' WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update pushdown
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-update ta_l set b = 'j', c = '2009-03-03 03:03:03' where b = 'f';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo update index pushdown
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l SET b = 'g', c = '2009-03-03 03:03:03' WHERE a > 0 AND b = 'j';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete all
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete select
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l WHERE a IN (SELECT a FROM tb_l);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete select a
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l WHERE a = (SELECT a FROM tb_l ORDER BY a LIMIT 1);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete join
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE a FROM ta_l a, (SELECT a FROM tb_l ORDER BY a) b WHERE a.a = b.a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete low_priority
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE LOW_PRIORITY FROM ta_l WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete ignore
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE IGNORE FROM ta_l WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete quick
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE QUICK FROM ta_l WHERE a = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete pushdown
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l WHERE b = 'e';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo delete index pushdown
-TRUNCATE TABLE ta_l;
-INSERT INTO ta_l (a, b, c) VALUES (1, 'e', '2008-01-01 23:59:59'),
-(2, 'e', '2008-01-01 23:59:59'), (3, 'e', '2008-01-01 23:59:59'),
-(4, 'e', '2008-01-01 23:59:59'), (5, 'e', '2008-01-01 23:59:59'),
-(6, 'e', '2008-01-01 23:59:59'), (7, 'e', '2008-01-01 23:59:59'),
-(8, 'e', '2008-01-01 23:59:59'), (9, 'e', '2008-01-01 23:59:59'),
-(10, 'j', '2008-01-01 23:59:59');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-DELETE FROM ta_l WHERE a > 0 AND b = 'e';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo truncate
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-TRUNCATE TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'truncate %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/basic_sql_part.test b/storage/spider/mysql-test/spider/handler/t/basic_sql_part.test
deleted file mode 100644
index 1bb18358d5d..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/basic_sql_part.test
+++ /dev/null
@@ -1,571 +0,0 @@
-# This test tests by executing basic SQL
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'f', '2008-07-01 10:21:39'),
- (2, 'g', '2000-02-01 00:00:00'),
- (3, 'j', '2007-05-04 20:03:11'),
- (4, 'i', '2003-10-30 05:01:03'),
- (5, 'h', '2001-10-31 23:59:59');
-
---echo
---echo create table with partition and select test
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_COMMENT_P_2_1
- SELECT a, b, c FROM tb_l;
- if ($MASTER_1_MERGE)
- {
- --error ER_WRONG_OBJECT
- eval CREATE TABLE ta_l2 (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT_P_2_1
- SELECT a, b, c FROM tb_l;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT_P_2_1;
- INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
- }
- if (!$MASTER_1_MERGE)
- {
- eval CREATE TABLE ta_l2 (
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT_P_2_1
- SELECT a, b, c FROM tb_l;
- }
- --enable_query_log
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-}
-
---echo
---echo select partition using pushdown
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 a WHERE
- a.b = 'g' ORDER BY a.a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo select partition using index pushdown
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a.a, a.b, date_format(a.c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 a WHERE
- a.a > 0 AND a.b = 'g' ORDER BY a.a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo update partition pushdown
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- UPDATE ta_l2 SET b = 'e', c = '2009-03-03 03:03:03' WHERE b = 'j';
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-}
-
---echo
---echo update partition index pushdown
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- UPDATE ta_l2 SET b = 'j', c = '2009-03-03 03:03:03' WHERE a > 0 AND b = 'e';
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'update %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-}
-
---echo
---echo delete partition pushdown
-if ($HAVE_PARTITION)
-{
- TRUNCATE TABLE ta_l2;
- INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- DELETE FROM ta_l2 WHERE b = 'g';
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-}
-
---echo
---echo delete partition index pushdown
-if ($HAVE_PARTITION)
-{
- TRUNCATE TABLE ta_l2;
- INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- DELETE FROM ta_l2 WHERE a > 0 AND b = 'g';
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE 'delete %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child2_1.inc b/storage/spider/mysql-test/spider/handler/t/connect_child2_1.inc
deleted file mode 100644
index cd9b0c9ca9b..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child2_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child2_1, localhost, root, , , $CHILD2_1_MYPORT, $CHILD2_1_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child2_2.inc b/storage/spider/mysql-test/spider/handler/t/connect_child2_2.inc
deleted file mode 100644
index e145f66b630..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child2_2.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child2_2, localhost, root, , , $CHILD2_2_MYPORT, $CHILD2_2_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child2_3.inc b/storage/spider/mysql-test/spider/handler/t/connect_child2_3.inc
deleted file mode 100644
index d356348d8ea..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child2_3.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child2_3, localhost, root, , , $CHILD2_3_MYPORT, $CHILD2_3_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child3_1.inc b/storage/spider/mysql-test/spider/handler/t/connect_child3_1.inc
deleted file mode 100644
index 03e5c188c89..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child3_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child3_1, localhost, root, , , $CHILD3_1_MYPORT, $CHILD3_1_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child3_2.inc b/storage/spider/mysql-test/spider/handler/t/connect_child3_2.inc
deleted file mode 100644
index d62a7ada824..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child3_2.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child3_2, localhost, root, , , $CHILD3_2_MYPORT, $CHILD3_2_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_child3_3.inc b/storage/spider/mysql-test/spider/handler/t/connect_child3_3.inc
deleted file mode 100644
index fb49f5bfdac..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_child3_3.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (child3_3, localhost, root, , , $CHILD3_3_MYPORT, $CHILD3_3_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_master_1.inc b/storage/spider/mysql-test/spider/handler/t/connect_master_1.inc
deleted file mode 100644
index 0c129ce5775..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_master_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (master_1, localhost, root, , , $MASTER_1_MYPORT, $MASTER_1_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/connect_slave1_1.inc b/storage/spider/mysql-test/spider/handler/t/connect_slave1_1.inc
deleted file mode 100644
index 45a822743e0..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/connect_slave1_1.inc
+++ /dev/null
@@ -1 +0,0 @@
---connect (slave1_1, localhost, root, , , $SLAVE1_1_MYPORT, $SLAVE1_1_MYSOCK)
diff --git a/storage/spider/mysql-test/spider/handler/t/direct_aggregate.test b/storage/spider/mysql-test/spider/handler/t/direct_aggregate.test
deleted file mode 100644
index 5c0c37f483d..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/direct_aggregate.test
+++ /dev/null
@@ -1,179 +0,0 @@
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
---enable_query_log
-INSERT INTO ta_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
---echo
---echo direct_aggregating test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-SELECT COUNT(*) FROM ta_l;
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-SELECT MAX(a) FROM ta_l;
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-SELECT MIN(a) FROM ta_l;
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-SELECT MAX(a) FROM ta_l WHERE a < 5;
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-SELECT MIN(a) FROM ta_l WHERE a > 1;
-eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/direct_aggregate_part.test b/storage/spider/mysql-test/spider/handler/t/direct_aggregate_part.test
deleted file mode 100644
index cb0b55e9788..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/direct_aggregate_part.test
+++ /dev/null
@@ -1,192 +0,0 @@
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo with partition test
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT2_P_2_1;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
- --enable_query_log
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- SELECT COUNT(*) FROM ta_l2;
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- SELECT MAX(a) FROM ta_l2;
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- SELECT MIN(a) FROM ta_l2;
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- SELECT MAX(a) FROM ta_l2 WHERE a < 5;
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- SELECT MIN(a) FROM ta_l2 WHERE a > 1;
- eval $MASTER_1_CHECK_DIRECT_AGGREGATE_STATUS;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/direct_update.test b/storage/spider/mysql-test/spider/handler/t/direct_update.test
deleted file mode 100644
index 94f27e2859c..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/direct_update.test
+++ /dev/null
@@ -1,198 +0,0 @@
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
---enable_query_log
-INSERT INTO ta_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
---echo
---echo direct_updating test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo update all rows with function
-UPDATE ta_l SET c = ADDDATE(c, 1);
-eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo update by primary key
-UPDATE ta_l SET b = 'x' WHERE a = 3;
-eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo update by a column without index
-UPDATE ta_l SET c = '2011-10-17' WHERE b = 'x';
-eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo update by primary key with order and limit
-UPDATE ta_l SET c = ADDDATE(c, 1) WHERE a < 4 ORDER BY b DESC LIMIT 1;
-eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo delete by primary key with order and limit
-DELETE FROM ta_l WHERE a < 4 ORDER BY c LIMIT 1;
-eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo delete by a column without index
-DELETE FROM ta_l WHERE b = 'c';
-eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
---echo delete by primary key
-DELETE FROM ta_l WHERE a = 3;
-eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/direct_update_part.test b/storage/spider/mysql-test/spider/handler/t/direct_update_part.test
deleted file mode 100644
index e8f1882594c..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/direct_update_part.test
+++ /dev/null
@@ -1,211 +0,0 @@
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo with partition test
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT2_P_2_1;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
- --enable_query_log
- eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo update all rows with function
- UPDATE ta_l2 SET c = ADDDATE(c, 1);
- eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo update by primary key
- UPDATE ta_l2 SET b = 'x' WHERE a = 3;
- eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo update by a column without index
- UPDATE ta_l2 SET c = '2011-10-17' WHERE b = 'x';
- eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo update by primary key with order and limit
- UPDATE ta_l2 SET c = ADDDATE(c, 1) WHERE a < 4 ORDER BY b DESC LIMIT 1;
- eval $MASTER_1_CHECK_DIRECT_UPDATE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo delete by primary key with order and limit
- DELETE FROM ta_l2 WHERE a < 4 ORDER BY c LIMIT 1;
- eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo delete by a column without index
- DELETE FROM ta_l2 WHERE b = 'c';
- eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- --echo delete by primary key
- DELETE FROM ta_l2 WHERE a = 3;
- eval $MASTER_1_CHECK_DIRECT_DELETE_STATUS;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%handler %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/function.test b/storage/spider/mysql-test/spider/handler/t/function.test
deleted file mode 100644
index 2472e774782..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/function.test
+++ /dev/null
@@ -1,253 +0,0 @@
-# This test tests for using functions
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo in()
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TEXT_PK_TABLES1;
- echo CHILD2_1_CREATE_TEXT_PK_TABLES1;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TEXT_PK_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_TEXT_PK_TABLES1;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_query_log
-echo CREATE TABLE t1 (
- a VARCHAR(255),
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET3 MASTER_1_COMMENT_TEXT_PK1_1;
-eval CREATE TABLE t1 (
- a VARCHAR(255),
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET3 $MASTER_1_COMMENT_TEXT_PK1_1;
---enable_query_log
-insert into t1 values ('1');
-insert into t1 select a + 1 from t1;
-insert into t1 select a + 2 from t1;
-insert into t1 select a + 4 from t1;
-insert into t1 select a + 8 from t1;
-insert into t1 select a + 16 from t1;
-insert into t1 select a + 32 from t1;
-insert into t1 select a + 64 from t1;
-insert into t1 select a + 128 from t1;
-insert into t1 select a + 256 from t1;
-insert into t1 select a + 512 from t1;
-flush tables;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-select a from t1 where a in ('15', '120');
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TEXT_PK_TABLES1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo date_sub()
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
---enable_query_log
-INSERT INTO ta_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 YEAR);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 QUARTER);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 MONTH);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 WEEK);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 DAY);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 HOUR);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_SUB(c, INTERVAL 1 MINUTE);
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-UPDATE ta_l SET c = DATE_ADD(c, INTERVAL 1 SECOND);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/ha.test b/storage/spider/mysql-test/spider/handler/t/ha.test
deleted file mode 100644
index c36b7363a6d..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/ha.test
+++ /dev/null
@@ -1,878 +0,0 @@
-# This test tests for ha features
-if ($USE_HA_TEST)
-{
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source ha_test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
- --connection child2_3
- DROP DATABASE IF EXISTS auto_test_remote3;
- CREATE DATABASE auto_test_remote3;
- USE auto_test_remote3;
-}
-if ($USE_CHILD_GROUP3)
-{
- --connection child3_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
- --connection child3_2
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
- --connection child3_3
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- --connection child2_3
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- SELECT 1;
- --connection child3_2
- SELECT 1;
- --connection child3_3
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_1_CREATE_TABLES_HA_2_1;
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_2_CREATE_TABLES_HA_2_1;
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_3_CREATE_TABLES_HA_2_1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_HA_2_1;
---enable_query_log
-INSERT INTO ta_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
---echo
---echo select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo fail-over test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_HA_DROP_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_HA_DROP_TABLES;
- --enable_warnings
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_CHECK_HA_STATUS;
---error 12511
-INSERT INTO ta_l (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
-eval $MASTER_1_CHECK_LINK_STATUS;
-eval $MASTER_1_CHECK_LINK_FAILED_LOG;
-eval $MASTER_1_CHECK_HA_STATUS;
-INSERT INTO ta_l (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_CHECK_LINK_STATUS;
- eval $CHILD3_1_CHECK_LINK_FAILED_LOG;
- --connection child3_2
- eval $CHILD3_2_CHECK_LINK_STATUS;
- eval $CHILD3_2_CHECK_LINK_FAILED_LOG;
- --connection child3_3
- eval $CHILD3_3_CHECK_LINK_STATUS;
- eval $CHILD3_3_CHECK_LINK_FAILED_LOG;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo recovery test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_HA_CREATE_TABLES;
- }
- eval $CHILD2_2_HA_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_RECOVERY_STATUS_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_RECOVERY_STATUS_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_RECOVERY_STATUS_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_SET_RECOVERY_STATUS_2_1;
-eval $MASTER_1_CHECK_LINK_STATUS;
-eval $MASTER_1_COPY_TABLES_2_1;
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_OK_STATUS_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_OK_STATUS_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_OK_STATUS_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_SET_OK_STATUS_2_1;
-eval $MASTER_1_CHECK_LINK_STATUS;
-INSERT INTO ta_l (a, b, c) VALUES
- (8, 'g', '2011-05-05 21:33:30');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-DROP TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_2_1;
- --enable_warnings
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_2_1;
- --enable_warnings
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_2_1;
- --enable_warnings
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---connection master_1
-eval $MASTER_1_CHANGE_HA_MON;
-
---echo
---echo active standby test
---echo create table test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_1_CREATE_TABLES_HA_AS_2_1;
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_2_CREATE_TABLES_HA_AS_2_1;
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_2_1;
- --enable_warnings
- eval $CHILD3_3_CREATE_TABLES_HA_AS_2_1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_AS_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_HA_AS_2_1;
---enable_query_log
-INSERT INTO ta_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
---echo
---echo select test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo fail-over test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_HA_AS_DROP_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_HA_AS_DROP_TABLES;
- --enable_warnings
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_CHECK_HA_STATUS;
---error 12511
-INSERT INTO ta_l (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
-eval $MASTER_1_CHECK_LINK_STATUS;
-eval $MASTER_1_CHECK_LINK_FAILED_LOG;
-eval $MASTER_1_CHECK_HA_STATUS;
-INSERT INTO ta_l (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_CHECK_LINK_STATUS;
- eval $CHILD3_1_CHECK_LINK_FAILED_LOG;
- --connection child3_2
- eval $CHILD3_2_CHECK_LINK_STATUS;
- eval $CHILD3_2_CHECK_LINK_FAILED_LOG;
- --connection child3_3
- eval $CHILD3_3_CHECK_LINK_STATUS;
- eval $CHILD3_3_CHECK_LINK_FAILED_LOG;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo recovery test
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_HA_AS_CREATE_TABLES;
- }
- eval $CHILD2_1_HA_AS_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_OK_STATUS_AS_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_OK_STATUS_AS_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_OK_STATUS_AS_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-eval $MASTER_1_SET_OK_STATUS_AS_2_1;
-eval $MASTER_1_CHECK_LINK_STATUS;
-INSERT INTO ta_l (a, b, c) VALUES
- (8, 'g', '2011-05-05 21:33:30');
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-DROP TABLE ta_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_2_1;
- --enable_warnings
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_2_1;
- --enable_warnings
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_2_1;
- --enable_warnings
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---connection master_1
-eval $MASTER_1_CHANGE_HA_MON;
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- --connection child2_3
- DROP DATABASE IF EXISTS auto_test_remote3;
-}
-if ($USE_CHILD_GROUP3)
-{
- --connection child3_1
- DROP DATABASE IF EXISTS auto_test_local;
- --connection child3_2
- DROP DATABASE IF EXISTS auto_test_local;
- --connection child3_3
- DROP DATABASE IF EXISTS auto_test_local;
-}
---disable_query_log
---disable_result_log
---source ha_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
-}
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/ha_part.test b/storage/spider/mysql-test/spider/handler/t/ha_part.test
deleted file mode 100644
index 33fe9850b68..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/ha_part.test
+++ /dev/null
@@ -1,1017 +0,0 @@
-# This test tests for ha features
-if ($USE_HA_TEST)
-{
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source ha_test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source ha_test_deinit.inc
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
- --connection child2_3
- DROP DATABASE IF EXISTS auto_test_remote3;
- CREATE DATABASE auto_test_remote3;
- USE auto_test_remote3;
-}
-if ($USE_CHILD_GROUP3)
-{
- --connection child3_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
- --connection child3_2
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
- --connection child3_3
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- --connection child2_3
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-if ($USE_CHILD_GROUP3)
-{
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- SELECT 1;
- --connection child3_2
- SELECT 1;
- --connection child3_3
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-if ($HAVE_PARTITION)
-{
- --echo
- --echo create table with partition test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_3_DROP_TABLES;
- echo CHILD2_3_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_3_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_3_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_1_CREATE_TABLES_HA_P_2_1;
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_2_CREATE_TABLES_HA_P_2_1;
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_3_CREATE_TABLES_HA_P_2_1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_warnings
- DROP TABLE IF EXISTS ta_l2;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_HA_P_2_1;
- --enable_query_log
- INSERT INTO ta_l2 (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
- --echo
- --echo select test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- eval $CHILD2_1_SELECT_TABLES2;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_3_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-
- --echo
- --echo fail-over test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_3_HA_DROP_TABLES;
- }
- --disable_warnings
- eval $CHILD2_3_HA_DROP_TABLES;
- --enable_warnings
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- eval $MASTER_1_CHECK_HA_STATUS;
- --error 12511
- INSERT INTO ta_l2 (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
- eval $MASTER_1_CHECK_LINK_STATUS;
- eval $MASTER_1_CHECK_LINK_FAILED_LOG;
- eval $MASTER_1_CHECK_HA_STATUS;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- eval $CHILD2_1_SELECT_TABLES2;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_CHECK_LINK_STATUS;
- eval $CHILD3_1_CHECK_LINK_FAILED_LOG;
- --connection child3_2
- eval $CHILD3_2_CHECK_LINK_STATUS;
- eval $CHILD3_2_CHECK_LINK_FAILED_LOG;
- --connection child3_3
- eval $CHILD3_3_CHECK_LINK_STATUS;
- eval $CHILD3_3_CHECK_LINK_FAILED_LOG;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-
- --echo
- --echo recovery test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_3_HA_CREATE_TABLES;
- }
- eval $CHILD2_3_HA_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_RECOVERY_STATUS_P_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_RECOVERY_STATUS_P_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_RECOVERY_STATUS_P_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- eval $MASTER_1_SET_RECOVERY_STATUS_P_2_1;
- eval $MASTER_1_CHECK_LINK_STATUS;
- eval $MASTER_1_COPY_TABLES_P_2_1;
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_OK_STATUS_P_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_OK_STATUS_P_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_OK_STATUS_P_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- eval $MASTER_1_SET_OK_STATUS_P_2_1;
- eval $MASTER_1_CHECK_LINK_STATUS;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (8, 'g', '2011-05-05 21:33:30'),
- (9, 'h', '2011-05-05 22:32:10');
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- DROP TABLE ta_l2;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- eval $CHILD2_1_SELECT_TABLES2;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_3_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
-if ($HAVE_PARTITION)
-{
- --echo
- --echo create table with partition test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_3_DROP_TABLES;
- echo CHILD2_3_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_3_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_3_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_1_CREATE_TABLES_HA_AS_P_2_1;
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_2_CREATE_TABLES_HA_AS_P_2_1;
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- eval $CHILD3_3_CREATE_TABLES_HA_AS_P_2_1;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_warnings
- DROP TABLE IF EXISTS ta_l2;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_HA_AS_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_HA_AS_P_2_1;
- --enable_query_log
- INSERT INTO ta_l2 (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
- --echo
- --echo select test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- eval $CHILD2_1_SELECT_TABLES2;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_3_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-
- --echo
- --echo fail-over test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_HA_AS_DROP_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_HA_AS_DROP_TABLES2;
- --enable_warnings
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- eval $MASTER_1_CHECK_HA_STATUS;
- --error 12511
- INSERT INTO ta_l2 (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
- eval $MASTER_1_CHECK_LINK_STATUS;
- eval $MASTER_1_CHECK_LINK_FAILED_LOG;
- eval $MASTER_1_CHECK_HA_STATUS;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (6, 'e', '2011-05-05 20:04:05');
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_3_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_CHECK_LINK_STATUS;
- eval $CHILD3_1_CHECK_LINK_FAILED_LOG;
- --connection child3_2
- eval $CHILD3_2_CHECK_LINK_STATUS;
- eval $CHILD3_2_CHECK_LINK_FAILED_LOG;
- --connection child3_3
- eval $CHILD3_3_CHECK_LINK_STATUS;
- eval $CHILD3_3_CHECK_LINK_FAILED_LOG;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-
- --echo
- --echo recovery test
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_HA_AS_CREATE_TABLES2;
- }
- eval $CHILD2_1_HA_AS_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- eval $CHILD3_1_SET_OK_STATUS_AS_P_2_1;
- eval $CHILD3_1_CHECK_LINK_STATUS;
- --connection child3_2
- eval $CHILD3_2_SET_OK_STATUS_AS_P_2_1;
- eval $CHILD3_2_CHECK_LINK_STATUS;
- --connection child3_3
- eval $CHILD3_3_SET_OK_STATUS_AS_P_2_1;
- eval $CHILD3_3_CHECK_LINK_STATUS;
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- eval $MASTER_1_SET_OK_STATUS_AS_P_2_1;
- eval $MASTER_1_CHECK_LINK_STATUS;
- INSERT INTO ta_l2 (a, b, c) VALUES
- (8, 'g', '2011-05-05 21:33:30'),
- (9, 'h', '2011-05-05 22:32:10');
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 ORDER BY a;
- DROP TABLE ta_l2;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES;
- eval $CHILD2_1_SELECT_TABLES2;
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_3
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_3_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- if ($USE_CHILD_GROUP3)
- {
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child3_1
- --disable_warnings
- eval $CHILD3_1_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- --connection child3_2
- --disable_warnings
- eval $CHILD3_2_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- --connection child3_3
- --disable_warnings
- eval $CHILD3_3_DROP_TABLES_HA_P_2_1;
- --enable_warnings
- if (!$OUTPUT_CHILD_GROUP3)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- --connection child2_3
- DROP DATABASE IF EXISTS auto_test_remote3;
-}
-if ($USE_CHILD_GROUP3)
-{
- --connection child3_1
- DROP DATABASE IF EXISTS auto_test_local;
- --connection child3_2
- DROP DATABASE IF EXISTS auto_test_local;
- --connection child3_3
- DROP DATABASE IF EXISTS auto_test_local;
-}
---disable_query_log
---disable_result_log
---source ha_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
-}
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/ha_test_deinit.inc b/storage/spider/mysql-test/spider/handler/t/ha_test_deinit.inc
deleted file mode 100644
index 53d0409d066..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/ha_test_deinit.inc
+++ /dev/null
@@ -1,30 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---connection master_1
---source ../include/ha_deinit_master_1.inc
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --connection child2_1
- --source ../include/ha_deinit_child2_1.inc
- --echo child2_2
- --connection child2_2
- --source ../include/ha_deinit_child2_2.inc
- --echo child2_3
- --connection child2_3
- --source ../include/ha_deinit_child2_3.inc
-}
---echo for child3
-if ($USE_CHILD_GROUP3)
-{
- --echo child3_1
- --connection child3_1
- --source ../include/ha_deinit_child3_1.inc
- --echo child3_2
- --connection child3_2
- --source ../include/ha_deinit_child3_2.inc
- --echo child3_3
- --connection child3_3
- --source ../include/ha_deinit_child3_3.inc
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/ha_test_init.inc b/storage/spider/mysql-test/spider/handler/t/ha_test_init.inc
deleted file mode 100644
index 70576ab16dc..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/ha_test_init.inc
+++ /dev/null
@@ -1,30 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---connection master_1
---source ../include/ha_init_master_1.inc
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --connection child2_1
- --source ../include/ha_init_child2_1.inc
- --echo child2_2
- --connection child2_2
- --source ../include/ha_init_child2_2.inc
- --echo child2_3
- --connection child2_3
- --source ../include/ha_init_child2_3.inc
-}
---echo for child3
-if ($USE_CHILD_GROUP3)
-{
- --echo child3_1
- --connection child3_1
- --source ../include/ha_init_child3_1.inc
- --echo child3_2
- --connection child3_2
- --source ../include/ha_init_child3_2.inc
- --echo child3_3
- --connection child3_3
- --source ../include/ha_init_child3_3.inc
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/have_engine.inc b/storage/spider/mysql-test/spider/handler/t/have_engine.inc
deleted file mode 100644
index 64bef7499cb..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/have_engine.inc
+++ /dev/null
@@ -1,7 +0,0 @@
-if (!`SELECT count(*) FROM information_schema.engines WHERE
- (support = 'YES' OR support = 'DEFAULT') AND
- engine = '$TEST_ENGINE_TYPE'`)
-{
- SELECT engine, support FROM information_schema.engines;
- --let $SKIP_REASON= "Need $TEST_ENGINE_TYPE engine"
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/have_func.inc b/storage/spider/mysql-test/spider/handler/t/have_func.inc
deleted file mode 100644
index e0823e73fc8..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/have_func.inc
+++ /dev/null
@@ -1,5 +0,0 @@
-if (!`SELECT count(*) FROM mysql.func WHERE name = '$TEST_FUNC_NAME'`)
-{
- SELECT name FROM mysql.func;
- --let $SKIP_REASON= "Need $TEST_FUNC_NAME function"
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/have_partition.inc b/storage/spider/mysql-test/spider/handler/t/have_partition.inc
deleted file mode 100644
index b6e699475db..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/have_partition.inc
+++ /dev/null
@@ -1,7 +0,0 @@
-let $HAVE_PARTITION= 0;
-if (`SELECT count(*) FROM information_schema.plugins WHERE
- plugin_status = 'ACTIVE' AND
- plugin_name = 'partition'`)
-{
- let $HAVE_PARTITION= 1;
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/have_trigger.inc b/storage/spider/mysql-test/spider/handler/t/have_trigger.inc
deleted file mode 100644
index 32de484b388..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/have_trigger.inc
+++ /dev/null
@@ -1,2 +0,0 @@
-let $HAVE_TRIGGER= `SELECT COUNT(*) FROM information_schema.tables
- WHERE TABLE_SCHEMA = 'information_schema' AND TABLE_NAME = 'TRIGGERS'`;
diff --git a/storage/spider/mysql-test/spider/handler/t/hs_test_deinit.inc b/storage/spider/mysql-test/spider/handler/t/hs_test_deinit.inc
deleted file mode 100644
index 7ec2e981fd2..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/hs_test_deinit.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---connection master_1
---source ../include/hs_deinit_master_1.inc
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --connection child2_1
- --source ../include/hs_deinit_child2_1.inc
- --echo child2_2
- --connection child2_2
- --source ../include/hs_deinit_child2_2.inc
- --echo child2_3
- --connection child2_3
- --source ../include/hs_deinit_child2_3.inc
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/hs_test_init.inc b/storage/spider/mysql-test/spider/handler/t/hs_test_init.inc
deleted file mode 100644
index 831bf479524..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/hs_test_init.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---connection master_1
---source ../include/hs_init_master_1.inc
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --connection child2_1
- --source ../include/hs_init_child2_1.inc
- --echo child2_2
- --connection child2_2
- --source ../include/hs_init_child2_2.inc
- --echo child2_3
- --connection child2_3
- --source ../include/hs_init_child2_3.inc
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/slave_test_deinit.inc b/storage/spider/mysql-test/spider/handler/t/slave_test_deinit.inc
deleted file mode 100644
index e9d99b7a960..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/slave_test_deinit.inc
+++ /dev/null
@@ -1,6 +0,0 @@
-# get connection and exist engine test
---echo for slave1_1
---connection slave1_1
-STOP SLAVE;
---source ../include/deinit_slave1_1.inc
---disconnect slave1_1
diff --git a/storage/spider/mysql-test/spider/handler/t/slave_test_init.inc b/storage/spider/mysql-test/spider/handler/t/slave_test_init.inc
deleted file mode 100644
index 739d88970c5..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/slave_test_init.inc
+++ /dev/null
@@ -1,44 +0,0 @@
-# get connection and exist engine test
---echo for slave1_1
---source connect_slave1_1.inc
---connection slave1_1
-SET SESSION sql_log_bin= 0;
---let $SLAVE1_1_SERVER_ID=`SELECT @@global.server_id`
---let $TEST_ENGINE_TYPE= $SLAVE1_1_ENGINE_TYPE
---source have_partition.inc
---source have_trigger.inc
---source ../include/init_slave1_1.inc
---source have_engine.inc
---let $SLAVE1_1_SLAVE_STATUS=`SHOW SLAVE STATUS`
-if (!$SLAVE1_1_SLAVE_STATUS)
-{
- eval CHANGE MASTER TO
- MASTER_HOST = '127.0.0.1',
- MASTER_USER = 'root',
- MASTER_PASSWORD = '',
- MASTER_PORT = $MASTER_1_MYPORT
- ;
-}
-START SLAVE;
---connection master_1
-call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
---connection slave1_1
-call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
- --connection child2_2
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
- --connection child2_3
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
-}
-if ($USE_CHILD_GROUP3)
-{
- --connection child3_1
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
- --connection child3_2
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
- --connection child3_3
- call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/spider3_fixes.test b/storage/spider/mysql-test/spider/handler/t/spider3_fixes.test
deleted file mode 100644
index 30d22a6a16f..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/spider3_fixes.test
+++ /dev/null
@@ -1,297 +0,0 @@
-# This test tests for Spider 3.0's bug fixes
-source include/have_log_bin.inc;
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source slave_test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo
---echo 3.1
---echo auto_increment
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_INCREMENT_TABLES1;
- echo CHILD2_1_CREATE_INCREMENT_TABLES1;
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-if ($USE_REPLICATION)
-{
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
-}
---disable_warnings
-DROP TABLE IF EXISTS t1, t2;
---enable_warnings
---disable_query_log
-echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1;
-echo CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1;
-echo MASTER_1_AUTO_INCREMENT_INCREMENT2;
-echo MASTER_1_AUTO_INCREMENT_OFFSET2;
-eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_1;
-eval CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_1;
---disable_ps_protocol
-eval $MASTER_1_AUTO_INCREMENT_INCREMENT2;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET2;
---enable_ps_protocol
-if ($USE_REPLICATION)
-{
- SET SESSION sql_log_bin= 1;
- --connection slave1_1
- --disable_warnings
- DROP TABLE IF EXISTS t1, t2;
- --enable_warnings
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1;
- echo CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_1;
- eval CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_1;
- --connection master_1
-}
---enable_query_log
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t2;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET3;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
---enable_query_log
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET4;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
---enable_query_log
-INSERT INTO t2 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t2;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET3;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
---enable_query_log
-INSERT INTO t1 () VALUES (),(),(),();
-SELECT LAST_INSERT_ID();
-SELECT id FROM t1 ORDER BY id;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET4;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
---enable_query_log
-INSERT INTO t2 () VALUES (),(),(),();
-SELECT LAST_INSERT_ID();
-SELECT id FROM t2 ORDER BY id;
-TRUNCATE TABLE t1;
-TRUNCATE TABLE t2;
-INSERT INTO t1 () VALUES (),(),(),();
-SELECT LAST_INSERT_ID();
-SELECT id FROM t1 ORDER BY id;
-INSERT INTO t2 () VALUES (),(),(),();
-SELECT LAST_INSERT_ID();
-SELECT id FROM t2 ORDER BY id;
-SET INSERT_ID=5000;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET3;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
---enable_query_log
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
---disable_query_log
-echo MASTER_1_AUTO_INCREMENT_OFFSET4;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
---enable_query_log
-INSERT INTO t2 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t2;
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t2 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t2;
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-if ($USE_REPLICATION)
-{
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- SELECT id FROM t1 ORDER BY id;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
-}
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source slave_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/spider3_fixes_part.test b/storage/spider/mysql-test/spider/handler/t/spider3_fixes_part.test
deleted file mode 100644
index e9c9c194e5c..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/spider3_fixes_part.test
+++ /dev/null
@@ -1,350 +0,0 @@
-# This test tests for Spider 3.0's bug fixes
-source include/have_log_bin.inc;
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source slave_test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source slave_test_deinit.inc
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo auto_increment with partition
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_INCREMENT_TABLES1;
- echo CHILD2_1_CREATE_INCREMENT_TABLES1;
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_INCREMENT_TABLES1;
- echo CHILD2_2_CREATE_INCREMENT_TABLES1;
- echo CHILD2_2_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_2_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_2_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_2_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_2_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
- SET SESSION spider_auto_increment_mode = -1;
- if ($USE_REPLICATION)
- {
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
- }
- --disable_warnings
- DROP TABLE IF EXISTS t1, t2;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1;
- echo CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1;
- echo MASTER_1_AUTO_INCREMENT_INCREMENT2;
- echo MASTER_1_AUTO_INCREMENT_OFFSET2;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_P_1;
- eval CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_P_1;
- --disable_ps_protocol
- eval $MASTER_1_AUTO_INCREMENT_INCREMENT2;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET2;
- --enable_ps_protocol
- if ($USE_REPLICATION)
- {
- SET SESSION sql_log_bin= 1;
- --connection slave1_1
- --disable_warnings
- DROP TABLE IF EXISTS t1, t2;
- --enable_warnings
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1;
- echo CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_P_1;
- eval CREATE TABLE t2 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_P_1;
- --connection master_1
- }
- --enable_query_log
- INSERT INTO t1 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t2 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t2;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET3;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
- --enable_query_log
- INSERT INTO t1 (id) VALUES (null);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET4;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
- --enable_query_log
- INSERT INTO t2 (id) VALUES (null);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t2;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET3;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
- --enable_query_log
- INSERT INTO t1 () VALUES (),(),(),();
- SELECT LAST_INSERT_ID();
- SELECT id FROM t1 ORDER BY id;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET4;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
- --enable_query_log
- INSERT INTO t2 () VALUES (),(),(),();
- SELECT LAST_INSERT_ID();
- SELECT id FROM t2 ORDER BY id;
- TRUNCATE TABLE t1;
- TRUNCATE TABLE t2;
- INSERT INTO t1 () VALUES (),(),(),();
- SELECT LAST_INSERT_ID();
- SELECT id FROM t1 ORDER BY id;
- INSERT INTO t2 () VALUES (),(),(),();
- SELECT LAST_INSERT_ID();
- SELECT id FROM t2 ORDER BY id;
- SET INSERT_ID=5000;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET3;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET3;
- --enable_query_log
- INSERT INTO t1 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- --disable_query_log
- echo MASTER_1_AUTO_INCREMENT_OFFSET4;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET4;
- --enable_query_log
- INSERT INTO t2 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t2;
- INSERT INTO t1 (id) VALUES (10000);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t2 (id) VALUES (1000);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t2;
- SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
- if ($USE_REPLICATION)
- {
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- SELECT id FROM t1 ORDER BY id;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
- }
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_2_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_2_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_2_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_2_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source slave_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/spider_fixes.test b/storage/spider/mysql-test/spider/handler/t/spider_fixes.test
deleted file mode 100644
index 5a3c1d1c893..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/spider_fixes.test
+++ /dev/null
@@ -1,1433 +0,0 @@
-# This test tests for Spider's bug fixes
-source include/have_log_bin.inc;
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source slave_test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table and insert
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
---enable_query_log
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-
---echo
---echo 2.13
---echo select table with "order by desc" and "<"
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-WHERE a < 5 ORDER BY a DESC LIMIT 3;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo select table with "order by desc" and "<="
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l
-WHERE a <= 5 ORDER BY a DESC LIMIT 3;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo 2.14
---echo update table with range scan and split_read
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l SET c = '2000-02-02 00:00:00' WHERE a > 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l ORDER BY a;
-
---echo
---echo 2.15
---echo select table with range scan
-TRUNCATE TABLE ta_l;
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES6;
- echo CHILD2_1_CREATE_TABLES6;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES6;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES6;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_query_log
-echo CREATE TABLE ta_l (
- a int(11) NOT NULL DEFAULT '0',
- b char(1) DEFAULT NULL,
- c datetime DEFAULT NULL,
- PRIMARY KEY (a, b, c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT5_2_1;
-eval CREATE TABLE ta_l (
- a int(11) NOT NULL DEFAULT '0',
- b char(1) DEFAULT NULL,
- c datetime DEFAULT NULL,
- PRIMARY KEY (a, b, c)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT5_2_1;
---enable_query_log
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b >= 'b'
-AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b > 'b'
-AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a >= 4 AND b = 'd'
-AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a > 4 AND b = 'c'
-AND c = '2001-12-31 23:59:59';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b <= 'd'
-AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b < 'e'
-AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a <= 4 AND b = 'b'
-AND c = '2000-01-01 00:00:00';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a < 4 AND b = 'b'
-AND c = '2000-01-01 00:00:00';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b >= 'b'
-AND b <= 'd' AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a = 4 AND b > 'b'
-AND b < 'e' AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a <= 4 AND a >= 1
-AND b >= 'b' AND c = '2003-11-30 05:01:03';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l FORCE INDEX(PRIMARY) WHERE a < 4 AND a > 1
-AND b >= 'b' AND c = '2000-01-01 00:00:00';
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo 2.16
---echo auto_increment insert with trigger
-if ($HAVE_TRIGGER)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TABLES4;
- echo CHILD2_1_CREATE_TABLES4;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES4;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES4;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l_auto_inc (
- a INT AUTO_INCREMENT,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT3_2_1;
- eval CREATE TABLE ta_l_auto_inc (
- a INT AUTO_INCREMENT,
- b CHAR(1) DEFAULT 'c',
- c DATETIME DEFAULT '1999-10-10 10:10:10',
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT3_2_1;
- echo CREATE TABLE tc_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
- eval CREATE TABLE tc_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
- --enable_query_log
- --eval CREATE TRIGGER ins_ta_l_auto_inc AFTER INSERT ON ta_l_auto_inc FOR EACH ROW BEGIN INSERT INTO tc_l (a, b, c) VALUES (NEW.a, NEW.b, NEW.c); END;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- INSERT INTO ta_l_auto_inc (a, b, c) VALUES
- (NULL, 's', '2008-12-31 20:59:59');
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES4;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM tc_l ORDER BY a;
-}
-
---echo
---echo 2.17
---echo engine-condition-pushdown with "or" and joining
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l WHERE a = 1 OR a IN (SELECT a FROM tb_l);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo 2.23
---echo index merge
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TABLES5;
- echo CHILD2_1_CREATE_TABLES5;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES5;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES5;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_query_log
-echo CREATE TABLE ta_l_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1;
-eval CREATE TABLE ta_l_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
---enable_query_log
-INSERT INTO ta_l_int (a, b, c) VALUES (1, 2, 3);
-INSERT INTO ta_l_int (a, b, c) SELECT a + 1, b + 1, c + 1 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 2, b + 2, c + 2 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 4, b + 4, c + 4 FROM ta_l_int;
-INSERT INTO ta_l_int (a, b, c) SELECT a + 8, b + 8, c + 8 FROM ta_l_int;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l_int force index(primary, idx1, idx2)
-WHERE a = 5 OR b = 5 OR c = 5 ORDER BY a;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo 2.24
---echo index scan update without PK
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l_int;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l_int (
- a INT NOT NULL,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- KEY idx1(b),
- KEY idx2(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1;
-if ($MASTER_1_NEEDPK)
-{
- --error ER_REQUIRES_PRIMARY_KEY
- eval CREATE TABLE ta_l_int (
- a INT NOT NULL,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- KEY idx1(b),
- KEY idx2(c)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
- eval CREATE TABLE ta_l_int (
- a INT NOT NULL,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
-}
-if (!$MASTER_1_NEEDPK)
-{
- eval CREATE TABLE ta_l_int (
- a INT NOT NULL,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- KEY idx1(b),
- KEY idx2(c)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
-}
---enable_query_log
-SELECT a, b, c FROM ta_l_int ORDER BY a;
-INSERT INTO ta_l_int (a, b, c) VALUES (0, 2, 3);
-INSERT INTO ta_l_int (a, b, c) VALUES (18, 2, 3);
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-UPDATE ta_l_int SET c = 4 WHERE b = 2;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SELECT a, b, c FROM ta_l_int ORDER BY a;
-
-
---echo
---echo 2.25
---echo direct order limit
---connection master_1
-eval $MASTER_1_CHECK_DIRECT_ORDER_LIMIT_STATUS;
-SELECT a, b, c FROM ta_l_int ORDER BY a LIMIT 3;
-eval $MASTER_1_CHECK_DIRECT_ORDER_LIMIT_STATUS;
-
-
---echo
---echo 2.26
---echo lock tables
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_LOCK_TABLES1;
- echo CHILD2_1_DROP_LOCK_TABLES2;
- echo CHILD2_1_CREATE_LOCK_TABLES1;
- echo CHILD2_1_CREATE_LOCK_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_LOCK_TABLES1;
- eval $CHILD2_1_DROP_LOCK_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_LOCK_TABLES1;
- eval $CHILD2_1_CREATE_LOCK_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_LOCK_TABLES1;
- echo CHILD2_2_DROP_LOCK_TABLES2;
- echo CHILD2_2_CREATE_LOCK_TABLES1;
- echo CHILD2_2_CREATE_LOCK_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_LOCK_TABLES1;
- eval $CHILD2_2_DROP_LOCK_TABLES2;
- --enable_warnings
- eval $CHILD2_2_CREATE_LOCK_TABLES1;
- eval $CHILD2_2_CREATE_LOCK_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS t1;
-DROP TABLE IF EXISTS t2;
---enable_warnings
---disable_query_log
-echo CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_LOCK1;
-eval CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_LOCK1;
-echo CREATE TABLE t2 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_LOCK2;
-eval CREATE TABLE t2 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_LOCK2;
---enable_query_log
-LOCK TABLES t1 READ, t2 READ;
-UNLOCK TABLES;
-
-
---echo
---echo auto_increment
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_INCREMENT_TABLES1;
- echo CHILD2_1_CREATE_INCREMENT_TABLES1;
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
-SET SESSION spider_auto_increment_mode = -1;
-if ($USE_REPLICATION)
-{
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
-}
---disable_warnings
-DROP TABLE IF EXISTS t1;
---enable_warnings
---disable_query_log
-echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_1;
-echo MASTER_1_AUTO_INCREMENT_INCREMENT2;
-echo MASTER_1_AUTO_INCREMENT_OFFSET2;
-eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_1;
---disable_ps_protocol
-eval $MASTER_1_AUTO_INCREMENT_INCREMENT2;
-eval $MASTER_1_AUTO_INCREMENT_OFFSET2;
---enable_ps_protocol
-if ($USE_REPLICATION)
-{
- SET SESSION sql_log_bin= 1;
- --connection slave1_1
- --disable_warnings
- DROP TABLE IF EXISTS t1;
- --enable_warnings
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_1;
- --connection master_1
-}
---enable_query_log
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 (id) VALUES (null);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 () VALUES (),(),(),();
-SELECT LAST_INSERT_ID();
-SELECT id FROM t1 ORDER BY id;
-SET INSERT_ID=5000;
-INSERT INTO t1 () VALUES ();
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 (id) VALUES (10000);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-INSERT INTO t1 (id) VALUES (1000);
-SELECT LAST_INSERT_ID();
-SELECT MAX(id) FROM t1;
-SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
-if ($USE_REPLICATION)
-{
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- SELECT id FROM t1 ORDER BY id;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
-}
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo
---echo read only
-let $MASTER_1_ENGINE_IS_SPIDER=
- `SELECT IF('$MASTER_1_ENGINE_TYPE' = 'Spider' OR
- '$MASTER_1_HIDDEN_ENGINE_TYPE' = 'Spider', 1, 0)`;
-if ($MASTER_1_ENGINE_IS_SPIDER)
-{
- --connection master_1
- SET @original_spider_read_only_mode = @@SESSION.spider_read_only_mode;
- SET SESSION spider_read_only_mode = -1;
- --disable_warnings
- DROP TABLE IF EXISTS t1;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_READONLY1_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_READONLY1_1;
- --let $MIN_VAL= `SELECT MIN(id) FROM t1`
- --enable_query_log
- SELECT id FROM t1 ORDER BY id;
- --error 12518
- INSERT INTO t1 (id) VALUES (1);
- --error 12518
- eval UPDATE t1 SET id = 4 WHERE id = $MIN_VAL;
- --error 12518
- eval DELETE FROM t1 WHERE id = $MIN_VAL;
- --error 12518
- DELETE FROM t1;
- --error 12518
- TRUNCATE t1;
- SET SESSION spider_read_only_mode = @original_spider_read_only_mode;
-}
-if (!$MASTER_1_ENGINE_IS_SPIDER)
-{
- --echo skipped
-}
-
-
---echo
---echo 2.27
---echo error mode
-if ($MASTER_1_ENGINE_IS_SPIDER)
-{
- --connection master_1
- SET @original_spider_error_read_mode = @@SESSION.spider_error_read_mode;
- SET @original_spider_error_write_mode = @@SESSION.spider_error_write_mode;
- SET SESSION spider_error_read_mode = -1;
- SET SESSION spider_error_write_mode = -1;
- --disable_warnings
- DROP TABLE IF EXISTS t1;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_ERROR_MODE1_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL,
- PRIMARY KEY (id)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_ERROR_MODE1_1;
- --enable_query_log
- SELECT id FROM t1 ORDER BY id;
- INSERT INTO t1 (id) VALUES (1);
- DELETE FROM t1;
- TRUNCATE t1;
- SET SESSION spider_error_read_mode = @original_spider_error_read_mode;
- SET SESSION spider_error_write_mode = @original_spider_error_write_mode;
-}
-if (!$MASTER_1_ENGINE_IS_SPIDER)
-{
- --echo skipped
-}
-
-
---echo
---echo 3.0
---echo is null
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TEXT_KEY_TABLES1;
- echo CHILD2_1_CREATE_TEXT_KEY_TABLES1;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TEXT_KEY_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_TEXT_KEY_TABLES1;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS t1;
---enable_warnings
---disable_query_log
-echo CREATE TABLE t1 (
- a VARCHAR(255),
- b VARCHAR(255),
- c VARCHAR(255),
- KEY idx1(a,b),
- KEY idx2(b),
- PRIMARY KEY(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_TEXT_KEY1_1;
-eval CREATE TABLE t1 (
- a VARCHAR(255),
- b VARCHAR(255),
- c VARCHAR(255),
- KEY idx1(a,b),
- KEY idx2(b),
- PRIMARY KEY(c)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_TEXT_KEY1_1;
---enable_query_log
-insert into t1 values (null, null, '2048');
-insert into t1 values ('1', '1', '1');
-insert into t1 select a + 1, b + 1, c + 1 from t1;
-insert into t1 select a + 2, b + 2, c + 2 from t1;
-insert into t1 select a + 4, b + 4, c + 4 from t1;
-insert into t1 select a + 8, b + 8, c + 8 from t1;
-insert into t1 select a + 16, b + 16, c + 16 from t1;
-insert into t1 select a + 32, b + 32, c + 32 from t1;
-insert into t1 select a + 64, b + 64, c + 64 from t1;
-insert into t1 select a + 128, b + 128, c + 128 from t1;
-insert into t1 select a + 256, b + 256, c + 256 from t1;
-insert into t1 select a + 512, b + 512, c + 512 from t1;
-flush tables;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-select a from t1 where a is null order by a limit 30;
-select b from t1 where b is null order by b limit 30;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TEXT_PK_TABLES1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo
---echo direct_order_limit
---connection master_1
-TRUNCATE TABLE t1;
-insert into t1 values ('1', '1', '1');
-insert into t1 select a + 1, b + 1, c + 1 from t1;
-insert into t1 select a + 2, b + 2, c + 2 from t1;
-insert into t1 select a + 4, b + 4, c + 4 from t1;
-insert into t1 select a + 8, b + 8, c + 8 from t1;
-insert into t1 select a + 16, b + 16, c + 16 from t1;
-insert into t1 select a, b + 32, c + 32 from t1;
-insert into t1 select a, b + 64, c + 64 from t1;
-insert into t1 select a, b + 128, c + 128 from t1;
-flush tables;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-select a, b, c from t1 where a = '10' and b <> '100' order by c desc limit 5;
-select a, c from t1 where a = '10' order by b desc limit 5;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TEXT_PK_TABLES1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source slave_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/spider_fixes_part.test b/storage/spider/mysql-test/spider/handler/t/spider_fixes_part.test
deleted file mode 100644
index 22ba6102405..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/spider_fixes_part.test
+++ /dev/null
@@ -1,650 +0,0 @@
-# This test tests for Spider's bug fixes
-source include/have_log_bin.inc;
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---source slave_test_init.inc
---enable_result_log
---enable_query_log
-if (!$HAVE_PARTITION)
-{
- --disable_query_log
- --disable_result_log
- --source slave_test_deinit.inc
- --source test_deinit.inc
- --enable_result_log
- --enable_query_log
- --enable_warnings
- skip Test requires partitioning;
-}
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
- CREATE DATABASE auto_test_local;
- USE auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
-
---echo
---echo 2.17
---echo partition with sort
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT2_P_2_1;
- --enable_query_log
- INSERT INTO ta_l2 SELECT a, b, c FROM tb_l;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2 WHERE a > 1
- ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo
---echo 2.23
---echo partition update with moving partition
-if ($HAVE_PARTITION)
-{
- --connection master_1
- --disable_warnings
- DROP TABLE IF EXISTS ta_l2;
- --enable_warnings
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_TABLES;
- echo CHILD2_2_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES2;
- echo CHILD2_1_CREATE_TABLES2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES2;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) MASTER_1_ENGINE MASTER_1_COMMENT2_P_2_1;
- eval CREATE TABLE ta_l2 (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
- ) $MASTER_1_ENGINE $MASTER_1_COMMENT2_P_2_1;
- --enable_query_log
- INSERT INTO ta_l2 (a, b, c) VALUES (3, 'B', '2010-09-26 00:00:00');
- UPDATE ta_l2 SET a = 4 WHERE a = 3;
- SELECT a, b, date_format(c, '%Y-%m-%d %H:%i:%s') FROM ta_l2;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%delete %';
- }
- eval $CHILD2_2_SELECT_TABLES;
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%update %';
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%delete %';
- }
- eval $CHILD2_1_SELECT_TABLES2;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
---echo index merge with partition
-if ($HAVE_PARTITION)
-{
- --connection master_1
- --disable_warnings
- DROP TABLE IF EXISTS ta_l_int;
- --enable_warnings
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_2_DROP_TABLES5;
- echo CHILD2_2_CREATE_TABLES5;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_TABLES5;
- --enable_warnings
- eval $CHILD2_2_CREATE_TABLES5;
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TABLES5;
- echo CHILD2_1_CREATE_TABLES5;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES5;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES5;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
- }
- --connection master_1
- --disable_query_log
- echo CREATE TABLE ta_l_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT3_P_2_1;
- eval CREATE TABLE ta_l_int (
- a INT AUTO_INCREMENT,
- b INT DEFAULT 10,
- c INT DEFAULT 11,
- PRIMARY KEY(a),
- KEY idx1(b),
- KEY idx2(c)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT3_P_2_1;
- --enable_query_log
- INSERT INTO ta_l_int (a, b, c) VALUES (1, 2, 3);
- INSERT INTO ta_l_int (a, b, c) SELECT a + 1, b + 1, c + 1 FROM ta_l_int;
- INSERT INTO ta_l_int (a, b, c) SELECT a + 2, b + 2, c + 2 FROM ta_l_int;
- INSERT INTO ta_l_int (a, b, c) SELECT a + 4, b + 4, c + 4 FROM ta_l_int;
- INSERT INTO ta_l_int (a, b, c) SELECT a + 8, b + 8, c + 8 FROM ta_l_int;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SELECT a, b, c FROM ta_l_int force index(primary, idx1, idx2)
- WHERE a = 5 OR b = 5 OR c = 5 ORDER BY a;
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%select %';
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
-
---echo
---echo 2.26
---echo auto_increment with partition
-if ($HAVE_PARTITION)
-{
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_INCREMENT_TABLES1;
- echo CHILD2_1_CREATE_INCREMENT_TABLES1;
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_1_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- --connection child2_2
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_DROP_INCREMENT_TABLES1;
- echo CHILD2_2_CREATE_INCREMENT_TABLES1;
- echo CHILD2_2_AUTO_INCREMENT_INCREMENT2;
- echo CHILD2_2_AUTO_INCREMENT_OFFSET2;
- }
- --disable_warnings
- eval $CHILD2_2_DROP_INCREMENT_TABLES1;
- --enable_warnings
- eval $CHILD2_2_CREATE_INCREMENT_TABLES1;
- eval $CHILD2_2_AUTO_INCREMENT_INCREMENT2;
- eval $CHILD2_2_AUTO_INCREMENT_OFFSET2;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
- --connection master_1
- SET @original_spider_auto_increment_mode = @@SESSION.spider_auto_increment_mode;
- SET SESSION spider_auto_increment_mode = -1;
- if ($USE_REPLICATION)
- {
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
- }
- --disable_warnings
- DROP TABLE IF EXISTS t1;
- --enable_warnings
- --disable_query_log
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_INCREMENT1_P_1;
- echo MASTER_1_AUTO_INCREMENT_INCREMENT2;
- echo MASTER_1_AUTO_INCREMENT_OFFSET2;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_INCREMENT1_P_1;
- --disable_ps_protocol
- eval $MASTER_1_AUTO_INCREMENT_INCREMENT2;
- eval $MASTER_1_AUTO_INCREMENT_OFFSET2;
- --enable_ps_protocol
- if ($USE_REPLICATION)
- {
- SET SESSION sql_log_bin= 1;
- --connection slave1_1
- --disable_warnings
- DROP TABLE IF EXISTS t1;
- --enable_warnings
- echo CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) SLAVE1_1_ENGINE SLAVE1_1_CHARSET SLAVE1_1_COMMENT_INCREMENT1_P_1;
- eval CREATE TABLE t1 (
- id int(11) NOT NULL AUTO_INCREMENT,
- PRIMARY KEY (id)
- ) $SLAVE1_1_ENGINE $SLAVE1_1_CHARSET $SLAVE1_1_COMMENT_INCREMENT1_P_1;
- --connection master_1
- }
- --enable_query_log
- INSERT INTO t1 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 (id) VALUES (null);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 (id) VALUES (null);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 () VALUES (),(),(),();
- SELECT LAST_INSERT_ID();
- SELECT id FROM t1 ORDER BY id;
- SET INSERT_ID=5000;
- INSERT INTO t1 () VALUES ();
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 (id) VALUES (10000);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- INSERT INTO t1 (id) VALUES (1000);
- SELECT LAST_INSERT_ID();
- SELECT MAX(id) FROM t1;
- SET SESSION spider_auto_increment_mode = @original_spider_auto_increment_mode;
- if ($USE_REPLICATION)
- {
- save_master_pos;
- --connection slave1_1
- sync_with_master;
- SELECT id FROM t1 ORDER BY id;
- --connection master_1
- --disable_query_log
- SET SESSION sql_log_bin= 0;
- --enable_query_log
- }
- if ($USE_CHILD_GROUP2)
- {
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_1_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_1_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_1_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- --connection child2_2
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_2_SELECT_INCREMENT_TABLES1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_2_AUTO_INCREMENT_INCREMENT1;
- echo CHILD2_2_AUTO_INCREMENT_OFFSET1;
- }
- eval $CHILD2_2_AUTO_INCREMENT_INCREMENT1;
- eval $CHILD2_2_AUTO_INCREMENT_OFFSET1;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
- }
-}
-
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_REPLICATION)
-{
- --connection slave1_1
- DROP DATABASE IF EXISTS auto_test_local;
-}
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source slave_test_deinit.inc
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/handler/t/test_deinit.inc b/storage/spider/mysql-test/spider/handler/t/test_deinit.inc
deleted file mode 100644
index 989bde26d3c..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/test_deinit.inc
+++ /dev/null
@@ -1,37 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---connection master_1
---source ../include/deinit_master_1.inc
---disconnect master_1
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --connection child2_1
- --source ../include/deinit_child2_1.inc
- --disconnect child2_1
- --echo child2_2
- --connection child2_2
- --source ../include/deinit_child2_2.inc
- --disconnect child2_2
- --echo child2_3
- --connection child2_3
- --source ../include/deinit_child2_3.inc
- --disconnect child2_3
-}
---echo for child3
-if ($USE_CHILD_GROUP3)
-{
- --echo child3_1
- --connection child3_1
- --source ../include/deinit_child3_1.inc
- --disconnect child3_1
- --echo child3_2
- --connection child3_2
- --source ../include/deinit_child3_2.inc
- --disconnect child3_2
- --echo child3_3
- --connection child3_3
- --source ../include/deinit_child3_3.inc
- --disconnect child3_3
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/test_init.inc b/storage/spider/mysql-test/spider/handler/t/test_init.inc
deleted file mode 100644
index f2cd6c0269f..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/test_init.inc
+++ /dev/null
@@ -1,74 +0,0 @@
-# get connection and exist engine test
---echo for master_1
---source connect_master_1.inc
---connection master_1
-CALL mtr.add_suppression("unknown variable");
-SET SESSION sql_log_bin= 0;
---let $MASTER_1_SERVER_ID=`SELECT @@global.server_id`
---let $TEST_ENGINE_TYPE= $MASTER_1_ENGINE_TYPE
---source have_partition.inc
---source have_trigger.inc
---source ../include/init_master_1.inc
---source have_engine.inc
---echo for child2
-if ($USE_CHILD_GROUP2)
-{
- --echo child2_1
- --source connect_child2_1.inc
- --connection child2_1
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD2_1_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD2_1_ENGINE_TYPE
- --source ../include/init_child2_1.inc
- --source have_engine.inc
- --echo child2_2
- --source connect_child2_2.inc
- --connection child2_2
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD2_2_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD2_2_ENGINE_TYPE
- --source ../include/init_child2_2.inc
- --source have_engine.inc
- --echo child2_3
- --source connect_child2_3.inc
- --connection child2_3
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD2_3_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD2_3_ENGINE_TYPE
- --source ../include/init_child2_3.inc
- --source have_engine.inc
-}
---echo for child3
-if ($USE_CHILD_GROUP3)
-{
- --echo child3_1
- --source connect_child3_1.inc
- --connection child3_1
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD3_1_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD3_1_ENGINE_TYPE
- --source ../include/init_child3_1.inc
- --source have_engine.inc
- --echo child3_2
- --source connect_child3_2.inc
- --connection child3_2
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD3_2_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD3_2_ENGINE_TYPE
- --source ../include/init_child3_2.inc
- --source have_engine.inc
- --echo child3_3
- --source connect_child3_3.inc
- --connection child3_3
- CALL mtr.add_suppression("unknown variable *");
- SET SESSION sql_log_bin= 0;
- --let $CHILD3_3_SERVER_ID=`SELECT @@global.server_id`
- --let $TEST_ENGINE_TYPE= $CHILD3_3_ENGINE_TYPE
- --source ../include/init_child3_3.inc
- --source have_engine.inc
-}
diff --git a/storage/spider/mysql-test/spider/handler/t/vp_fixes.test b/storage/spider/mysql-test/spider/handler/t/vp_fixes.test
deleted file mode 100644
index 2c3e1523611..00000000000
--- a/storage/spider/mysql-test/spider/handler/t/vp_fixes.test
+++ /dev/null
@@ -1,335 +0,0 @@
-# This test tests for VP's bug fixes
---disable_warnings
---disable_query_log
---disable_result_log
---source test_init.inc
---enable_result_log
---enable_query_log
-
---echo
---echo drop and create databases
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-CREATE DATABASE auto_test_local;
-USE auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- CREATE DATABASE auto_test_remote;
- USE auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
- CREATE DATABASE auto_test_remote2;
- USE auto_test_remote2;
-}
---enable_warnings
-
---echo
---echo test select 1
---connection master_1
-SELECT 1;
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- SELECT 1;
- --connection child2_2
- SELECT 1;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo create table and insert
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- echo CHILD2_1_DROP_TABLES;
- echo CHILD2_1_CREATE_TABLES;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES;
- if ($OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- }
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS tb_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) MASTER_1_ENGINE2 MASTER_1_CHARSET2;
-eval CREATE TABLE tb_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE2 $MASTER_1_CHARSET2;
---enable_query_log
-INSERT INTO tb_l (a, b, c) VALUES
- (1, 'a', '2008-08-01 10:21:39'),
- (2, 'b', '2000-01-01 00:00:00'),
- (3, 'e', '2007-06-04 20:03:11'),
- (4, 'd', '2003-11-30 05:01:03'),
- (5, 'c', '2001-12-31 23:59:59');
---disable_warnings
-DROP TABLE IF EXISTS ta_l;
---enable_warnings
---disable_query_log
-echo CREATE TABLE ta_l (
- PRIMARY KEY(a)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT_2_1;
-eval CREATE TABLE ta_l (
- a INT,
- b CHAR(1),
- c DATETIME,
- PRIMARY KEY(a)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT_2_1;
---enable_query_log
-INSERT INTO ta_l SELECT a, b, c FROM tb_l;
-
---echo
---echo 0.9
---echo create different primary key table
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TABLES5;
- echo CHILD2_1_CREATE_TABLES5;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES5;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES5;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_query_log
-echo CREATE TABLE ta_l_int (
- a INT DEFAULT 10,
- b INT AUTO_INCREMENT,
- c INT DEFAULT 11,
- PRIMARY KEY(b)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1;
-eval CREATE TABLE ta_l_int (
- a INT DEFAULT 10,
- b INT AUTO_INCREMENT,
- c INT DEFAULT 11,
- PRIMARY KEY(b)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
---let $MASTER_1_IS_VP= `SELECT IF('$MASTER_1_ENGINE_TYPE' = 'VP', 1, 0)`
-if ($MASTER_1_IS_VP)
-{
- --error 14514
- INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
-}
-if (!$MASTER_1_IS_VP)
-{
- INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
- --disable_query_log
- --disable_result_log
- TRUNCATE TABLE ta_l_int;
- --enable_query_log
- --enable_result_log
-}
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES5;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo create un-correspond primary key table
---connection master_1
---disable_warnings
-DROP TABLE IF EXISTS ta_l_int;
---enable_warnings
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_result_log
- }
- --disable_query_log
- --connection child2_1
- if ($OUTPUT_CHILD_GROUP2)
- {
- echo CHILD2_1_DROP_TABLES5;
- echo CHILD2_1_CREATE_TABLES5;
- }
- --disable_warnings
- eval $CHILD2_1_DROP_TABLES5;
- --enable_warnings
- eval $CHILD2_1_CREATE_TABLES5;
- --enable_query_log
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_result_log
- }
-}
---connection master_1
---disable_query_log
-echo CREATE TABLE ta_l_int (
- a INT DEFAULT 10,
- b INT DEFAULT 12,
- c INT DEFAULT 11,
- PRIMARY KEY(c)
-) MASTER_1_ENGINE MASTER_1_CHARSET MASTER_1_COMMENT4_2_1;
-eval CREATE TABLE ta_l_int (
- a INT DEFAULT 10,
- b INT DEFAULT 12,
- c INT DEFAULT 11,
- PRIMARY KEY(c)
-) $MASTER_1_ENGINE $MASTER_1_CHARSET $MASTER_1_COMMENT4_2_1;
---enable_query_log
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- TRUNCATE TABLE mysql.general_log;
- }
- eval $CHILD2_1_SELECT_TABLES;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
---connection master_1
-if ($MASTER_1_IS_VP)
-{
- --error 14514
- INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
-}
-if (!$MASTER_1_IS_VP)
-{
- INSERT INTO ta_l_int (a, b, c) VALUES (2, NULL, 3);
- --disable_query_log
- --disable_result_log
- TRUNCATE TABLE ta_l_int;
- --enable_query_log
- --enable_result_log
-}
-if ($USE_CHILD_GROUP2)
-{
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --disable_query_log
- --disable_result_log
- }
- --connection child2_1
- if ($USE_GENERAL_LOG)
- {
- SELECT argument FROM mysql.general_log WHERE command_type != 'Execute' AND argument LIKE '%insert %';
- }
- eval $CHILD2_1_SELECT_TABLES5;
- if (!$OUTPUT_CHILD_GROUP2)
- {
- --enable_query_log
- --enable_result_log
- }
-}
-
---echo
---echo deinit
---disable_warnings
---connection master_1
-DROP DATABASE IF EXISTS auto_test_local;
-if ($USE_CHILD_GROUP2)
-{
- --connection child2_1
- DROP DATABASE IF EXISTS auto_test_remote;
- --connection child2_2
- DROP DATABASE IF EXISTS auto_test_remote2;
-}
---disable_query_log
---disable_result_log
---source test_deinit.inc
---enable_result_log
---enable_query_log
---enable_warnings
---echo
---echo end of test
diff --git a/storage/spider/mysql-test/spider/r/variable_deprecation.result b/storage/spider/mysql-test/spider/r/variable_deprecation.result
index 8840f1da892..21246a35104 100644
--- a/storage/spider/mysql-test/spider/r/variable_deprecation.result
+++ b/storage/spider/mysql-test/spider/r/variable_deprecation.result
@@ -13,21 +13,6 @@ child3_3
connection master_1;
CREATE DATABASE auto_test_local;
USE auto_test_local;
-# MDEV-27923 Deprecate spider_use_handler
-SET spider_use_handler = 3;
-Warnings:
-Warning 1287 '@@spider_use_handler' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_use_handler";
-Variable_name Value
-spider_use_handler 3
-CREATE TABLE tbl_a (a INT) ENGINE=Spider COMMENT='uhd "3"';
-Warnings:
-Warning 1287 The table parameter 'uhd' is deprecated and will be removed in a future release
-CREATE TABLE tbl_b (a INT) ENGINE=Spider COMMENT='use_handler "3"';
-Warnings:
-Warning 1287 The table parameter 'use_handler' is deprecated and will be removed in a future release
-DROP TABLE tbl_a;
-DROP TABLE tbl_b;
# MDEV-28297 Deprecate spider_internal_offset
SET spider_internal_offset = 1;
Warnings:
@@ -43,37 +28,6 @@ Warnings:
Warning 1287 The table parameter 'internal_offset' is deprecated and will be removed in a future release
DROP TABLE tbl_a;
DROP TABLE tbl_b;
-# MDEV-28005 Deprecate Spider plugin variables regarding UDFs
-SET GLOBAL spider_udf_ds_bulk_insert_rows = 1;
-Warnings:
-Warning 1287 '@@spider_udf_ds_bulk_insert_rows' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_udf_ds_bulk_insert_rows";
-Variable_name Value
-spider_udf_ds_bulk_insert_rows -1
-SET spider_udf_ds_table_loop_mode = 1;
-Warnings:
-Warning 1287 '@@spider_udf_ds_table_loop_mode' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_udf_ds_table_loop_mode";
-Variable_name Value
-spider_udf_ds_table_loop_mode 1
-SET spider_udf_ds_use_real_table = 1;
-Warnings:
-Warning 1287 '@@spider_udf_ds_use_real_table' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_udf_ds_use_real_table";
-Variable_name Value
-spider_udf_ds_use_real_table 1
-SET GLOBAL spider_udf_ct_bulk_insert_interval = 1;
-Warnings:
-Warning 1287 '@@spider_udf_ct_bulk_insert_interval' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_udf_ct_bulk_insert_interval";
-Variable_name Value
-spider_udf_ct_bulk_insert_interval 1
-SET GLOBAL spider_udf_ct_bulk_insert_rows = 1;
-Warnings:
-Warning 1287 '@@spider_udf_ct_bulk_insert_rows' is deprecated and will be removed in a future release
-SHOW VARIABLES LIKE "spider_udf_ct_bulk_insert_rows";
-Variable_name Value
-spider_udf_ct_bulk_insert_rows 1
# MDEV-27981 Deprecate spider_internal_limit
SET spider_internal_limit = 1;
Warnings:
diff --git a/storage/spider/mysql-test/spider/t/variable_deprecation.test b/storage/spider/mysql-test/spider/t/variable_deprecation.test
index 6c59deba5d0..ba1b00a41c0 100644
--- a/storage/spider/mysql-test/spider/t/variable_deprecation.test
+++ b/storage/spider/mysql-test/spider/t/variable_deprecation.test
@@ -12,14 +12,6 @@
CREATE DATABASE auto_test_local;
USE auto_test_local;
---echo # MDEV-27923 Deprecate spider_use_handler
-SET spider_use_handler = 3;
-SHOW VARIABLES LIKE "spider_use_handler";
-eval CREATE TABLE tbl_a (a INT) $MASTER_1_ENGINE COMMENT='uhd "3"';
-eval CREATE TABLE tbl_b (a INT) $MASTER_1_ENGINE COMMENT='use_handler "3"';
-DROP TABLE tbl_a;
-DROP TABLE tbl_b;
-
--echo # MDEV-28297 Deprecate spider_internal_offset
SET spider_internal_offset = 1;
SHOW VARIABLES LIKE "spider_internal_offset";
@@ -29,22 +21,6 @@ eval CREATE TABLE tbl_b (a INT) $MASTER_1_ENGINE COMMENT='internal_offset "1"';
DROP TABLE tbl_a;
DROP TABLE tbl_b;
---echo # MDEV-28005 Deprecate Spider plugin variables regarding UDFs
-SET GLOBAL spider_udf_ds_bulk_insert_rows = 1;
-SHOW VARIABLES LIKE "spider_udf_ds_bulk_insert_rows";
-
-SET spider_udf_ds_table_loop_mode = 1;
-SHOW VARIABLES LIKE "spider_udf_ds_table_loop_mode";
-
-SET spider_udf_ds_use_real_table = 1;
-SHOW VARIABLES LIKE "spider_udf_ds_use_real_table";
-
-SET GLOBAL spider_udf_ct_bulk_insert_interval = 1;
-SHOW VARIABLES LIKE "spider_udf_ct_bulk_insert_interval";
-
-SET GLOBAL spider_udf_ct_bulk_insert_rows = 1;
-SHOW VARIABLES LIKE "spider_udf_ct_bulk_insert_rows";
-
--echo # MDEV-27981 Deprecate spider_internal_limit
SET spider_internal_limit = 1;
SHOW VARIABLES LIKE "spider_internal_limit";
diff --git a/storage/spider/spd_conn.cc b/storage/spider/spd_conn.cc
index 91c6b91af30..366a22ef8d2 100644
--- a/storage/spider/spd_conn.cc
+++ b/storage/spider/spd_conn.cc
@@ -2161,8 +2161,6 @@ int spider_bg_conn_search(
result_list->split_read ?
result_list->split_read :
result_list->internal_limit - result_list->record_num;
- DBUG_PRINT("info",("spider sql_kinds=%u", spider->sql_kinds));
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->reappend_limit_sql_part(
result_list->internal_offset + result_list->record_num,
@@ -2181,17 +2179,6 @@ int spider_bg_conn_search(
DBUG_RETURN(error_num);
}
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- spider_db_append_handler_next(spider);
- if ((error_num = spider->reappend_limit_sql_part(
- 0, result_list->limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- pthread_mutex_unlock(&conn->bg_conn_mutex);
- DBUG_RETURN(error_num);
- }
- }
}
result_list->bgs_phase = 2;
if (conn->db_conn->limit_mode() == 1)
@@ -2310,8 +2297,6 @@ int spider_bg_conn_search(
result_list->split_read ?
result_list->split_read :
result_list->internal_limit - result_list->record_num;
- DBUG_PRINT("info",("spider sql_kinds=%u", spider->sql_kinds));
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->reappend_limit_sql_part(
result_list->internal_offset + result_list->record_num,
@@ -2330,17 +2315,6 @@ int spider_bg_conn_search(
DBUG_RETURN(error_num);
}
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- spider_db_append_handler_next(spider);
- if ((error_num = spider->reappend_limit_sql_part(
- 0, result_list->limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- pthread_mutex_unlock(&conn->bg_conn_mutex);
- DBUG_RETURN(error_num);
- }
- }
if (conn->db_conn->limit_mode() == 1)
{
conn->db_conn->set_limit(result_list->limit_num);
@@ -2542,12 +2516,7 @@ void *spider_bg_conn_action(
!result_list->bgs_current->result
) {
ulong sql_type;
- if (spider->sql_kind[conn->link_idx] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_TMP_SQL;
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
if (dbton_handler->need_lock_before_set_sql_for_exec(sql_type))
{
@@ -3930,91 +3899,6 @@ bool spider_conn_check_recovery_link(
DBUG_RETURN(FALSE);
}
-bool spider_conn_use_handler(
- ha_spider *spider,
- int lock_mode,
- int link_idx
-) {
- THD *thd = spider->wide_handler->trx->thd;
- int use_handler = spider_param_use_handler(thd,
- spider->share->use_handlers[link_idx]);
- DBUG_ENTER("spider_conn_use_handler");
- DBUG_PRINT("info",("spider use_handler=%d", use_handler));
- DBUG_PRINT("info",("spider spider->conn_kind[link_idx]=%u",
- spider->conn_kind[link_idx]));
- if (spider->do_direct_update)
- {
- spider->sql_kinds |= SPIDER_SQL_KIND_SQL;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_SQL;
- spider->direct_update_kinds |= SPIDER_SQL_KIND_SQL;
- DBUG_PRINT("info",("spider FALSE by using direct_update"));
- DBUG_RETURN(FALSE);
- }
- if (spider->use_spatial_index)
- {
- DBUG_PRINT("info",("spider FALSE by use_spatial_index"));
- spider->sql_kinds |= SPIDER_SQL_KIND_SQL;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_SQL;
- DBUG_RETURN(FALSE);
- }
- uint dbton_id;
- spider_db_handler *dbton_hdl;
- dbton_id = spider->share->sql_dbton_ids[spider->conn_link_idx[link_idx]];
- dbton_hdl = spider->dbton_handler[dbton_id];
- if (!dbton_hdl->support_use_handler(use_handler))
- {
- DBUG_PRINT("info",("spider FALSE by dbton"));
- spider->sql_kinds |= SPIDER_SQL_KIND_SQL;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_SQL;
- DBUG_RETURN(FALSE);
- }
- if (
- spider->wide_handler->sql_command == SQLCOM_HA_READ &&
- (
- !(use_handler & 2) ||
- (
- spider_param_sync_trx_isolation(thd) &&
- thd_tx_isolation(thd) == ISO_SERIALIZABLE
- )
- )
- ) {
- DBUG_PRINT("info",("spider TRUE by HA"));
- spider->sql_kinds |= SPIDER_SQL_KIND_HANDLER;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_HANDLER;
- DBUG_RETURN(TRUE);
- }
- if (
- spider->wide_handler->sql_command != SQLCOM_HA_READ &&
- lock_mode == SPIDER_LOCK_MODE_NO_LOCK &&
- spider_param_sync_trx_isolation(thd) &&
- thd_tx_isolation(thd) != ISO_SERIALIZABLE &&
- (use_handler & 1)
- ) {
- DBUG_PRINT("info",("spider TRUE by PARAM"));
- spider->sql_kinds |= SPIDER_SQL_KIND_HANDLER;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_HANDLER;
- DBUG_RETURN(TRUE);
- }
- spider->sql_kinds |= SPIDER_SQL_KIND_SQL;
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_SQL;
- DBUG_RETURN(FALSE);
-}
-
-bool spider_conn_need_open_handler(
- ha_spider *spider,
- uint idx,
- int link_idx
-) {
- DBUG_ENTER("spider_conn_need_open_handler");
- DBUG_PRINT("info",("spider spider=%p", spider));
- if (spider->handler_opened(link_idx, spider->conn_kind[link_idx]))
- {
- DBUG_PRINT("info",("spider HA already opened"));
- DBUG_RETURN(FALSE);
- }
- DBUG_RETURN(TRUE);
-}
-
SPIDER_CONN* spider_get_conn_from_idle_connection(
SPIDER_SHARE *share,
int link_idx,
diff --git a/storage/spider/spd_conn.h b/storage/spider/spd_conn.h
index 53c10572687..807e1474ed2 100644
--- a/storage/spider/spd_conn.h
+++ b/storage/spider/spd_conn.h
@@ -390,18 +390,6 @@ bool spider_conn_check_recovery_link(
SPIDER_SHARE *share
);
-bool spider_conn_use_handler(
- ha_spider *spider,
- int lock_mode,
- int link_idx
-);
-
-bool spider_conn_need_open_handler(
- ha_spider *spider,
- uint idx,
- int link_idx
-);
-
SPIDER_IP_PORT_CONN *spider_create_ipport_conn(SPIDER_CONN *conn);
SPIDER_CONN* spider_get_conn_from_idle_connection
(
diff --git a/storage/spider/spd_copy_tables.cc b/storage/spider/spd_copy_tables.cc
index 4b2f5174ce0..eb2454b2f29 100644
--- a/storage/spider/spd_copy_tables.cc
+++ b/storage/spider/spd_copy_tables.cc
@@ -1000,8 +1000,7 @@ long long spider_copy_tables_body(
else
copy_tables->access_charset = system_charset_info;
- bulk_insert_rows = spider_param_udf_ct_bulk_insert_rows(
- copy_tables->bulk_insert_rows);
+ bulk_insert_rows= copy_tables->bulk_insert_rows;
for (src_tbl_conn = copy_tables->table_conn[0]; src_tbl_conn;
src_tbl_conn = src_tbl_conn->next)
{
diff --git a/storage/spider/spd_db_conn.cc b/storage/spider/spd_db_conn.cc
index c29e9253b3f..a5118ea442f 100644
--- a/storage/spider/spd_db_conn.cc
+++ b/storage/spider/spd_db_conn.cc
@@ -169,7 +169,6 @@ int spider_db_connect(
conn->connect_error = 0;
conn->opened_handlers = 0;
- conn->db_conn->reset_opened_handler();
++conn->connection_id;
/* Set the connection's time zone to UTC */
@@ -1344,11 +1343,7 @@ int spider_db_append_name_with_quote_str_internal(
for (name_end = name + length; name < name_end; name += length)
{
head_code = *name;
-#ifdef SPIDER_HAS_MY_CHARLEN
if ((length = my_ci_charlen(cs, (const uchar *) name, (const uchar *) name_end)) < 1)
-#else
- if (!(length = my_mbcharlen(cs, (uchar) head_code)))
-#endif
{
my_message(ER_SPIDER_WRONG_CHARACTER_IN_NAME_NUM,
ER_SPIDER_WRONG_CHARACTER_IN_NAME_STR, MYF(0));
@@ -1377,18 +1372,11 @@ int spider_db_append_select(
int error_num;
DBUG_ENTER("spider_db_append_select");
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->append_select_sql_part(
SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = spider->append_select_sql_part(
- SPIDER_SQL_TYPE_HANDLER)))
- DBUG_RETURN(error_num);
- }
DBUG_RETURN(0);
}
@@ -1398,7 +1386,6 @@ int spider_db_append_select_columns(
int error_num;
SPIDER_RESULT_LIST *result_list = &spider->result_list;
DBUG_ENTER("spider_db_append_select_columns");
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (
result_list->direct_aggregate &&
@@ -1427,11 +1414,6 @@ int spider_db_append_select_columns(
DBUG_RETURN(error_num);
}
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = spider->append_from_sql_part(SPIDER_SQL_TYPE_HANDLER)))
- DBUG_RETURN(error_num);
- }
DBUG_RETURN(0);
}
@@ -1548,7 +1530,6 @@ int spider_db_append_hint_after_table(
spider_string *hint
) {
DBUG_ENTER("spider_db_append_hint_after_table");
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if (str->append(*hint))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
@@ -1588,19 +1569,9 @@ int spider_db_append_key_where_internal(
KEY_PART_INFO *key_part;
Field *field;
bool use_both = TRUE, key_eq;
- uint sql_kind;
spider_db_handler *dbton_hdl = spider->dbton_handler[dbton_id];
spider_db_share *dbton_share = share->dbton_share[dbton_id];
DBUG_ENTER("spider_db_append_key_where_internal");
- switch (sql_type)
- {
- case SPIDER_SQL_TYPE_HANDLER:
- sql_kind = SPIDER_SQL_KIND_HANDLER;
- break;
- default:
- sql_kind = SPIDER_SQL_KIND_SQL;
- break;
- }
if (key_info)
full_key_part_map =
@@ -1632,46 +1603,6 @@ int spider_db_append_key_where_internal(
MY_BITMAP *tmp_map = dbug_tmp_use_all_columns(table, &table->read_set);
#endif
- if (sql_kind == SPIDER_SQL_KIND_HANDLER)
- {
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
- const char *key_name = key_info->name.str;
- key_name_length = key_info->name.length;
-#else
- const char *key_name = key_info->name;
- key_name_length = strlen(key_name);
-#endif
- if (str->reserve(SPIDER_SQL_READ_LEN +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + key_name_length))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_READ_STR, SPIDER_SQL_READ_LEN);
- if ((error_num = spider_dbton[dbton_id].db_util->
- append_name(str, key_name, key_name_length)))
- {
- DBUG_RETURN(error_num);
- }
- dbton_hdl->set_order_pos(SPIDER_SQL_TYPE_HANDLER);
- if (
- (start_key_part_map || end_key_part_map) &&
- !(use_both && (!start_key_part_map || !end_key_part_map))
- ) {
- if (str_part->reserve(SPIDER_SQL_OPEN_PAREN_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str_part->q_append(SPIDER_SQL_OPEN_PAREN_STR, SPIDER_SQL_OPEN_PAREN_LEN);
- result_list->ha_read_kind = 0;
- } else if (!result_list->desc_flg)
- {
- if (str->reserve(SPIDER_SQL_FIRST_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_FIRST_STR, SPIDER_SQL_FIRST_LEN);
- result_list->ha_read_kind = 1;
- } else {
- if (str->reserve(SPIDER_SQL_LAST_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_LAST_STR, SPIDER_SQL_LAST_LEN);
- result_list->ha_read_kind = 2;
- }
- }
if (!start_key_part_map && !end_key_part_map)
{
result_list->key_order = 0;
@@ -1694,16 +1625,10 @@ int spider_db_append_key_where_internal(
if (start_key_part_map == end_key_part_map)
result_list->use_both_key = TRUE;
- if (sql_kind == SPIDER_SQL_KIND_SQL)
{
if (str->reserve(SPIDER_SQL_WHERE_LEN))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
str->q_append(SPIDER_SQL_WHERE_STR, SPIDER_SQL_WHERE_LEN);
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
- {
- if (str_part2->reserve(SPIDER_SQL_WHERE_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str_part2->q_append(SPIDER_SQL_WHERE_STR, SPIDER_SQL_WHERE_LEN);
}
for (
@@ -1763,18 +1688,14 @@ int spider_db_append_key_where_internal(
) {
if (error_num > 0)
DBUG_RETURN(error_num);
- if (
- !set_order &&
- start_key->flag != HA_READ_KEY_EXACT &&
- sql_kind == SPIDER_SQL_KIND_SQL
- ) {
+ if (!set_order && start_key->flag != HA_READ_KEY_EXACT)
+ {
result_list->key_order = key_count;
set_order = TRUE;
}
} else if (key_eq)
{
DBUG_PRINT("info", ("spider key_eq"));
- if (sql_kind == SPIDER_SQL_KIND_SQL)
{
if (str->reserve(store_length + key_name_length +
/* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
@@ -1786,252 +1707,101 @@ int spider_db_append_key_where_internal(
append_column_value(spider, str, field, ptr,
share->access_charset))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
- {
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_EQUAL_LEN + SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- str_part2->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
}
} else {
DBUG_PRINT("info", ("spider start_key->flag=%d", start_key->flag));
+ const char *op_str;
+ uint32 op_len;
switch (start_key->flag)
{
case HA_READ_PREFIX_LAST:
result_list->desc_flg = TRUE;
/* fall through */
case HA_READ_KEY_EXACT:
- if (sql_kind == SPIDER_SQL_KIND_SQL)
- {
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
- {
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- str_part2->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
- }
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
+ SPIDER_SQL_EQUAL_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
break;
case HA_READ_AFTER_KEY:
- if (sql_kind == SPIDER_SQL_KIND_SQL)
+ if (start_key_part_map == 1)
{
- const char* op_str;
- uint32 op_len;
- if (start_key_part_map == 1) {
- op_str = rev ? SPIDER_SQL_LT_STR : SPIDER_SQL_GT_STR;
- op_len = rev ? SPIDER_SQL_LT_LEN : SPIDER_SQL_GT_LEN;
- } else {
- op_str = rev ? SPIDER_SQL_LTEQUAL_STR : SPIDER_SQL_GTEQUAL_STR;
- op_len = rev ? SPIDER_SQL_LTEQUAL_LEN : SPIDER_SQL_GTEQUAL_LEN;
- }
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- str->q_append(op_str, op_len);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (use_both)
- start_key_part_map = 0;
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
+ op_str= rev ? SPIDER_SQL_LT_STR : SPIDER_SQL_GT_STR;
+ op_len= rev ? SPIDER_SQL_LT_LEN : SPIDER_SQL_GT_LEN;
+ }
+ else
{
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_GT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_LT_STR, SPIDER_SQL_LT_LEN);
- else
- str_part2->q_append(SPIDER_SQL_GT_STR, SPIDER_SQL_GT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_GT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_GT_STR, SPIDER_SQL_GT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ op_str= rev ? SPIDER_SQL_LTEQUAL_STR : SPIDER_SQL_GTEQUAL_STR;
+ op_len= rev ? SPIDER_SQL_LTEQUAL_LEN : SPIDER_SQL_GTEQUAL_LEN;
+ }
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ str->q_append(op_str, op_len);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (use_both)
+ start_key_part_map= 0;
+ if (!set_order)
+ {
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
case HA_READ_BEFORE_KEY:
result_list->desc_flg = TRUE;
- if (sql_kind == SPIDER_SQL_KIND_SQL)
+ if (start_key_part_map == 1)
{
- const char* op_str;
- uint32 op_len;
- if (start_key_part_map == 1) {
- op_str = rev ? SPIDER_SQL_GT_STR : SPIDER_SQL_LT_STR;
- op_len = rev ? SPIDER_SQL_GT_LEN : SPIDER_SQL_LT_LEN;
- } else {
- op_str = rev ? SPIDER_SQL_GTEQUAL_STR : SPIDER_SQL_LTEQUAL_STR;
- op_len = rev ? SPIDER_SQL_GTEQUAL_LEN : SPIDER_SQL_LTEQUAL_LEN;
- }
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- str->q_append(op_str, op_len);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (use_both)
- start_key_part_map = 0;
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
+ op_str= rev ? SPIDER_SQL_GT_STR : SPIDER_SQL_LT_STR;
+ op_len= rev ? SPIDER_SQL_GT_LEN : SPIDER_SQL_LT_LEN;
+ }
+ else
{
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_GT_STR, SPIDER_SQL_GT_LEN);
- else
- str_part2->q_append(SPIDER_SQL_LT_STR, SPIDER_SQL_LT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_LT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_LT_STR, SPIDER_SQL_LT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ op_str= rev ? SPIDER_SQL_GTEQUAL_STR : SPIDER_SQL_LTEQUAL_STR;
+ op_len= rev ? SPIDER_SQL_GTEQUAL_LEN : SPIDER_SQL_LTEQUAL_LEN;
+ }
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ str->q_append(op_str, op_len);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (use_both)
+ start_key_part_map= 0;
+ if (!set_order)
+ {
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
case HA_READ_KEY_OR_PREV:
case HA_READ_PREFIX_LAST_OR_PREV:
result_list->desc_flg = TRUE;
- if (sql_kind == SPIDER_SQL_KIND_SQL)
- {
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- if (rev)
- str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- else
- str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
+ SPIDER_SQL_LTEQUAL_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ if (rev)
+ str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
+ else
+ str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (!set_order)
{
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- else
- str_part2->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
case HA_READ_MBR_CONTAIN:
@@ -2124,73 +1894,29 @@ int spider_db_append_key_where_internal(
SPIDER_SQL_CLOSE_PAREN_LEN);
break;
default:
- if (sql_kind == SPIDER_SQL_KIND_SQL)
- {
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_GTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- if (rev)
- str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- else
- str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
+ SPIDER_SQL_GTEQUAL_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ if (rev)
+ str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
+ else
+ str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (!set_order)
{
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_GTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- else
- str_part2->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == start_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_GTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
}
}
- if (sql_kind == SPIDER_SQL_KIND_SQL)
- {
- if (str->reserve(SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_AND_STR,
- SPIDER_SQL_AND_LEN);
- } else if (sql_kind == SPIDER_SQL_KIND_HANDLER)
- {
- if (str_part2->reserve(SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str_part2->q_append(SPIDER_SQL_AND_STR,
- SPIDER_SQL_AND_LEN);
-
- }
+ if (str->reserve(SPIDER_SQL_AND_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ str->q_append(SPIDER_SQL_AND_STR, SPIDER_SQL_AND_LEN);
}
if (
@@ -2204,182 +1930,81 @@ int spider_db_append_key_where_internal(
{
if (error_num > 0)
DBUG_RETURN(error_num);
- if (
- !set_order &&
- end_key->flag != HA_READ_KEY_EXACT &&
- sql_kind == SPIDER_SQL_KIND_SQL
- ) {
+ if (!set_order && end_key->flag != HA_READ_KEY_EXACT)
+ {
result_list->key_order = key_count;
set_order = TRUE;
}
} else if (key_eq)
{
DBUG_PRINT("info", ("spider key_eq"));
- if (sql_kind == SPIDER_SQL_KIND_SQL)
- {
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_EQUAL_LEN + SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- } else {
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_EQUAL_LEN + SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- str_part2->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == end_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
- }
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
+ SPIDER_SQL_EQUAL_LEN + SPIDER_SQL_AND_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
} else {
DBUG_PRINT("info", ("spider end_key->flag=%d", end_key->flag));
switch (end_key->flag)
{
case HA_READ_BEFORE_KEY:
- if (sql_kind == SPIDER_SQL_KIND_SQL)
+ const char *op_str;
+ uint32 op_len;
+ if (end_key_part_map == 1)
{
- const char* op_str;
- uint32 op_len;
- if (end_key_part_map == 1) {
- op_str = rev ? SPIDER_SQL_GT_STR : SPIDER_SQL_LT_STR;
- op_len = rev ? SPIDER_SQL_GT_LEN : SPIDER_SQL_LT_LEN;
- } else {
- op_str = rev ? SPIDER_SQL_GTEQUAL_STR : SPIDER_SQL_LTEQUAL_STR;
- op_len = rev ? SPIDER_SQL_GTEQUAL_LEN : SPIDER_SQL_LTEQUAL_LEN;
- }
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- str->q_append(op_str, op_len);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (use_both)
- end_key_part_map = 0;
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else {
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_GT_STR, SPIDER_SQL_GT_LEN);
- else
- str_part2->q_append(SPIDER_SQL_LT_STR, SPIDER_SQL_LT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == end_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_LT_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_LT_STR, SPIDER_SQL_LT_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ op_str= rev ? SPIDER_SQL_GT_STR : SPIDER_SQL_LT_STR;
+ op_len= rev ? SPIDER_SQL_GT_LEN : SPIDER_SQL_LT_LEN;
+ }
+ else
+ {
+ op_str= rev ? SPIDER_SQL_GTEQUAL_STR : SPIDER_SQL_LTEQUAL_STR;
+ op_len= rev ? SPIDER_SQL_GTEQUAL_LEN : SPIDER_SQL_LTEQUAL_LEN;
+ }
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 + op_len))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ str->q_append(op_str, op_len);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (use_both)
+ end_key_part_map= 0;
+ if (!set_order)
+ {
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
default:
- if (sql_kind == SPIDER_SQL_KIND_SQL)
+ if (str->reserve(store_length + key_name_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
+ SPIDER_SQL_LTEQUAL_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ dbton_share->append_column_name(str, field->field_index);
+ if (rev)
+ str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
+ else
+ str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
+ if (spider_dbton[dbton_id].db_util->append_column_value(
+ spider, str, field, ptr, share->access_charset))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ if (!set_order)
{
- if (str->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str, field->field_index);
- if (rev)
- str->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- else
- str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (!set_order)
- {
- result_list->key_order = key_count;
- set_order = TRUE;
- }
- } else {
- if (str_part2->reserve(store_length + key_name_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 2 +
- SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- dbton_share->append_column_name(str_part2, field->field_index);
- if (rev)
- str_part2->q_append(SPIDER_SQL_GTEQUAL_STR, SPIDER_SQL_GTEQUAL_LEN);
- else
- str_part2->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part2, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
-
- if (use_key == end_key)
- {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_LTEQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_LTEQUAL_STR, SPIDER_SQL_LTEQUAL_LEN);
- if (spider_dbton[dbton_id].db_util->
- append_column_value(spider, str_part, field, ptr,
- share->access_charset))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- }
+ result_list->key_order= key_count;
+ set_order= TRUE;
}
break;
}
}
- if (sql_kind == SPIDER_SQL_KIND_SQL)
{
if (str->reserve(SPIDER_SQL_AND_LEN))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_AND_STR,
- SPIDER_SQL_AND_LEN);
- } else {
- if (str_part2->reserve(SPIDER_SQL_AND_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str_part2->q_append(SPIDER_SQL_AND_STR,
- SPIDER_SQL_AND_LEN);
-
+ str->q_append(SPIDER_SQL_AND_STR, SPIDER_SQL_AND_LEN);
}
}
if (use_both && (!start_key_part_map || !end_key_part_map))
@@ -2398,8 +2023,9 @@ end:
/* use condition */
if (dbton_hdl->append_condition_part(NULL, 0, sql_type, FALSE))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- if (sql_kind == SPIDER_SQL_KIND_SQL)
+ {
dbton_hdl->set_order_pos(sql_type);
+ }
#ifndef DBUG_OFF
dbug_tmp_restore_column_map(&table->read_set, tmp_map);
#endif
@@ -2413,20 +2039,12 @@ int spider_db_append_key_where(
) {
int error_num;
DBUG_ENTER("spider_db_append_key_where");
- if ((spider->sql_kinds & SPIDER_SQL_KIND_SQL))
{
DBUG_PRINT("info",("spider call internal by SPIDER_SQL_KIND_SQL"));
if ((error_num = spider->append_key_where_sql_part(start_key, end_key,
SPIDER_SQL_TYPE_SELECT_SQL)))
DBUG_RETURN(error_num);
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- DBUG_PRINT("info",("spider call internal by SPIDER_SQL_KIND_HANDLER"));
- if ((error_num = spider->append_key_where_sql_part(start_key, end_key,
- SPIDER_SQL_TYPE_HANDLER)))
- DBUG_RETURN(error_num);
- }
DBUG_RETURN(0);
}
@@ -2539,9 +2157,7 @@ int spider_db_fetch_for_item_sum_func(
spider->direct_aggregate_item_first->next = NULL;
spider->direct_aggregate_item_first->item = NULL;
spider->direct_aggregate_item_first->tgt_num = 0;
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
spider->direct_aggregate_item_first->init_mem_root = FALSE;
-#endif
}
spider->direct_aggregate_item_current =
spider->direct_aggregate_item_first;
@@ -2558,16 +2174,13 @@ int spider_db_fetch_for_item_sum_func(
spider->direct_aggregate_item_current->next->item = NULL;
spider->direct_aggregate_item_current->next->tgt_num =
spider->direct_aggregate_item_current->tgt_num + 1;
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
spider->direct_aggregate_item_current->next->init_mem_root = FALSE;
-#endif
}
spider->direct_aggregate_item_current =
spider->direct_aggregate_item_current->next;
}
if (!spider->direct_aggregate_item_current->item)
{
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
if (!spider->direct_aggregate_item_current->init_mem_root)
{
SPD_INIT_ALLOC_ROOT(
@@ -2575,19 +2188,10 @@ int spider_db_fetch_for_item_sum_func(
4096, 0, MYF(MY_WME));
spider->direct_aggregate_item_current->init_mem_root = TRUE;
}
-#endif
Item *free_list = thd->free_list;
spider->direct_aggregate_item_current->item =
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
new (&spider->direct_aggregate_item_current->mem_root)
Item_string(thd, "", 0, share->access_charset);
-#else
- new Item_string("", 0, share->access_charset);
-#endif
-#else
- new Item_string(share->access_charset);
-#endif
if (!spider->direct_aggregate_item_current->item)
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
thd->free_list = free_list;
@@ -2598,12 +2202,8 @@ int spider_db_fetch_for_item_sum_func(
(Item_string *) spider->direct_aggregate_item_current->item;
if (row->is_null())
{
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY
item->val_str(NULL)->length(0);
item->append(NULL, 0);
-#else
- item->set_str_with_copy(NULL, 0);
-#endif
item->null_value = TRUE;
} else {
char buf[MAX_FIELD_WIDTH];
@@ -2612,12 +2212,8 @@ int spider_db_fetch_for_item_sum_func(
tmp_str.length(0);
if ((error_num = row->append_to_str(&tmp_str)))
DBUG_RETURN(error_num);
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY
item->val_str(NULL)->length(0);
item->append((char *) tmp_str.ptr(), tmp_str.length());
-#else
- item->set_str_with_copy(tmp_str.ptr(), tmp_str.length());
-#endif
item->null_value = FALSE;
}
item_sum_min_max->direct_add(item);
@@ -2683,27 +2279,6 @@ int spider_db_append_match_where(
DBUG_RETURN(0);
}
-void spider_db_append_handler_next(
- ha_spider *spider
-) {
- const char *alias;
- uint alias_length;
- SPIDER_RESULT_LIST *result_list = &spider->result_list;
- DBUG_ENTER("spider_db_append_handler_next");
- if (result_list->sorted && result_list->desc_flg)
- {
- alias = SPIDER_SQL_PREV_STR;
- alias_length = SPIDER_SQL_PREV_LEN;
- } else {
- alias = SPIDER_SQL_NEXT_STR;
- alias_length = SPIDER_SQL_NEXT_LEN;
- }
- spider->set_order_to_pos_sql(SPIDER_SQL_TYPE_HANDLER);
- spider->append_key_order_with_alias_sql_part(alias, alias_length,
- SPIDER_SQL_TYPE_HANDLER);
- DBUG_VOID_RETURN;
-}
-
void spider_db_get_row_from_tmp_tbl_rec(
SPIDER_RESULT *current,
SPIDER_DB_ROW **row
@@ -2846,7 +2421,6 @@ int spider_db_fetch_table(
if (spider->mrr_with_cnt)
{
DBUG_PRINT("info", ("spider mrr_with_cnt"));
- if (spider->sql_kind[spider->result_link_idx] == SPIDER_SQL_KIND_SQL)
{
if (!row->is_null())
spider->multi_range_hit_point = row->val_int();
@@ -2858,9 +2432,6 @@ int spider_db_fetch_table(
else
DBUG_RETURN(ER_SPIDER_UNKNOWN_NUM);
row->next();
- } else {
- spider->multi_range_hit_point = 0;
- result_list->snap_mrr_with_cnt = FALSE;
}
}
@@ -3340,7 +2911,7 @@ int spider_db_free_result(
DBUG_RETURN(error_num);
}
}
- if (realloced & (SPIDER_SQL_TYPE_SELECT_SQL | SPIDER_SQL_TYPE_HANDLER))
+ if (realloced & (SPIDER_SQL_TYPE_SELECT_SQL))
{
for (roop_count = 0; roop_count < (int) share->link_count;
roop_count++)
@@ -4360,7 +3931,6 @@ int spider_db_fetch(
int error_num;
SPIDER_RESULT_LIST *result_list = &spider->result_list;
DBUG_ENTER("spider_db_fetch");
- if (spider->sql_kind[spider->result_link_idx] == SPIDER_SQL_KIND_SQL)
{
if (!spider->select_column_mode) {
if (result_list->keyread)
@@ -4372,9 +3942,6 @@ int spider_db_fetch(
} else
error_num = spider_db_fetch_minimum_columns(spider, buf, table,
result_list);
- } else {
- error_num = spider_db_fetch_table(spider, buf, table,
- result_list);
}
result_list->current_row_num++;
DBUG_PRINT("info",("spider error_num=%d", error_num));
@@ -4513,7 +4080,6 @@ int spider_db_seek_next(
result_list->split_read ?
result_list->split_read :
result_list->internal_limit - result_list->record_num;
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->reappend_limit_sql_part(
result_list->record_num, result_list->limit_num,
@@ -4531,17 +4097,6 @@ int spider_db_seek_next(
DBUG_RETURN(error_num);
}
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- spider_db_append_handler_next(spider);
- if ((error_num = spider->reappend_limit_sql_part(
- 0, result_list->limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- {
- DBUG_PRINT("info",("spider error_num 5=%d", error_num));
- DBUG_RETURN(error_num);
- }
- }
if (spider->use_fields)
{
@@ -4673,13 +4228,8 @@ int spider_db_seek_next(
SPIDER_LINK_STATUS_RECOVERY)
) {
ulong sql_type;
- conn = spider->conns[roop_count];
- if (spider->sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ conn= spider->conns[roop_count];
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
spider_db_handler *dbton_handler =
spider->dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
@@ -4905,7 +4455,6 @@ int spider_db_seek_last(
spider_next_split_read_param(spider);
result_list->limit_num =
result_list->internal_limit - result_list->record_num;
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->reappend_limit_sql_part(
result_list->internal_offset + result_list->record_num,
@@ -4919,21 +4468,6 @@ int spider_db_seek_last(
)
DBUG_RETURN(error_num);
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- spider_db_append_handler_next(spider);
- if ((error_num = spider->reappend_limit_sql_part(
- result_list->internal_offset + result_list->record_num,
- result_list->limit_num,
- SPIDER_SQL_TYPE_HANDLER)))
- DBUG_RETURN(error_num);
- if (
- !result_list->use_union &&
- (error_num = spider->append_select_lock_sql_part(
- SPIDER_SQL_TYPE_HANDLER))
- )
- DBUG_RETURN(error_num);
- }
int roop_start, roop_end, roop_count, lock_mode, link_ok;
lock_mode = spider_conn_lock_mode(spider);
@@ -4958,12 +4492,7 @@ int spider_db_seek_last(
SPIDER_LINK_STATUS_RECOVERY)
) {
ulong sql_type;
- if (spider->sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
conn = spider->conns[roop_count];
spider_db_handler *dbton_handler = spider->dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
@@ -5129,7 +4658,6 @@ int spider_db_seek_last(
result_list->limit_num =
result_list->internal_limit >= result_list->split_read ?
result_list->split_read : result_list->internal_limit;
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
spider->set_order_to_pos_sql(SPIDER_SQL_TYPE_SELECT_SQL);
if (
@@ -5140,35 +4668,12 @@ int spider_db_seek_last(
result_list->limit_num, SPIDER_SQL_TYPE_SELECT_SQL)) ||
(
!result_list->use_union &&
- (spider->sql_kinds & SPIDER_SQL_KIND_SQL) &&
(error_num = spider->append_select_lock_sql_part(
SPIDER_SQL_TYPE_SELECT_SQL))
)
)
DBUG_RETURN(error_num);
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- const char *alias;
- uint alias_length;
- if (result_list->sorted && result_list->desc_flg)
- {
- alias = SPIDER_SQL_LAST_STR;
- alias_length = SPIDER_SQL_LAST_LEN;
- } else {
- alias = SPIDER_SQL_FIRST_STR;
- alias_length = SPIDER_SQL_FIRST_LEN;
- }
- spider->set_order_to_pos_sql(SPIDER_SQL_TYPE_HANDLER);
- if (
- (error_num = spider->append_key_order_with_alias_sql_part(
- alias, alias_length, SPIDER_SQL_TYPE_HANDLER)) ||
- (error_num = spider->reappend_limit_sql_part(
- result_list->internal_offset,
- result_list->limit_num, SPIDER_SQL_TYPE_HANDLER))
- )
- DBUG_RETURN(error_num);
- }
int roop_start, roop_end, roop_count, lock_mode, link_ok;
lock_mode = spider_conn_lock_mode(spider);
@@ -5193,12 +4698,7 @@ int spider_db_seek_last(
SPIDER_LINK_STATUS_RECOVERY)
) {
ulong sql_type;
- if (spider->sql_kind[roop_count] == SPIDER_SQL_KIND_SQL)
- {
- sql_type = SPIDER_SQL_TYPE_SELECT_SQL;
- } else {
- sql_type = SPIDER_SQL_TYPE_HANDLER;
- }
+ sql_type= SPIDER_SQL_TYPE_SELECT_SQL;
conn = spider->conns[roop_count];
spider_db_handler *dbton_handler = spider->dbton_handler[conn->dbton_id];
pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
@@ -5407,7 +4907,6 @@ void spider_db_create_position(
pos->use_position = TRUE;
pos->mrr_with_cnt = spider->mrr_with_cnt;
pos->direct_aggregate = result_list->direct_aggregate;
- pos->sql_kind = spider->sql_kind[spider->result_link_idx];
pos->position_bitmap = spider->wide_handler->position_bitmap;
pos->ft_first = spider->ft_first;
pos->ft_current = spider->ft_current;
@@ -5430,7 +4929,6 @@ int spider_db_seek_tmp(
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
pos->row->first();
}
- if (pos->sql_kind == SPIDER_SQL_KIND_SQL)
{
if (!spider->select_column_mode)
{
@@ -5441,8 +4939,7 @@ int spider_db_seek_tmp(
error_num = spider_db_seek_tmp_table(buf, pos, spider, table);
} else
error_num = spider_db_seek_tmp_minimum_columns(buf, pos, spider, table);
- } else
- error_num = spider_db_seek_tmp_table(buf, pos, spider, table);
+ }
DBUG_PRINT("info",("spider error_num=%d", error_num));
DBUG_RETURN(error_num);
@@ -5485,11 +4982,8 @@ int spider_db_seek_tmp_table(
if (pos->mrr_with_cnt)
{
DBUG_PRINT("info", ("spider mrr_with_cnt"));
- if (pos->sql_kind == SPIDER_SQL_KIND_SQL)
{
row->next();
- } else {
- spider->result_list.snap_mrr_with_cnt = FALSE;
}
}
@@ -5904,7 +5398,6 @@ int spider_db_bulk_insert_init(
int error_num, roop_count;
SPIDER_SHARE *share = spider->share;
DBUG_ENTER("spider_db_bulk_insert_init");
- spider->sql_kinds = 0;
spider->reset_sql_sql(SPIDER_SQL_TYPE_INSERT_SQL);
for (
roop_count = spider_conn_link_idx_next(share->link_statuses,
@@ -5918,8 +5411,6 @@ int spider_db_bulk_insert_init(
if (spider->conns[roop_count])
spider->conns[roop_count]->ignore_dup_key =
spider->wide_handler->ignore_dup_key;
- spider_conn_use_handler(spider, spider->wide_handler->lock_mode,
- roop_count);
}
if (
(error_num = spider->append_insert_sql_part()) ||
@@ -5946,8 +5437,7 @@ int spider_db_bulk_insert(
if ((error_num = spider->append_insert_values_sql_part(
SPIDER_SQL_TYPE_INSERT_SQL)))
{
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
DBUG_RETURN(error_num);
}
}
@@ -5959,8 +5449,7 @@ int spider_db_bulk_insert(
if ((error_num = spider->append_insert_terminator_sql_part(
SPIDER_SQL_TYPE_INSERT_SQL)))
{
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
DBUG_RETURN(error_num);
}
bool insert_info = FALSE;
@@ -5987,8 +5476,7 @@ int spider_db_bulk_insert(
if ((error_num = dbton_handler->set_sql_for_exec(sql_type,
roop_count2)))
{
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
if (dbton_handler->need_lock_before_set_sql_for_exec(sql_type))
{
SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
@@ -6008,8 +5496,7 @@ int spider_db_bulk_insert(
conn->mta_conn_mutex_unlock_later = TRUE;
if ((error_num = spider_db_set_names(spider, conn, roop_count2)))
{
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
conn->mta_conn_mutex_lock_already = FALSE;
@@ -6042,14 +5529,10 @@ int spider_db_bulk_insert(
spider_conn_set_timeout_from_share(conn, roop_count2,
spider->wide_handler->trx->thd,
share);
- if (dbton_handler->execute_sql(
- sql_type,
- conn,
- -1,
- &spider->need_mons[roop_count2])
- ) {
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ if (dbton_handler->execute_sql(sql_type, conn, -1,
+ &spider->need_mons[roop_count2]))
+ {
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
error_num = spider_db_errorno(conn);
if (error_num == HA_ERR_FOUND_DUPP_KEY)
{
@@ -6113,9 +5596,8 @@ int spider_db_bulk_insert(
DBUG_ASSERT(!conn->mta_conn_mutex_lock_already);
DBUG_ASSERT(!conn->mta_conn_mutex_unlock_later);
conn->mta_conn_mutex_lock_already = TRUE;
- conn->mta_conn_mutex_unlock_later = TRUE;
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
- spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
+ conn->mta_conn_mutex_unlock_later= TRUE;
+ spider->set_insert_to_pos_sql(SPIDER_SQL_TYPE_INSERT_SQL);
if (table->next_number_field &&
(
!table->auto_increment_field_not_null ||
@@ -6722,30 +6204,15 @@ int spider_db_direct_update(
if ((error_num = spider->append_update_sql_part()))
DBUG_RETURN(error_num);
-/*
- SQL access -> SQL remote access
- !spider->do_direct_update &&
- (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
-
- SQL access -> SQL remote access with dirct_update
- spider->do_direct_update &&
- spider->direct_update_kinds == SPIDER_SQL_KIND_SQL &&
- spider->wide_handler->direct_update_fields
-*/
-
if (!spider->do_direct_update)
{
- if (
- (spider->sql_kinds & SPIDER_SQL_KIND_SQL) &&
- (error_num = spider->append_update_set_sql_part())
- ) {
+ if ((error_num= spider->append_update_set_sql_part()))
+ {
DBUG_RETURN(error_num);
}
} else {
- if (
- (spider->direct_update_kinds & SPIDER_SQL_KIND_SQL) &&
- (error_num = spider->append_direct_update_set_sql_part())
- ) {
+ if ((error_num= spider->append_direct_update_set_sql_part()))
+ {
DBUG_RETURN(error_num);
}
}
@@ -6761,7 +6228,6 @@ int spider_db_direct_update(
result_list->internal_limit >= select_limit ?
select_limit : result_list->internal_limit;
result_list->internal_offset += offset_limit;
- if (spider->direct_update_kinds & SPIDER_SQL_KIND_SQL)
{
if (
(error_num = spider->append_key_where_sql_part(
@@ -7042,7 +6508,6 @@ int spider_db_direct_delete(
result_list->internal_limit >= select_limit ?
select_limit : result_list->internal_limit;
result_list->internal_offset += offset_limit;
- if (spider->direct_update_kinds & SPIDER_SQL_KIND_SQL)
{
if (
(error_num = spider->append_delete_sql_part()) ||
@@ -7188,7 +6653,6 @@ int spider_db_direct_delete(
pthread_mutex_unlock(&conn->mta_conn_mutex);
}
int error_num2 = 0;
- if (spider->direct_update_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->reset_sql_sql(SPIDER_SQL_TYPE_DELETE_SQL)))
error_num2 = error_num;
@@ -7954,9 +7418,7 @@ int spider_db_print_item_type(
field, spider, str, alias, alias_length, dbton_id, use_fields, fields));
case Item::SUBSELECT_ITEM:
case Item::TRIGGER_FIELD_ITEM:
-#ifdef SPIDER_HAS_EXPR_CACHE_ITEM
case Item::EXPR_CACHE_ITEM:
-#endif
DBUG_RETURN(ER_SPIDER_COND_SKIP_NUM);
default:
DBUG_RETURN(spider_db_print_item_type_default(item, spider, str));
@@ -8181,13 +7643,8 @@ int spider_db_open_item_ident(
}
if (str)
{
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if (item_ident->field_name.str)
field_name_length = item_ident->field_name.length;
-#else
- if (item_ident->field_name)
- field_name_length = strlen(item_ident->field_name);
-#endif
else
field_name_length = 0;
if (share->access_charset->cset == system_charset_info->cset)
@@ -8198,14 +7655,9 @@ int spider_db_open_item_ident(
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
}
str->q_append(alias, alias_length);
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if ((error_num = spider_dbton[dbton_id].db_util->
append_escaped_name(str, item_ident->field_name.str,
field_name_length)))
-#else
- if ((error_num = spider_dbton[dbton_id].db_util->
- append_escaped_name(str, item_ident->field_name, field_name_length)))
-#endif
{
DBUG_RETURN(error_num);
}
@@ -8213,15 +7665,9 @@ int spider_db_open_item_ident(
if (str->reserve(alias_length))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
str->q_append(alias, alias_length);
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if ((error_num = spider_dbton[dbton_id].db_util->
append_escaped_name_with_charset(str, item_ident->field_name.str,
field_name_length, system_charset_info)))
-#else
- if ((error_num = spider_dbton[dbton_id].db_util->
- append_escaped_name_with_charset(str, item_ident->field_name,
- field_name_length, system_charset_info)))
-#endif
{
DBUG_RETURN(error_num);
}
@@ -8332,7 +7778,6 @@ int spider_db_open_item_ref(
DBUG_ENTER("spider_db_open_item_ref");
if (item_ref->ref)
{
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if (
(*(item_ref->ref))->type() != Item::CACHE_ITEM &&
item_ref->ref_type() != Item_ref::VIEW_REF &&
@@ -8340,34 +7785,16 @@ int spider_db_open_item_ref(
item_ref->name.str &&
item_ref->alias_name_used
)
-#else
- if (
- (*(item_ref->ref))->type() != Item::CACHE_ITEM &&
- item_ref->ref_type() != Item_ref::VIEW_REF &&
- !item_ref->table_name &&
- item_ref->name &&
- item_ref->alias_name_used
- )
-#endif
{
if (str)
{
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
uint length = item_ref->name.length;
-#else
- uint length = strlen(item_ref->name);
-#endif
if (str->reserve(length + /* SPIDER_SQL_NAME_QUOTE_LEN */ 2))
{
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
}
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if ((error_num = spider_dbton[dbton_id].db_util->
append_name(str, item_ref->name.str, length)))
-#else
- if ((error_num = spider_dbton[dbton_id].db_util->
- append_name(str, item_ref->name, length)))
-#endif
{
DBUG_RETURN(error_num);
}
@@ -8614,12 +8041,10 @@ int spider_db_open_item_int(
thd->variables.time_zone = UTC;
print_quoted_string = TRUE;
} else {
-#ifdef SPIDER_ITEM_HAS_CMP_TYPE
DBUG_PRINT("info",("spider cmp_type=%u", item->cmp_type()));
if (item->cmp_type() == TIME_RESULT)
print_quoted_string = TRUE;
else
-#endif
print_quoted_string = FALSE;
}
@@ -8813,18 +8238,11 @@ int spider_db_append_condition(
DBUG_ENTER("spider_db_append_condition");
if (!test_flg)
{
- if (spider->sql_kinds & SPIDER_SQL_KIND_SQL)
{
if ((error_num = spider->append_condition_sql_part(
alias, alias_length, SPIDER_SQL_TYPE_SELECT_SQL, FALSE)))
DBUG_RETURN(error_num);
}
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- if ((error_num = spider->append_condition_sql_part(
- alias, alias_length, SPIDER_SQL_TYPE_HANDLER, FALSE)))
- DBUG_RETURN(error_num);
- }
} else {
if (spider->wide_handler->cond_check)
DBUG_RETURN(spider->wide_handler->cond_check_error);
@@ -9138,10 +8556,8 @@ int spider_db_udf_direct_sql(
SPIDER_CONN *conn = direct_sql->conn;
SPIDER_DB_RESULT *result = NULL;
TABLE *table;
- int bulk_insert_rows = (int) spider_param_udf_ds_bulk_insert_rows(thd,
- direct_sql->bulk_insert_rows);
- int table_loop_mode = spider_param_udf_ds_table_loop_mode(thd,
- direct_sql->table_loop_mode);
+ int bulk_insert_rows= (int) direct_sql->bulk_insert_rows;
+ int table_loop_mode= direct_sql->table_loop_mode;
double ping_interval_at_trx_start =
spider_param_ping_interval_at_trx_start(thd);
time_t tmp_time = (time_t) time((time_t*) 0);
@@ -9255,14 +8671,13 @@ int spider_db_udf_direct_sql(
{
while (!error_num && !end_of_file)
{
- udf_table_mutex_index = spider_udf_calc_hash(
- direct_sql->db_names[roop_count],
- spider_param_udf_table_lock_mutex_count());
- udf_table_mutex_index += spider_udf_calc_hash(
- direct_sql->table_names[roop_count],
- spider_param_udf_table_lock_mutex_count());
- udf_table_mutex_index %=
- spider_param_udf_table_lock_mutex_count();
+ udf_table_mutex_index=
+ spider_udf_calc_hash(direct_sql->db_names[roop_count],
+ spider_udf_table_lock_mutex_count);
+ udf_table_mutex_index+=
+ spider_udf_calc_hash(direct_sql->table_names[roop_count],
+ spider_udf_table_lock_mutex_count);
+ udf_table_mutex_index%= spider_udf_table_lock_mutex_count;
pthread_mutex_lock(
&trx->udf_table_mutexes[udf_table_mutex_index]);
table = direct_sql->tables[roop_count];
@@ -10037,13 +9452,8 @@ int spider_db_udf_copy_key_row(
) {
int error_num;
DBUG_ENTER("spider_db_udf_copy_key_row");
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
if ((error_num = spider_db_append_name_with_quote_str(str,
(char *) field->field_name.str, dbton_id)))
-#else
- if ((error_num = spider_db_append_name_with_quote_str(str,
- (char *) field->field_name, dbton_id)))
-#endif
DBUG_RETURN(error_num);
if (str->reserve(joint_length + *length + SPIDER_SQL_AND_LEN))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
@@ -10313,8 +9723,7 @@ int spider_db_udf_copy_tables(
pthread_mutex_unlock(&tmp_conn->mta_conn_mutex);
goto error_db_query;
}
- bulk_insert_rows = spider_param_udf_ct_bulk_insert_rows(
- copy_tables->bulk_insert_rows);
+ bulk_insert_rows= copy_tables->bulk_insert_rows;
if (
select_ct->append_key_order_str(key_info, 0, FALSE) ||
select_ct->append_limit(0, bulk_insert_rows) ||
@@ -10526,8 +9935,7 @@ int spider_db_udf_copy_tables(
insert_ct->set_sql_to_pos();
}
DBUG_PRINT("info",("spider sleep"));
- bulk_insert_interval = spider_param_udf_ct_bulk_insert_interval(
- copy_tables->bulk_insert_interval);
+ bulk_insert_interval= copy_tables->bulk_insert_interval;
my_sleep(bulk_insert_interval);
}
}
@@ -10588,151 +9996,6 @@ error:
DBUG_RETURN(error_num);
}
-int spider_db_open_handler(
- ha_spider *spider,
- SPIDER_CONN *conn,
- int link_idx
-) {
- int error_num;
- SPIDER_SHARE *share = spider->share;
- uint *handler_id_ptr =
- &spider->m_handler_id[link_idx]
- ;
- spider_db_handler *dbton_hdl = spider->dbton_handler[conn->dbton_id];
- DBUG_ENTER("spider_db_open_handler");
- pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
- pthread_mutex_lock(&conn->mta_conn_mutex);
- SPIDER_SET_FILE_POS(&conn->mta_conn_mutex_file_pos);
- conn->need_mon = &spider->need_mons[link_idx];
- DBUG_ASSERT(conn->mta_conn_mutex_file_pos.file_name);
- DBUG_ASSERT(!conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(!conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = TRUE;
- conn->mta_conn_mutex_unlock_later = TRUE;
- if (!spider->handler_opened(link_idx, conn->conn_kind))
- *handler_id_ptr = conn->opened_handlers;
-
- if (!spider->handler_opened(link_idx, conn->conn_kind))
- my_sprintf(spider->m_handler_cid[link_idx],
- (spider->m_handler_cid[link_idx], SPIDER_SQL_HANDLER_CID_FORMAT,
- *handler_id_ptr));
-
- if ((error_num = dbton_hdl->append_open_handler_part(
- SPIDER_SQL_TYPE_HANDLER, *handler_id_ptr, conn, link_idx)))
- {
- goto error;
- }
-
- spider_conn_set_timeout_from_share(conn, link_idx,
- spider->wide_handler->trx->thd,
- share);
- if (dbton_hdl->execute_sql(
- SPIDER_SQL_TYPE_HANDLER,
- conn,
- -1,
- &spider->need_mons[link_idx])
- ) {
- error_num = spider_db_errorno(conn);
- goto error;
- }
- dbton_hdl->reset_sql(SPIDER_SQL_TYPE_HANDLER);
-
- if (!spider->handler_opened(link_idx, conn->conn_kind))
- {
- if ((error_num = dbton_hdl->insert_opened_handler(conn, link_idx)))
- goto error;
- conn->opened_handlers++;
- }
- DBUG_PRINT("info",("spider conn=%p", conn));
- DBUG_PRINT("info",("spider opened_handlers=%u", conn->opened_handlers));
- DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = FALSE;
- conn->mta_conn_mutex_unlock_later = FALSE;
- SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
- pthread_mutex_unlock(&conn->mta_conn_mutex);
- DBUG_RETURN(0);
-
-error:
- DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = FALSE;
- conn->mta_conn_mutex_unlock_later = FALSE;
- SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
- pthread_mutex_unlock(&conn->mta_conn_mutex);
- DBUG_RETURN(error_num);
-}
-
-
-int spider_db_close_handler(
- ha_spider *spider,
- SPIDER_CONN *conn,
- int link_idx,
- uint tgt_conn_kind
-) {
- int error_num;
- spider_db_handler *dbton_hdl = spider->dbton_handler[conn->dbton_id];
- DBUG_ENTER("spider_db_close_handler");
- DBUG_PRINT("info",("spider conn=%p", conn));
- pthread_mutex_assert_not_owner(&conn->mta_conn_mutex);
- pthread_mutex_lock(&conn->mta_conn_mutex);
- SPIDER_SET_FILE_POS(&conn->mta_conn_mutex_file_pos);
- conn->need_mon = &spider->need_mons[link_idx];
- DBUG_ASSERT(!conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(!conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = TRUE;
- conn->mta_conn_mutex_unlock_later = TRUE;
- if (spider->handler_opened(link_idx, tgt_conn_kind))
- {
- dbton_hdl->reset_sql(SPIDER_SQL_TYPE_HANDLER);
- if ((error_num = dbton_hdl->append_close_handler_part(
- SPIDER_SQL_TYPE_HANDLER, link_idx)))
- {
- DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = FALSE;
- conn->mta_conn_mutex_unlock_later = FALSE;
- SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
- pthread_mutex_unlock(&conn->mta_conn_mutex);
- DBUG_RETURN(error_num);
- }
-
- spider_conn_set_timeout_from_share(conn, link_idx,
- spider->wide_handler->trx->thd,
- spider->share);
- if (dbton_hdl->execute_sql(
- SPIDER_SQL_TYPE_HANDLER,
- conn,
- -1,
- &spider->need_mons[link_idx])
- ) {
- error_num = spider_db_errorno(conn);
- goto error;
- }
- dbton_hdl->reset_sql(SPIDER_SQL_TYPE_HANDLER);
- if ((error_num = dbton_hdl->delete_opened_handler(conn, link_idx)))
- goto error;
- conn->opened_handlers--;
- DBUG_PRINT("info",("spider opened_handlers=%u", conn->opened_handlers));
- }
- DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = FALSE;
- conn->mta_conn_mutex_unlock_later = FALSE;
- SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
- pthread_mutex_unlock(&conn->mta_conn_mutex);
- DBUG_RETURN(0);
-
-error:
- DBUG_ASSERT(conn->mta_conn_mutex_lock_already);
- DBUG_ASSERT(conn->mta_conn_mutex_unlock_later);
- conn->mta_conn_mutex_lock_already = FALSE;
- conn->mta_conn_mutex_unlock_later = FALSE;
- SPIDER_CLEAR_FILE_POS(&conn->mta_conn_mutex_file_pos);
- pthread_mutex_unlock(&conn->mta_conn_mutex);
- DBUG_RETURN(error_num);
-}
-
bool spider_db_conn_is_network_error(
int error_num
) {
diff --git a/storage/spider/spd_db_conn.h b/storage/spider/spd_db_conn.h
index 29813773d34..7da80877ce4 100644
--- a/storage/spider/spd_db_conn.h
+++ b/storage/spider/spd_db_conn.h
@@ -274,8 +274,6 @@
#define SPIDER_SQL_INDEX_FORCE_LEN (sizeof(SPIDER_SQL_INDEX_FORCE_STR) - 1)
#define SPIDER_SQL_INT_LEN 20
-#define SPIDER_SQL_HANDLER_CID_LEN 6
-#define SPIDER_SQL_HANDLER_CID_FORMAT "t%05u"
#define SPIDER_UDF_PING_TABLE_PING_ONLY (1 << 0)
#define SPIDER_UDF_PING_TABLE_USE_WHERE (1 << 1)
#define SPIDER_UDF_PING_TABLE_USE_ALL_MONITORING_NODES (1 << 2)
@@ -547,10 +545,6 @@ void spider_db_free_show_index(
SPIDER_SHARE *share
);
-void spider_db_append_handler_next(
- ha_spider *spider
-);
-
void spider_db_get_row_from_tmp_tbl_rec(
SPIDER_RESULT *current,
SPIDER_DB_ROW **row
@@ -1147,20 +1141,6 @@ int spider_db_udf_copy_tables(
longlong bulk_insert_rows
);
-int spider_db_open_handler(
- ha_spider *spider,
- SPIDER_CONN *conn,
- int link_idx
-);
-
-
-int spider_db_close_handler(
- ha_spider *spider,
- SPIDER_CONN *conn,
- int link_idx,
- uint tgt_conn_kind
-);
-
bool spider_db_conn_is_network_error(
int error_num
);
diff --git a/storage/spider/spd_db_include.h b/storage/spider/spd_db_include.h
index 40f5a6c572d..1e01545e2c4 100644
--- a/storage/spider/spd_db_include.h
+++ b/storage/spider/spd_db_include.h
@@ -33,12 +33,8 @@
#define SPIDER_HAS_APPEND_FOR_SINGLE_QUOTE
#define SPIDER_HAS_SHOW_SIMPLE_FUNC
#define SPIDER_HAS_JT_HASH_INDEX_MERGE
-#define SPIDER_HAS_EXPR_CACHE_ITEM
-#define SPIDER_ITEM_HAS_CMP_TYPE
#define SPIDER_HAS_TIME_STATUS
#define SPIDER_HAS_DECIMAL_OPERATION_RESULTS_VALUE_TYPE
-#define SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY
-#define SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
#define SPIDER_ORDER_HAS_ENUM_ORDER
#define SPIDER_ITEM_GEOFUNC_NAME_HAS_MBR
#define SPIDER_HANDLER_AUTO_REPAIR_HAS_ERROR
@@ -170,9 +166,6 @@ typedef st_spider_result SPIDER_RESULT;
#define SPIDER_CONN_KIND_MYSQL (1 << 0)
-#define SPIDER_SQL_KIND_SQL (1 << 0)
-#define SPIDER_SQL_KIND_HANDLER (1 << 1)
-
#define SPIDER_SQL_TYPE_SELECT_SQL (1 << 0)
#define SPIDER_SQL_TYPE_INSERT_SQL (1 << 1)
#define SPIDER_SQL_TYPE_UPDATE_SQL (1 << 2)
@@ -181,7 +174,6 @@ typedef st_spider_result SPIDER_RESULT;
#define SPIDER_SQL_TYPE_TMP_SQL (1 << 5)
#define SPIDER_SQL_TYPE_DROP_TMP_TABLE_SQL (1 << 6)
#define SPIDER_SQL_TYPE_OTHER_SQL (1 << 7)
-#define SPIDER_SQL_TYPE_HANDLER (1 << 8)
#define SPIDER_SQL_TYPE_SELECT_HS (1 << 9)
#define SPIDER_SQL_TYPE_INSERT_HS (1 << 10)
#define SPIDER_SQL_TYPE_UPDATE_HS (1 << 11)
@@ -1099,8 +1091,6 @@ public:
) = 0;
virtual uint get_lock_table_hash_count() = 0;
virtual void reset_lock_table_hash() = 0;
- virtual uint get_opened_handler_count() = 0;
- virtual void reset_opened_handler() = 0;
virtual void set_dup_key_idx(
ha_spider *spider,
int link_idx
@@ -1366,16 +1356,6 @@ public:
ulong sql_type,
uint multi_range_cnt
) = 0;
- virtual int append_open_handler_part(
- ulong sql_type,
- uint handler_id,
- SPIDER_CONN *conn,
- int link_idx
- ) = 0;
- virtual int append_close_handler_part(
- ulong sql_type,
- int link_idx
- ) = 0;
virtual int append_insert_terminator_part(
ulong sql_type
) = 0;
@@ -1538,20 +1518,9 @@ public:
SPIDER_CONN *conn,
int link_idx
) = 0;
- virtual int insert_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
- ) = 0;
- virtual int delete_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
- ) = 0;
virtual int sync_from_clone_source(
spider_db_handler *dbton_hdl
) = 0;
- virtual bool support_use_handler(
- int use_handler
- ) = 0;
virtual bool minimum_select_bit_is_set(
uint field_index
) = 0;
@@ -1740,7 +1709,6 @@ typedef struct st_spider_position
bool use_position;
bool mrr_with_cnt;
bool direct_aggregate;
- uint sql_kind;
uchar *position_bitmap;
st_spider_ft_info *ft_first;
st_spider_ft_info *ft_current;
@@ -1789,9 +1757,6 @@ typedef struct st_spider_result_list
int key_order;
spider_string *sqls;
int ha_read_kind;
- bool have_sql_kind_backup;
- uint *sql_kind_backup;
- uint sql_kinds_backup;
bool use_union;
bool use_both_key;
const key_range *end_key;
diff --git a/storage/spider/spd_db_mysql.cc b/storage/spider/spd_db_mysql.cc
index fcfb7239b8c..5c67e74fb6e 100644
--- a/storage/spider/spd_db_mysql.cc
+++ b/storage/spider/spd_db_mysql.cc
@@ -1758,7 +1758,7 @@ spider_db_mbase::spider_db_mbase(
SPIDER_CONN *conn,
spider_db_mbase_util *spider_db_mbase_utility
) : spider_db_conn(conn), spider_db_mbase_utility(spider_db_mbase_utility),
- lock_table_hash_inited(FALSE), handler_open_array_inited(FALSE)
+ lock_table_hash_inited(FALSE)
{
DBUG_ENTER("spider_db_mbase::spider_db_mbase");
DBUG_PRINT("info",("spider this=%p", this));
@@ -1788,15 +1788,6 @@ spider_db_mbase::~spider_db_mbase()
{
DBUG_ENTER("spider_db_mbase::~spider_db_mbase");
DBUG_PRINT("info",("spider this=%p", this));
- if (handler_open_array_inited)
- {
- reset_opened_handler();
- spider_free_mem_calc(spider_current_trx,
- handler_open_array_id,
- handler_open_array.max_element *
- handler_open_array.size_of_element);
- delete_dynamic(&handler_open_array);
- }
if (lock_table_hash_inited)
{
spider_free_mem_calc(spider_current_trx,
@@ -1839,18 +1830,6 @@ int spider_db_mbase::init()
lock_table_hash.array.size_of_element);
lock_table_hash_inited = TRUE;
- if (
- SPD_INIT_DYNAMIC_ARRAY2(&handler_open_array,
- sizeof(SPIDER_LINK_FOR_HASH *), NULL, 16, 16, MYF(MY_WME))
- ) {
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- spider_alloc_calc_mem_init(handler_open_array, 162);
- spider_alloc_calc_mem(spider_current_trx,
- handler_open_array,
- handler_open_array.max_element *
- handler_open_array.size_of_element);
- handler_open_array_inited = TRUE;
DBUG_RETURN(0);
}
@@ -3780,30 +3759,6 @@ void spider_db_mbase::reset_lock_table_hash()
DBUG_VOID_RETURN;
}
-uint spider_db_mbase::get_opened_handler_count()
-{
- DBUG_ENTER("spider_db_mbase::get_opened_handler_count");
- DBUG_PRINT("info",("spider this=%p", this));
- DBUG_RETURN(handler_open_array.elements);
-}
-
-void spider_db_mbase::reset_opened_handler()
-{
- ha_spider *tmp_spider;
- int tmp_link_idx;
- SPIDER_LINK_FOR_HASH **tmp_link_for_hash;
- DBUG_ENTER("spider_db_mbase::reset_opened_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- while ((tmp_link_for_hash =
- (SPIDER_LINK_FOR_HASH **) pop_dynamic(&handler_open_array)))
- {
- tmp_spider = (*tmp_link_for_hash)->spider;
- tmp_link_idx = (*tmp_link_for_hash)->link_idx;
- tmp_spider->clear_handler_opened(tmp_link_idx, conn->conn_kind);
- }
- DBUG_VOID_RETURN;
-}
-
void spider_db_mbase::set_dup_key_idx(
ha_spider *spider,
int link_idx
@@ -3825,13 +3780,8 @@ void spider_db_mbase::set_dup_key_idx(
key_name = spider->share->tgt_pk_names[all_link_idx];
key_name_length = spider->share->tgt_pk_names_lengths[all_link_idx];
} else {
-#ifdef SPIDER_use_LEX_CSTRING_for_KEY_Field_name
key_name = table->key_info[roop_count].name.str;
key_name_length = table->key_info[roop_count].name.length;
-#else
- key_name = table->key_info[roop_count].name;
- key_name_length = strlen(key_name);
-#endif
}
DBUG_PRINT("info",("spider key_name=%s", key_name));
if (
@@ -6392,15 +6342,12 @@ int spider_db_mbase_util::open_item_func(
bool has_other_item = FALSE;
while((item = lif++))
{
-#ifdef SPIDER_HAS_EXPR_CACHE_ITEM
if (
item->type() == Item::EXPR_CACHE_ITEM
) {
DBUG_PRINT("info",("spider EXPR_CACHE_ITEM"));
has_expr_cache_item = TRUE;
- } else
-#endif
- if (
+ } else if (
item->type() == Item::FUNC_ITEM &&
((Item_func *) item)->functype() == Item_func::ISNOTNULL_FUNC
) {
@@ -6604,7 +6551,6 @@ int spider_db_mbase_util::open_item_func(
}
break;
case Item_func::LIKE_FUNC:
-#ifdef SPIDER_LIKE_FUNC_HAS_GET_NEGATED
if (str)
{
if (((Item_func_like *)item_func)->get_negated())
@@ -6620,9 +6566,6 @@ int spider_db_mbase_util::open_item_func(
}
}
break;
-#else
- DBUG_RETURN(ER_SPIDER_COND_SKIP_NUM);
-#endif
case Item_func::CASE_SEARCHED_FUNC:
case Item_func::CASE_SIMPLE_FUNC:
#ifdef ITEM_FUNC_CASE_PARAMS_ARE_PUBLIC
@@ -8842,8 +8785,6 @@ int spider_mbase_handler::append_index_hint(
while(index_hints && (hint = iter++))
{
-// hint->print(thd, str);
- if (sql_type != SPIDER_SQL_TYPE_HANDLER)
{
switch(hint->type)
{
@@ -8888,13 +8829,8 @@ int spider_mbase_handler::append_table_name_with_adjusting(
int error_num = 0;
DBUG_ENTER("spider_mbase_handler::append_table_name_with_adjusting");
DBUG_PRINT("info",("spider this=%p", this));
- if (sql_type == SPIDER_SQL_TYPE_HANDLER)
- {
- str->q_append(spider->m_handler_cid[link_idx], SPIDER_SQL_HANDLER_CID_LEN);
- } else {
error_num = mysql_share->append_table_name_with_adjusting(str,
spider->conn_link_idx[link_idx]);
- }
DBUG_RETURN(error_num);
}
@@ -9817,10 +9753,8 @@ int spider_mbase_handler::append_direct_update_set(
spider_string *str
) {
DBUG_ENTER("spider_mbase_handler::append_direct_update_set");
- if (
- spider->direct_update_kinds == SPIDER_SQL_KIND_SQL &&
- spider->wide_handler->direct_update_fields
- ) {
+ if (spider->wide_handler->direct_update_fields)
+ {
if (str->reserve(SPIDER_SQL_SET_LEN))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
str->q_append(SPIDER_SQL_SET_STR, SPIDER_SQL_SET_LEN);
@@ -9828,11 +9762,6 @@ int spider_mbase_handler::append_direct_update_set(
dbton_id, FALSE, NULL));
}
- if (
- (spider->direct_update_kinds & SPIDER_SQL_KIND_SQL)
- ) {
- DBUG_ASSERT(0);
- }
DBUG_RETURN(0);
}
@@ -9892,9 +9821,6 @@ int spider_mbase_handler::append_select_part(
case SPIDER_SQL_TYPE_SELECT_SQL:
str = &sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
default:
DBUG_RETURN(0);
}
@@ -9909,12 +9835,7 @@ int spider_mbase_handler::append_select(
SPIDER_RESULT_LIST *result_list = &spider->result_list;
SPIDER_WIDE_HANDLER *wide_handler = spider->wide_handler;
DBUG_ENTER("spider_mbase_handler::append_select");
- if (sql_type == SPIDER_SQL_TYPE_HANDLER)
{
- if (str->reserve(SPIDER_SQL_HANDLER_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_HANDLER_STR, SPIDER_SQL_HANDLER_LEN);
- } else {
if (str->reserve(SPIDER_SQL_SELECT_LEN))
DBUG_RETURN(HA_ERR_OUT_OF_MEM);
str->q_append(SPIDER_SQL_SELECT_STR, SPIDER_SQL_SELECT_LEN);
@@ -10412,9 +10333,6 @@ int spider_mbase_handler::append_hint_after_table_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
default:
DBUG_RETURN(0);
}
@@ -10453,9 +10371,6 @@ void spider_mbase_handler::set_where_pos(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
where_pos = update_sql.length();
break;
- case SPIDER_SQL_TYPE_HANDLER:
- ha_read_pos = ha_sql.length();
- break;
default:
break;
}
@@ -10478,9 +10393,6 @@ void spider_mbase_handler::set_where_to_pos(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
update_sql.length(where_pos);
break;
- case SPIDER_SQL_TYPE_HANDLER:
- ha_sql.length(ha_read_pos);
- break;
default:
break;
}
@@ -10826,15 +10738,6 @@ int spider_mbase_handler::append_key_where_part(
str = &update_sql;
set_order = FALSE;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- ha_read_pos = str->length();
- str_part = &sql_part;
- str_part2 = &sql_part2;
- str_part->length(0);
- str_part2->length(0);
- set_order = TRUE;
- break;
default:
DBUG_RETURN(0);
}
@@ -10884,11 +10787,6 @@ int spider_mbase_handler::append_is_null_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- str_part = &sql_part;
- str_part2 = &sql_part2;
- break;
default:
DBUG_RETURN(0);
}
@@ -10915,38 +10813,6 @@ int spider_mbase_handler::append_is_null(
{
if (*(*ptr)++)
{
- if (sql_type == SPIDER_SQL_TYPE_HANDLER)
- {
- if (
- key_eq ||
- key->flag == HA_READ_KEY_EXACT ||
- key->flag == HA_READ_KEY_OR_NEXT
- ) {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- if (str->reserve(SPIDER_SQL_EQUAL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_EQUAL_STR, SPIDER_SQL_EQUAL_LEN);
- str = str_part;
- if (str->reserve(SPIDER_SQL_NULL_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_NULL_STR, SPIDER_SQL_NULL_LEN);
- }
- } else {
- if (str_part->length() == SPIDER_SQL_OPEN_PAREN_LEN)
- {
- str = str_part;
- /* first index column */
- str->length(str->length() - SPIDER_SQL_OPEN_PAREN_LEN);
- ha_next_pos = str->length();
- if (str->reserve(SPIDER_SQL_FIRST_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_FIRST_STR, SPIDER_SQL_FIRST_LEN);
- spider->result_list.ha_read_kind = 1;
- }
- }
- str = str_part2;
- }
if (
key_eq ||
key->flag == HA_READ_KEY_EXACT ||
@@ -10993,11 +10859,6 @@ int spider_mbase_handler::append_where_terminator_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- str_part = &sql_part;
- str_part2 = &sql_part2;
- break;
default:
DBUG_RETURN(0);
}
@@ -11016,31 +10877,11 @@ int spider_mbase_handler::append_where_terminator(
) {
SPIDER_RESULT_LIST *result_list = &spider->result_list;
DBUG_ENTER("spider_mbase_handler::append_where_terminator");
- DBUG_PRINT("info",("spider this=%p", this));
- if (sql_type != SPIDER_SQL_TYPE_HANDLER)
- {
- str->length(str->length() - SPIDER_SQL_AND_LEN);
- if (!set_order)
- result_list->key_order = key_count;
- } else {
- str_part2->length(str_part2->length() - SPIDER_SQL_AND_LEN);
+ DBUG_PRINT("info", ("spider this=%p", this));
- if (!result_list->ha_read_kind)
- str_part->q_append(SPIDER_SQL_CLOSE_PAREN_STR,
- SPIDER_SQL_CLOSE_PAREN_LEN);
- if (str->append(*str_part))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- uint clause_length = str->length() - ha_next_pos;
- if (clause_length < SPIDER_SQL_NEXT_LEN)
- {
- int roop_count;
- clause_length = SPIDER_SQL_NEXT_LEN - clause_length;
- if (str->reserve(clause_length))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- for (roop_count = 0; roop_count < (int) clause_length; roop_count++)
- str->q_append(SPIDER_SQL_SPACE_STR, SPIDER_SQL_SPACE_LEN);
- }
- }
+ str->length(str->length() - SPIDER_SQL_AND_LEN);
+ if (!set_order)
+ result_list->key_order= key_count;
DBUG_RETURN(0);
}
@@ -11253,39 +11094,6 @@ int spider_mbase_handler::append_condition_part(
start_where = ((int) str->length() == where_pos);
}
break;
- case SPIDER_SQL_TYPE_HANDLER:
- if (test_flg)
- {
- str = NULL;
- } else {
- str = &ha_sql;
- start_where = TRUE;
- if (spider->active_index == MAX_KEY)
- {
- set_where_pos(SPIDER_SQL_TYPE_HANDLER);
- if (str->reserve(SPIDER_SQL_READ_LEN + SPIDER_SQL_FIRST_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_READ_STR, SPIDER_SQL_READ_LEN);
- ha_next_pos = str->length();
- str->q_append(SPIDER_SQL_FIRST_STR, SPIDER_SQL_FIRST_LEN);
- sql_part2.length(0);
- }
- ha_where_pos = str->length();
-
- if (
- spider->wide_handler->sql_command == SQLCOM_HA_READ ||
- !spider->result_list.use_both_key
- ) {
- if (sql_part2.length())
- {
- str->append(sql_part2);
- start_where = FALSE;
- }
- } else {
- DBUG_RETURN(0);
- }
- }
- break;
default:
DBUG_RETURN(0);
}
@@ -11569,9 +11377,6 @@ void spider_mbase_handler::set_order_pos(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
order_pos = update_sql.length();
break;
- case SPIDER_SQL_TYPE_HANDLER:
- ha_next_pos = ha_sql.length();
- break;
default:
DBUG_ASSERT(0);
break;
@@ -11595,9 +11400,6 @@ void spider_mbase_handler::set_order_to_pos(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
update_sql.length(order_pos);
break;
- case SPIDER_SQL_TYPE_HANDLER:
- ha_sql.length(ha_next_pos);
- break;
default:
DBUG_ASSERT(0);
break;
@@ -11626,9 +11428,6 @@ int spider_mbase_handler::append_group_by_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
default:
DBUG_RETURN(0);
}
@@ -11689,10 +11488,6 @@ int spider_mbase_handler::append_key_order_for_merge_with_alias_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- ha_limit_pos = ha_sql.length();
- break;
default:
DBUG_RETURN(0);
}
@@ -11803,9 +11598,6 @@ int spider_mbase_handler::append_key_order_for_direct_order_limit_with_alias_par
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
default:
DBUG_RETURN(0);
}
@@ -11887,10 +11679,6 @@ int spider_mbase_handler::append_key_order_with_alias_part(
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
str = &update_sql;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- error_num = append_key_order_for_handler(str, alias, alias_length);
- DBUG_RETURN(error_num);
default:
DBUG_RETURN(0);
}
@@ -12103,10 +11891,6 @@ int spider_mbase_handler::append_limit_part(
str = &update_sql;
limit_pos = str->length();
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- ha_limit_pos = str->length();
- break;
default:
DBUG_RETURN(0);
}
@@ -12140,10 +11924,6 @@ int spider_mbase_handler::reappend_limit_part(
str = &update_sql;
str->length(limit_pos);
break;
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- str->length(ha_limit_pos);
- break;
default:
DBUG_RETURN(0);
}
@@ -12402,97 +12182,6 @@ int spider_mbase_handler::append_multi_range_cnt_with_name(
DBUG_RETURN(0);
}
-int spider_mbase_handler::append_open_handler_part(
- ulong sql_type,
- uint handler_id,
- SPIDER_CONN *conn,
- int link_idx
-) {
- int error_num;
- spider_string *str;
- DBUG_ENTER("spider_mbase_handler::append_open_handler_part");
- DBUG_PRINT("info",("spider this=%p", this));
- switch (sql_type)
- {
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
- default:
- DBUG_RETURN(0);
- }
- error_num = append_open_handler(str, handler_id, conn, link_idx);
- exec_ha_sql = str;
- DBUG_RETURN(error_num);
-}
-
-int spider_mbase_handler::append_open_handler(
- spider_string *str,
- uint handler_id,
- SPIDER_CONN *conn,
- int link_idx
-) {
- int error_num;
- DBUG_ENTER("spider_mbase_handler::append_open_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- DBUG_PRINT("info",("spider link_idx=%d", link_idx));
- DBUG_PRINT("info",("spider m_handler_cid=%s",
- spider->m_handler_cid[link_idx]));
- if (str->reserve(SPIDER_SQL_HANDLER_LEN))
- {
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- str->q_append(SPIDER_SQL_HANDLER_STR, SPIDER_SQL_HANDLER_LEN);
- if ((error_num = mysql_share->append_table_name(str,
- spider->conn_link_idx[link_idx])))
- DBUG_RETURN(error_num);
- if (str->reserve(SPIDER_SQL_OPEN_LEN + SPIDER_SQL_AS_LEN +
- SPIDER_SQL_HANDLER_CID_LEN))
- {
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- str->q_append(SPIDER_SQL_OPEN_STR, SPIDER_SQL_OPEN_LEN);
- str->q_append(SPIDER_SQL_AS_STR, SPIDER_SQL_AS_LEN);
- str->q_append(spider->m_handler_cid[link_idx], SPIDER_SQL_HANDLER_CID_LEN);
- DBUG_RETURN(0);
-}
-
-int spider_mbase_handler::append_close_handler_part(
- ulong sql_type,
- int link_idx
-) {
- int error_num;
- spider_string *str;
- DBUG_ENTER("spider_mbase_handler::append_close_handler_part");
- DBUG_PRINT("info",("spider this=%p", this));
- switch (sql_type)
- {
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
- default:
- DBUG_RETURN(0);
- }
- error_num = append_close_handler(str, link_idx);
- exec_ha_sql = str;
- DBUG_RETURN(error_num);
-}
-
-int spider_mbase_handler::append_close_handler(
- spider_string *str,
- int link_idx
-) {
- DBUG_ENTER("spider_mbase_handler::append_close_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- if (str->reserve(SPIDER_SQL_HANDLER_LEN + SPIDER_SQL_CLOSE_LEN +
- SPIDER_SQL_HANDLER_CID_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_HANDLER_STR, SPIDER_SQL_HANDLER_LEN);
- str->q_append(spider->m_handler_cid[link_idx],
- SPIDER_SQL_HANDLER_CID_LEN);
- str->q_append(SPIDER_SQL_CLOSE_STR, SPIDER_SQL_CLOSE_LEN);
- DBUG_RETURN(0);
-}
-
int spider_mbase_handler::append_insert_terminator_part(
ulong sql_type
) {
@@ -12731,9 +12420,6 @@ int spider_mbase_handler::append_from_part(
DBUG_PRINT("info",("spider this=%p", this));
switch (sql_type)
{
- case SPIDER_SQL_TYPE_HANDLER:
- str = &ha_sql;
- break;
case SPIDER_SQL_TYPE_UPDATE_SQL:
case SPIDER_SQL_TYPE_DELETE_SQL:
case SPIDER_SQL_TYPE_BULK_UPDATE_SQL:
@@ -12755,33 +12441,18 @@ int spider_mbase_handler::append_from(
DBUG_ENTER("spider_mbase_handler::append_from");
DBUG_PRINT("info",("spider this=%p", this));
DBUG_PRINT("info",("spider link_idx=%d", link_idx));
- int error_num = 0;
- if (sql_type == SPIDER_SQL_TYPE_HANDLER)
+ int error_num= 0;
+ if (str->reserve(SPIDER_SQL_FROM_LEN + mysql_share->db_nm_max_length +
+ SPIDER_SQL_DOT_LEN + mysql_share->table_nm_max_length +
+ /* SPIDER_SQL_NAME_QUOTE_LEN */ 4 +
+ SPIDER_SQL_OPEN_PAREN_LEN))
+ DBUG_RETURN(HA_ERR_OUT_OF_MEM);
+ str->q_append(SPIDER_SQL_FROM_STR, SPIDER_SQL_FROM_LEN);
+ table_name_pos= str->length();
+ append_table_name_with_adjusting(str, link_idx, sql_type);
+ if (spider_param_index_hint_pushdown(spider->wide_handler->trx->thd))
{
- ha_table_name_pos = str->length();
- DBUG_PRINT("info",("spider ha_table_name_pos=%u", ha_table_name_pos));
- ha_sql_handler_id = spider->m_handler_id[link_idx];
- DBUG_PRINT("info",("spider ha_sql_handler_id=%u", ha_sql_handler_id));
- if (str->reserve(SPIDER_SQL_HANDLER_CID_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(spider->m_handler_cid[link_idx], SPIDER_SQL_HANDLER_CID_LEN);
- DBUG_PRINT("info",("spider m_handler_cid=%s",
- spider->m_handler_cid[link_idx]));
- } else {
- if (str->reserve(SPIDER_SQL_FROM_LEN + mysql_share->db_nm_max_length +
- SPIDER_SQL_DOT_LEN + mysql_share->table_nm_max_length +
- /* SPIDER_SQL_NAME_QUOTE_LEN */ 4 + SPIDER_SQL_OPEN_PAREN_LEN))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- str->q_append(SPIDER_SQL_FROM_STR, SPIDER_SQL_FROM_LEN);
- table_name_pos = str->length();
- append_table_name_with_adjusting(str, link_idx, sql_type);
- if(spider_param_index_hint_pushdown(spider->wide_handler->trx->thd))
- {
- if((error_num = append_index_hint(str, link_idx, sql_type)))
- {
- DBUG_RETURN(error_num);
- }
- }
+ DBUG_RETURN(error_num);
}
DBUG_RETURN(0);
}
@@ -13347,9 +13018,6 @@ bool spider_mbase_handler::sql_is_empty(
case SPIDER_SQL_TYPE_TMP_SQL:
is_empty = (tmp_sql.length() == 0);
break;
- case SPIDER_SQL_TYPE_HANDLER:
- is_empty = (ha_sql.length() == 0);
- break;
default:
is_empty = TRUE;
break;
@@ -13679,10 +13347,6 @@ int spider_mbase_handler::reset_sql(
{
tmp_sql.length(0);
}
- if (sql_type & SPIDER_SQL_TYPE_HANDLER)
- {
- ha_sql.length(0);
- }
DBUG_RETURN(0);
}
@@ -13874,23 +13538,6 @@ int spider_mbase_handler::set_sql_for_exec(
exec_update_sql->length(tmp_pos);
}
}
- if (sql_type & SPIDER_SQL_TYPE_HANDLER)
- {
- if (spider->m_handler_id[link_idx] == ha_sql_handler_id)
- exec_ha_sql = &ha_sql;
- else {
- exec_ha_sql = &result_list->sqls[link_idx];
- if (exec_ha_sql->copy(ha_sql))
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- else {
- tmp_pos = exec_ha_sql->length();
- exec_ha_sql->length(ha_table_name_pos);
- append_table_name_with_adjusting(exec_ha_sql, link_idx,
- SPIDER_SQL_TYPE_HANDLER);
- exec_ha_sql->length(tmp_pos);
- }
- }
- }
DBUG_RETURN(0);
}
@@ -13956,11 +13603,6 @@ int spider_mbase_handler::execute_sql(
tgt_sql = exec_tmp_sql;
tgt_length = tmp_sql_pos5;
break;
- case SPIDER_SQL_TYPE_HANDLER:
- DBUG_PRINT("info",("spider SPIDER_SQL_TYPE_HANDLER"));
- tgt_sql = exec_ha_sql;
- tgt_length = tgt_sql->length();
- break;
default:
/* nothing to do */
DBUG_PRINT("info",("spider default"));
@@ -15599,55 +15241,6 @@ int spider_mbase_handler::flush_logs(
DBUG_RETURN(0);
}
-int spider_mbase_handler::insert_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
-) {
- spider_db_mbase *db_conn = (spider_db_mbase *) conn->db_conn;
- SPIDER_LINK_FOR_HASH *tmp_link_for_hash = &link_for_hash[link_idx];
- DBUG_ASSERT(tmp_link_for_hash->spider == spider);
- DBUG_ASSERT(tmp_link_for_hash->link_idx == link_idx);
- uint old_elements = db_conn->handler_open_array.max_element;
- DBUG_ENTER("spider_mbase_handler::insert_opened_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- if (insert_dynamic(&db_conn->handler_open_array,
- (uchar*) &tmp_link_for_hash))
- {
- DBUG_RETURN(HA_ERR_OUT_OF_MEM);
- }
- if (db_conn->handler_open_array.max_element > old_elements)
- {
- spider_alloc_calc_mem(spider_current_trx,
- db_conn->handler_open_array,
- (db_conn->handler_open_array.max_element - old_elements) *
- db_conn->handler_open_array.size_of_element);
- }
- DBUG_RETURN(0);
-}
-
-int spider_mbase_handler::delete_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
-) {
- spider_db_mbase *db_conn = (spider_db_mbase *) conn->db_conn;
- uint roop_count, elements = db_conn->handler_open_array.elements;
- SPIDER_LINK_FOR_HASH *tmp_link_for_hash;
- DBUG_ENTER("spider_mbase_handler::delete_opened_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- for (roop_count = 0; roop_count < elements; roop_count++)
- {
- get_dynamic(&db_conn->handler_open_array, (uchar *) &tmp_link_for_hash,
- roop_count);
- if (tmp_link_for_hash == &link_for_hash[link_idx])
- {
- delete_dynamic_element(&db_conn->handler_open_array, roop_count);
- break;
- }
- }
- DBUG_ASSERT(roop_count < elements);
- DBUG_RETURN(0);
-}
-
int spider_mbase_handler::sync_from_clone_source(
spider_db_handler *dbton_hdl
) {
@@ -15656,14 +15249,6 @@ int spider_mbase_handler::sync_from_clone_source(
DBUG_RETURN(0);
}
-bool spider_mbase_handler::support_use_handler(
- int use_handler
-) {
- DBUG_ENTER("spider_mbase_handler::support_use_handler");
- DBUG_PRINT("info",("spider this=%p", this));
- DBUG_RETURN(TRUE);
-}
-
void spider_mbase_handler::minimum_select_bitmap_create()
{
TABLE *table = spider->get_table();
diff --git a/storage/spider/spd_db_mysql.h b/storage/spider/spd_db_mysql.h
index 534216ca485..3066832853c 100644
--- a/storage/spider/spd_db_mysql.h
+++ b/storage/spider/spd_db_mysql.h
@@ -398,12 +398,6 @@ public:
const char *lock_table_hash_func_name;
const char *lock_table_hash_file_name;
ulong lock_table_hash_line_no;
- DYNAMIC_ARRAY handler_open_array;
- bool handler_open_array_inited;
- uint handler_open_array_id;
- const char *handler_open_array_func_name;
- const char *handler_open_array_file_name;
- ulong handler_open_array_line_no;
spider_db_mbase(
SPIDER_CONN *conn,
spider_db_mbase_util *spider_db_mbase_utility
@@ -585,8 +579,6 @@ public:
);
uint get_lock_table_hash_count();
void reset_lock_table_hash();
- uint get_opened_handler_count();
- void reset_opened_handler();
void set_dup_key_idx(
ha_spider *spider,
int link_idx
@@ -1194,26 +1186,6 @@ public:
spider_string *str,
uint multi_range_cnt
);
- int append_open_handler_part(
- ulong sql_type,
- uint handler_id,
- SPIDER_CONN *conn,
- int link_idx
- );
- int append_open_handler(
- spider_string *str,
- uint handler_id,
- SPIDER_CONN *conn,
- int link_idx
- );
- int append_close_handler_part(
- ulong sql_type,
- int link_idx
- );
- int append_close_handler(
- spider_string *str,
- int link_idx
- );
int append_insert_terminator_part(
ulong sql_type
);
@@ -1480,20 +1452,9 @@ public:
SPIDER_CONN *conn,
int link_idx
);
- int insert_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
- );
- int delete_opened_handler(
- SPIDER_CONN *conn,
- int link_idx
- );
int sync_from_clone_source(
spider_db_handler *dbton_hdl
);
- bool support_use_handler(
- int use_handler
- );
void minimum_select_bitmap_create();
bool minimum_select_bit_is_set(
uint field_index
diff --git a/storage/spider/spd_direct_sql.cc b/storage/spider/spd_direct_sql.cc
index 6a7d5109081..333532bb107 100644
--- a/storage/spider/spd_direct_sql.cc
+++ b/storage/spider/spd_direct_sql.cc
@@ -1594,10 +1594,9 @@ long long spider_direct_sql_body(
}
trx->updated_in_this_trx = TRUE;
DBUG_PRINT("info",("spider trx->updated_in_this_trx=TRUE"));
- use_real_table = spider_param_udf_ds_use_real_table(thd,
- direct_sql->use_real_table);
- for (roop_count = 0; roop_count < direct_sql->table_count; roop_count++)
- {
+ use_real_table= direct_sql->use_real_table;
+ for (roop_count= 0; roop_count < direct_sql->table_count; roop_count++)
+ {
#ifdef SPIDER_NEED_INIT_ONE_TABLE_FOR_FIND_TEMPORARY_TABLE
#ifdef SPIDER_use_LEX_CSTRING_for_database_tablename_alias
LEX_CSTRING db_name =
diff --git a/storage/spider/spd_environ.h b/storage/spider/spd_environ.h
index 0caf23af64c..ccdc7009f9a 100644
--- a/storage/spider/spd_environ.h
+++ b/storage/spider/spd_environ.h
@@ -26,7 +26,4 @@
#define HA_EXTRA_HAS_STARTING_ORDERED_INDEX_SCAN
#define HANDLER_HAS_CAN_USE_FOR_AUTO_INC_INIT
#define SPIDER_UPDATE_ROW_HAS_CONST_NEW_DATA
-#define SPIDER_MDEV_16246
-#define SPIDER_LIKE_FUNC_HAS_GET_NEGATED
-#define SPIDER_I_S_USE_SHOW_FOR_COLUMN
#endif /* SPD_ENVIRON_INCLUDED */
diff --git a/storage/spider/spd_group_by_handler.cc b/storage/spider/spd_group_by_handler.cc
index 63ab234e878..8cc8cef23ab 100644
--- a/storage/spider/spd_group_by_handler.cc
+++ b/storage/spider/spd_group_by_handler.cc
@@ -1237,10 +1237,6 @@ int spider_group_by_handler::init_scan()
spider_db_free_one_result_for_start_next(spider);
- spider->sql_kinds = SPIDER_SQL_KIND_SQL;
- for (link_idx = 0; link_idx < (int) share->link_count; ++link_idx)
- spider->sql_kind[link_idx] = SPIDER_SQL_KIND_SQL;
-
spider->do_direct_update = FALSE;
spider->direct_update_kinds = 0;
spider_get_select_limit(spider, &select_lex, &select_limit, &offset_limit);
@@ -1912,16 +1908,6 @@ group_by_handler *spider_create_group_by_handler(
spider->conn_link_idx, roop_count, share->link_count,
tgt_link_status)
) {
- if (spider_param_use_handler(thd, share->use_handlers[roop_count]))
- {
- DBUG_PRINT("info",("spider direct_join does not support use_handler"));
- if (lock_mode)
- {
- delete fields;
- DBUG_RETURN(NULL);
- }
- continue;
- }
conn = spider->conns[roop_count];
DBUG_PRINT("info",("spider roop_count=%d", roop_count));
DBUG_PRINT("info",("spider conn=%p", conn));
@@ -1997,16 +1983,6 @@ group_by_handler *spider_create_group_by_handler(
tgt_link_status)
) {
DBUG_PRINT("info",("spider roop_count=%d", roop_count));
- if (spider_param_use_handler(thd, share->use_handlers[roop_count]))
- {
- DBUG_PRINT("info",("spider direct_join does not support use_handler"));
- if (lock_mode)
- {
- delete fields;
- DBUG_RETURN(NULL);
- }
- continue;
- }
conn = spider->conns[roop_count];
DBUG_PRINT("info",("spider conn=%p", conn));
if (!fields->check_conn_same_conn(conn))
diff --git a/storage/spider/spd_i_s.cc b/storage/spider/spd_i_s.cc
index 22cd8eb0f15..7db9537136a 100644
--- a/storage/spider/spd_i_s.cc
+++ b/storage/spider/spd_i_s.cc
@@ -41,7 +41,6 @@ static struct st_mysql_storage_engine spider_i_s_info =
{ MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION };
namespace Show {
-#ifdef SPIDER_I_S_USE_SHOW_FOR_COLUMN
static ST_FIELD_INFO spider_i_s_alloc_mem_fields_info[] =
{
Column("ID", ULong(10), NOT_NULL, "id"),
@@ -54,27 +53,6 @@ static ST_FIELD_INFO spider_i_s_alloc_mem_fields_info[] =
Column("FREE_MEM_COUNT", ULonglong(20), NULLABLE, "free_mem_count"),
CEnd()
};
-#else
-static ST_FIELD_INFO spider_i_s_alloc_mem_fields_info[] =
-{
- {"ID", 10, MYSQL_TYPE_LONG, 0, MY_I_S_UNSIGNED, "id", SKIP_OPEN_TABLE},
- {"FUNC_NAME", 64, MYSQL_TYPE_STRING, 0,
- MY_I_S_MAYBE_NULL, "func_name", SKIP_OPEN_TABLE},
- {"FILE_NAME", 64, MYSQL_TYPE_STRING, 0,
- MY_I_S_MAYBE_NULL, "file_name", SKIP_OPEN_TABLE},
- {"LINE_NO", 10, MYSQL_TYPE_LONG, 0,
- MY_I_S_UNSIGNED | MY_I_S_MAYBE_NULL, "line_no", SKIP_OPEN_TABLE},
- {"TOTAL_ALLOC_MEM", 20, MYSQL_TYPE_LONGLONG, 0,
- MY_I_S_UNSIGNED | MY_I_S_MAYBE_NULL, "total_alloc_mem", SKIP_OPEN_TABLE},
- {"CURRENT_ALLOC_MEM", 20, MYSQL_TYPE_LONGLONG, 0,
- MY_I_S_MAYBE_NULL, "current_alloc_mem", SKIP_OPEN_TABLE},
- {"ALLOC_MEM_COUNT", 20, MYSQL_TYPE_LONGLONG, 0,
- MY_I_S_UNSIGNED | MY_I_S_MAYBE_NULL, "alloc_mem_count", SKIP_OPEN_TABLE},
- {"FREE_MEM_COUNT", 20, MYSQL_TYPE_LONGLONG, 0,
- MY_I_S_UNSIGNED | MY_I_S_MAYBE_NULL, "free_mem_count", SKIP_OPEN_TABLE},
- {NULL, 0, MYSQL_TYPE_STRING, 0, 0, NULL, 0}
-};
-#endif
} // namespace Show
static int spider_i_s_alloc_mem_fill_table(
@@ -180,7 +158,6 @@ struct st_maria_plugin spider_i_s_alloc_mem_maria =
extern SPIDER_DBTON spider_dbton[SPIDER_DBTON_SIZE];
namespace Show {
-#ifdef SPIDER_I_S_USE_SHOW_FOR_COLUMN
static ST_FIELD_INFO spider_i_s_wrapper_protocols_fields_info[] =
{
Column("WRAPPER_NAME", Varchar(NAME_CHAR_LEN), NOT_NULL, ""),
@@ -189,16 +166,6 @@ static ST_FIELD_INFO spider_i_s_wrapper_protocols_fields_info[] =
Column("WRAPPER_MATURITY", Varchar(12), NOT_NULL, ""),
CEnd()
};
-#else
-static ST_FIELD_INFO spider_i_s_wrapper_protocols_fields_info[] =
-{
- {"WRAPPER_NAME", NAME_CHAR_LEN, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE},
- {"WRAPPER_VERSION", 20, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE},
- {"WRAPPER_DESCRIPTION", 65535, MYSQL_TYPE_STRING, 0, 1, 0, SKIP_OPEN_TABLE},
- {"WRAPPER_MATURITY", 12, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE},
- {0, 0, MYSQL_TYPE_STRING, 0, 0, 0, 0}
-};
-#endif
} // namespace Show
static int spider_i_s_wrapper_protocols_fill_table(
diff --git a/storage/spider/spd_include.h b/storage/spider/spd_include.h
index ce3221d8994..6df79e4e2c8 100644
--- a/storage/spider/spd_include.h
+++ b/storage/spider/spd_include.h
@@ -99,7 +99,6 @@
#define SPIDER_new_THD(A) (new THD(A))
#define SPIDER_order_direction_is_asc(A) (A->direction == ORDER::ORDER_ASC)
-#define SPIDER_HAS_MY_CHARLEN
#define SPIDER_open_temporary_table
#define SPIDER_generate_partition_syntax(A,B,C,D,E,F,G,H) generate_partition_syntax(A,B,C,E,F,G)
@@ -110,7 +109,6 @@
#define SPIDER_read_record_read_record(A) read_record()
#define SPIDER_has_Item_with_subquery
-#define SPIDER_use_LEX_CSTRING_for_KEY_Field_name
#define SPIDER_use_LEX_CSTRING_for_Field_blob_constructor
#define SPIDER_use_LEX_CSTRING_for_database_tablename_alias
#define SPIDER_THD_db_str(A) (A)->db.str
@@ -165,7 +163,7 @@ typedef start_new_trans *SPIDER_Open_tables_backup;
#define SPIDER_TMP_SHARE_CHAR_PTR_COUNT 23
#define SPIDER_TMP_SHARE_UINT_COUNT SPIDER_TMP_SHARE_CHAR_PTR_COUNT
-#define SPIDER_TMP_SHARE_LONG_COUNT 20
+#define SPIDER_TMP_SHARE_LONG_COUNT 19
#define SPIDER_TMP_SHARE_LONGLONG_COUNT 3
#define SPIDER_MEM_CALC_LIST_NUM 314
@@ -902,7 +900,6 @@ typedef struct st_spider_share
longlong *monitoring_bg_interval;
longlong *monitoring_limit;
longlong *monitoring_sid;
- long *use_handlers;
long *connect_timeouts;
long *net_read_timeouts;
long *net_write_timeouts;
@@ -990,7 +987,6 @@ typedef struct st_spider_share
uint monitoring_bg_interval_length;
uint monitoring_limit_length;
uint monitoring_sid_length;
- uint use_handlers_length;
uint connect_timeouts_length;
uint net_read_timeouts_length;
uint net_write_timeouts_length;
@@ -1239,10 +1235,8 @@ typedef struct st_spider_item_hld
{
uint tgt_num;
Item *item;
-#ifdef SPIDER_ITEM_STRING_WITHOUT_SET_STR_WITH_COPY_AND_THDPTR
bool init_mem_root;
MEM_ROOT mem_root;
-#endif
st_spider_item_hld *next;
} SPIDER_ITEM_HLD;
diff --git a/storage/spider/spd_param.cc b/storage/spider/spd_param.cc
index a21ee246409..70e44023a8b 100644
--- a/storage/spider/spd_param.cc
+++ b/storage/spider/spd_param.cc
@@ -1952,103 +1952,6 @@ int spider_param_direct_dup_insert(
direct_dup_insert : THDVAR(thd, direct_dup_insert));
}
-static uint spider_udf_table_lock_mutex_count;
-/*
- 1-: mutex count
- */
-static MYSQL_SYSVAR_UINT(
- udf_table_lock_mutex_count,
- spider_udf_table_lock_mutex_count,
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
- "Mutex count of table lock for Spider UDFs",
- NULL,
- NULL,
- 20,
- 1,
- 4294967295U,
- 0
-);
-
-uint spider_param_udf_table_lock_mutex_count()
-{
- DBUG_ENTER("spider_param_udf_table_lock_mutex_count");
- DBUG_RETURN(spider_udf_table_lock_mutex_count);
-}
-
-static uint spider_udf_table_mon_mutex_count;
-/*
- 1-: mutex count
- */
-static MYSQL_SYSVAR_UINT(
- udf_table_mon_mutex_count,
- spider_udf_table_mon_mutex_count,
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
- "Mutex count of table mon for Spider UDFs",
- NULL,
- NULL,
- 20,
- 1,
- 4294967295U,
- 0
-);
-
-uint spider_param_udf_table_mon_mutex_count()
-{
- DBUG_ENTER("spider_param_udf_table_mon_mutex_count");
- DBUG_RETURN(spider_udf_table_mon_mutex_count);
-}
-
-/*
- 1-:number of rows
- */
-static MYSQL_THDVAR_LONGLONG(
- udf_ds_bulk_insert_rows, /* name */
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED, /* opt */
- "Number of rows for bulk inserting", /* comment */
- NULL, /* check */
- NULL, /* update */
- -1, /* def */
- -1, /* min */
- 9223372036854775807LL, /* max */
- 0 /* blk */
-);
-
-longlong spider_param_udf_ds_bulk_insert_rows(
- THD *thd,
- longlong udf_ds_bulk_insert_rows
-) {
- DBUG_ENTER("spider_param_udf_ds_bulk_insert_rows");
- DBUG_RETURN(THDVAR(thd, udf_ds_bulk_insert_rows) <= 0 ?
- udf_ds_bulk_insert_rows : THDVAR(thd, udf_ds_bulk_insert_rows));
-}
-
-/*
- -1 :use table parameter
- 0 :drop records
- 1 :insert last table
- 2 :insert first table and loop again
- */
-static MYSQL_THDVAR_INT(
- udf_ds_table_loop_mode, /* name */
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED, /* opt */
- "Table loop mode if the number of tables in table list are less than the number of result sets", /* comment */
- NULL, /* check */
- NULL, /* update */
- -1, /* def */
- -1, /* min */
- 2, /* max */
- 0 /* blk */
-);
-
-int spider_param_udf_ds_table_loop_mode(
- THD *thd,
- int udf_ds_table_loop_mode
-) {
- DBUG_ENTER("spider_param_udf_ds_table_loop_mode");
- DBUG_RETURN(THDVAR(thd, udf_ds_table_loop_mode) == -1 ?
- udf_ds_table_loop_mode : THDVAR(thd, udf_ds_table_loop_mode));
-}
-
static char *spider_remote_access_charset;
/*
*/
@@ -2281,84 +2184,6 @@ int spider_param_bka_mode(
bka_mode : THDVAR(thd, bka_mode));
}
-static int spider_udf_ct_bulk_insert_interval;
-/*
- -1 : The UDF parameter is adopted.
- 0 or more : Milliseconds.
- */
-static MYSQL_SYSVAR_INT(
- udf_ct_bulk_insert_interval,
- spider_udf_ct_bulk_insert_interval,
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED,
- "The interval time between bulk insert and next bulk insert at coping",
- NULL,
- NULL,
- -1,
- -1,
- 2147483647,
- 0
-);
-
-int spider_param_udf_ct_bulk_insert_interval(
- int udf_ct_bulk_insert_interval
-) {
- DBUG_ENTER("spider_param_udf_ct_bulk_insert_interval");
- DBUG_RETURN(spider_udf_ct_bulk_insert_interval < 0 ?
- udf_ct_bulk_insert_interval : spider_udf_ct_bulk_insert_interval);
-}
-
-static longlong spider_udf_ct_bulk_insert_rows;
-/*
- -1,0 : The UDF parameter is adopted.
- 1 or more : Number of rows.
- */
-static MYSQL_SYSVAR_LONGLONG(
- udf_ct_bulk_insert_rows,
- spider_udf_ct_bulk_insert_rows,
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED,
- "The number of rows inserted with bulk insert of one time at coping",
- NULL,
- NULL,
- -1,
- -1,
- 9223372036854775807LL,
- 0
-);
-
-longlong spider_param_udf_ct_bulk_insert_rows(
- longlong udf_ct_bulk_insert_rows
-) {
- DBUG_ENTER("spider_param_udf_ct_bulk_insert_rows");
- DBUG_RETURN(spider_udf_ct_bulk_insert_rows <= 0 ?
- udf_ct_bulk_insert_rows : spider_udf_ct_bulk_insert_rows);
-}
-
-/*
- -1 :use table parameter
- 0 :not use
- 1 :use handler
- */
-static MYSQL_THDVAR_INT(
- use_handler, /* name */
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED, /* opt */
- "Use handler for reading", /* comment */
- NULL, /* check */
- spider_use_table_value_deprecated, /* update */
- 0, /* def */
- -1, /* min */
- 3, /* max */
- 0 /* blk */
-);
-
-int spider_param_use_handler(
- THD *thd,
- int use_handler
-) {
- DBUG_ENTER("spider_param_use_handler");
- DBUG_RETURN(THDVAR(thd, use_handler) == -1 ?
- use_handler : THDVAR(thd, use_handler));
-}
-
/*
-1 :use table parameter
0 :return error if error
@@ -2517,33 +2342,6 @@ int spider_param_read_only_mode(
read_only_mode : THDVAR(thd, read_only_mode));
}
-
-/*
- -1 :use UDF parameter
- 0 :can not use
- 1 :can use
- */
-static MYSQL_THDVAR_INT(
- udf_ds_use_real_table, /* name */
- PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_DEPRECATED, /* opt */
- "Use real table for temporary table list", /* comment */
- NULL, /* check */
- NULL, /* update */
- -1, /* def */
- -1, /* min */
- 1, /* max */
- 0 /* blk */
-);
-
-int spider_param_udf_ds_use_real_table(
- THD *thd,
- int udf_ds_use_real_table
-) {
- DBUG_ENTER("spider_param_udf_ds_use_real_table");
- DBUG_RETURN(THDVAR(thd, udf_ds_use_real_table) == -1 ?
- udf_ds_use_real_table : THDVAR(thd, udf_ds_use_real_table));
-}
-
static my_bool spider_general_log;
static MYSQL_SYSVAR_BOOL(
general_log,
@@ -3171,10 +2969,6 @@ static struct st_mysql_sys_var* spider_system_variables[] = {
MYSQL_SYSVAR(local_lock_table),
MYSQL_SYSVAR(use_pushdown_udf),
MYSQL_SYSVAR(direct_dup_insert),
- MYSQL_SYSVAR(udf_table_lock_mutex_count),
- MYSQL_SYSVAR(udf_table_mon_mutex_count),
- MYSQL_SYSVAR(udf_ds_bulk_insert_rows),
- MYSQL_SYSVAR(udf_ds_table_loop_mode),
MYSQL_SYSVAR(remote_access_charset),
MYSQL_SYSVAR(remote_autocommit),
MYSQL_SYSVAR(remote_time_zone),
@@ -3186,16 +2980,12 @@ static struct st_mysql_sys_var* spider_system_variables[] = {
MYSQL_SYSVAR(connect_mutex),
MYSQL_SYSVAR(bka_engine),
MYSQL_SYSVAR(bka_mode),
- MYSQL_SYSVAR(udf_ct_bulk_insert_interval),
- MYSQL_SYSVAR(udf_ct_bulk_insert_rows),
- MYSQL_SYSVAR(use_handler),
MYSQL_SYSVAR(error_read_mode),
MYSQL_SYSVAR(error_write_mode),
MYSQL_SYSVAR(skip_default_condition),
MYSQL_SYSVAR(skip_parallel_search),
MYSQL_SYSVAR(direct_order_limit),
MYSQL_SYSVAR(read_only_mode),
- MYSQL_SYSVAR(udf_ds_use_real_table),
MYSQL_SYSVAR(general_log),
MYSQL_SYSVAR(index_hint_pushdown),
MYSQL_SYSVAR(max_connections),
diff --git a/storage/spider/spd_param.h b/storage/spider/spd_param.h
index 0c5392e302a..6abdca43492 100644
--- a/storage/spider/spd_param.h
+++ b/storage/spider/spd_param.h
@@ -14,6 +14,9 @@
along with this program); if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA */
+constexpr uint spider_udf_table_lock_mutex_count= 20;
+constexpr uint spider_udf_table_mon_mutex_count= 20;
+
my_bool spider_param_support_xa();
my_bool spider_param_connect_mutex();
uint spider_param_connect_error_interval();
@@ -263,16 +266,6 @@ int spider_param_direct_dup_insert(
THD *thd,
int direct_dup_insert
);
-uint spider_param_udf_table_lock_mutex_count();
-uint spider_param_udf_table_mon_mutex_count();
-longlong spider_param_udf_ds_bulk_insert_rows(
- THD *thd,
- longlong udf_ds_bulk_insert_rows
-);
-int spider_param_udf_ds_table_loop_mode(
- THD *thd,
- int udf_ds_table_loop_mode
-);
char *spider_param_remote_access_charset();
int spider_param_remote_autocommit();
char *spider_param_remote_time_zone();
@@ -293,16 +286,6 @@ int spider_param_bka_mode(
THD *thd,
int bka_mode
);
-int spider_param_udf_ct_bulk_insert_interval(
- int udf_ct_bulk_insert_interval
-);
-longlong spider_param_udf_ct_bulk_insert_rows(
- longlong udf_ct_bulk_insert_rows
-);
-int spider_param_use_handler(
- THD *thd,
- int use_handler
-);
int spider_param_error_read_mode(
THD *thd,
int error_read_mode
@@ -327,10 +310,6 @@ int spider_param_read_only_mode(
THD *thd,
int read_only_mode
);
-int spider_param_udf_ds_use_real_table(
- THD *thd,
- int udf_ds_use_real_table
-);
my_bool spider_param_general_log();
my_bool spider_param_index_hint_pushdown(
THD *thd
diff --git a/storage/spider/spd_ping_table.cc b/storage/spider/spd_ping_table.cc
index 9814cf30666..ebd5ac866ca 100644
--- a/storage/spider/spd_ping_table.cc
+++ b/storage/spider/spd_ping_table.cc
@@ -97,8 +97,8 @@ SPIDER_TABLE_MON_LIST *spider_get_ping_table_mon_list(
free_root(&mem_root, MYF(0));
}
- mutex_hash = spider_udf_calc_hash(str->c_ptr(),
- spider_param_udf_table_mon_mutex_count());
+ mutex_hash=
+ spider_udf_calc_hash(str->c_ptr(), spider_udf_table_mon_mutex_count);
DBUG_PRINT("info",("spider hash key=%s", str->c_ptr()));
DBUG_PRINT("info",("spider hash key length=%u", str->length()));
hash_value = my_calc_hash(
@@ -224,8 +224,8 @@ int spider_release_ping_table_mon_list(
conv_name_str.q_append(conv_name, conv_name_length);
conv_name_str.q_append(link_idx_str, link_idx_str_length);
- mutex_hash = spider_udf_calc_hash(conv_name_str.c_ptr_safe(),
- spider_param_udf_table_mon_mutex_count());
+ mutex_hash= spider_udf_calc_hash(conv_name_str.c_ptr_safe(),
+ spider_udf_table_mon_mutex_count);
my_hash_value_type hash_value = my_calc_hash(
&spider_udf_table_mon_list_hash[mutex_hash],
(uchar*) conv_name_str.c_ptr(), conv_name_str.length());
diff --git a/storage/spider/spd_table.cc b/storage/spider/spd_table.cc
index f37044caf37..47c4027f08b 100644
--- a/storage/spider/spd_table.cc
+++ b/storage/spider/spd_table.cc
@@ -817,8 +817,6 @@ int spider_free_share_alloc(
spider_free(spider_current_trx, share->monitoring_flag, MYF(0));
if (share->monitoring_kind)
spider_free(spider_current_trx, share->monitoring_kind, MYF(0));
- if (share->use_handlers)
- spider_free(spider_current_trx, share->use_handlers, MYF(0));
if (share->connect_timeouts)
spider_free(spider_current_trx, share->connect_timeouts, MYF(0));
if (share->net_read_timeouts)
@@ -2335,8 +2333,6 @@ int spider_parse_connect_info(
option_struct &&
option_struct->remote_table);
SPIDER_PARAM_INT_WITH_MAX("tcm", table_count_mode, 0, 3);
- SPIDER_PARAM_DEPRECATED_WARNING("uhd");
- SPIDER_PARAM_LONG_LIST_WITH_MAX("uhd", use_handlers, 0, 3);
SPIDER_PARAM_INT_WITH_MAX("upu", use_pushdown_udf, 0, 1);
SPIDER_PARAM_INT_WITH_MAX("utc", use_table_charset, 0, 1);
error_num = connect_string_parse.print_param_error();
@@ -2415,8 +2411,6 @@ int spider_parse_connect_info(
SPIDER_PARAM_INT_WITH_MAX("crd_bg_mode", crd_bg_mode, 0, 2);
SPIDER_PARAM_INT_WITH_MAX("sts_bg_mode", sts_bg_mode, 0, 2);
SPIDER_PARAM_LONG_LIST_WITH_MAX("link_status", link_statuses, 0, 3);
- SPIDER_PARAM_DEPRECATED_WARNING("use_handler");
- SPIDER_PARAM_LONG_LIST_WITH_MAX("use_handler", use_handlers, 0, 3);
SPIDER_PARAM_INT_WITH_MAX("casual_read", casual_read, 0, 63);
SPIDER_PARAM_DEPRECATED_WARNING("buffer_size");
SPIDER_PARAM_INT("buffer_size", buffer_size, 0);
@@ -2660,8 +2654,6 @@ int spider_parse_connect_info(
share->all_link_count = share->monitoring_bg_kind_length;
if (share->all_link_count < share->monitoring_bg_interval_length)
share->all_link_count = share->monitoring_bg_interval_length;
- if (share->all_link_count < share->use_handlers_length)
- share->all_link_count = share->use_handlers_length;
if (share->all_link_count < share->connect_timeouts_length)
share->all_link_count = share->connect_timeouts_length;
if (share->all_link_count < share->net_read_timeouts_length)
@@ -2877,11 +2869,6 @@ int spider_parse_connect_info(
share->all_link_count)))
goto error;
if ((error_num = spider_increase_long_list(
- &share->use_handlers,
- &share->use_handlers_length,
- share->all_link_count)))
- goto error;
- if ((error_num = spider_increase_long_list(
&share->connect_timeouts,
&share->connect_timeouts_length,
share->all_link_count)))
@@ -3806,8 +3793,6 @@ int spider_set_connect_info_default(
if (share->monitoring_sid[roop_count] == -1)
share->monitoring_sid[roop_count] = global_system_variables.server_id;
- if (share->use_handlers[roop_count] == -1)
- share->use_handlers[roop_count] = 0;
if (share->connect_timeouts[roop_count] == -1)
share->connect_timeouts[roop_count] = 6;
if (share->net_read_timeouts[roop_count] == -1)
@@ -4390,7 +4375,7 @@ SPIDER_SHARE *spider_create_share(
(uint) (sizeof(*tmp_cardinality_upd) * bitmap_size),
&tmp_table_mon_mutex_bitmap,
(uint) (sizeof(*tmp_table_mon_mutex_bitmap) *
- ((spider_param_udf_table_mon_mutex_count() + 7) / 8)),
+ ((spider_udf_table_mon_mutex_count + 7) / 8)),
NullS))
) {
*error_num = HA_ERR_OUT_OF_MEM;
@@ -4440,7 +4425,7 @@ SPIDER_SHARE *spider_create_share(
buf_pos = strmov(buf_pos, link_idx_str);
*buf_pos = '\0';
spider_set_bit(tmp_table_mon_mutex_bitmap,
- spider_udf_calc_hash(buf, spider_param_udf_table_mon_mutex_count())
+ spider_udf_calc_hash(buf, spider_udf_table_mon_mutex_count)
);
}
@@ -4562,7 +4547,7 @@ SPIDER_SHARE *spider_get_share(
TABLE_SHARE *table_share = table->s;
SPIDER_RESULT_LIST *result_list = &spider->result_list;
uint length, tmp_conn_link_idx = 0, buf_sz;
- char *tmp_name, *tmp_cid;
+ char *tmp_name;
int roop_count;
double sts_interval;
int sts_mode;
@@ -4671,7 +4656,7 @@ SPIDER_SHARE *spider_get_share(
{
pthread_mutex_lock(&share->mutex);
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -4703,7 +4688,7 @@ SPIDER_SHARE *spider_get_share(
FALSE, error_num))
) {
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -4725,7 +4710,7 @@ SPIDER_SHARE *spider_get_share(
*error_num != HA_ERR_END_OF_FILE
) {
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -4758,7 +4743,7 @@ SPIDER_SHARE *spider_get_share(
}
}
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -4853,16 +4838,10 @@ SPIDER_SHARE *spider_get_share(
&spider->conns, sizeof(SPIDER_CONN *) * share->link_count,
&spider->conn_link_idx, sizeof(uint) * share->link_count,
&spider->conn_can_fo, sizeof(uchar) * share->link_bitmap_size,
- &spider->sql_kind, sizeof(uint) * share->link_count,
&spider->connection_ids, sizeof(ulonglong) * share->link_count,
&spider->conn_kind, sizeof(uint) * share->link_count,
&spider->db_request_id, sizeof(ulonglong) * share->link_count,
&spider->db_request_phase, sizeof(uchar) * share->link_bitmap_size,
- &spider->m_handler_opened, sizeof(uchar) * share->link_bitmap_size,
- &spider->m_handler_id, sizeof(uint) * share->link_count,
- &spider->m_handler_cid, sizeof(char *) * share->link_count,
- &tmp_cid, sizeof(char) * (SPIDER_SQL_HANDLER_CID_LEN + 1) *
- share->link_count,
&spider->need_mons, sizeof(int) * share->link_count,
&spider->quick_targets, sizeof(void *) * share->link_count,
&result_list->upd_tmp_tbls, sizeof(TABLE *) * share->link_count,
@@ -4872,7 +4851,6 @@ SPIDER_SHARE *spider_get_share(
sizeof(uchar) * share->link_bitmap_size,
&result_list->tmp_table_created,
sizeof(uchar) * share->link_bitmap_size,
- &result_list->sql_kind_backup, sizeof(uint) * share->link_count,
&result_list->casual_read, sizeof(int) * share->link_count,
&spider->dbton_handler,
sizeof(spider_db_handler *) * SPIDER_DBTON_SIZE,
@@ -4892,8 +4870,6 @@ SPIDER_SHARE *spider_get_share(
spider->conn_keys[roop_count] = tmp_name;
*tmp_name = first_byte;
tmp_name += share->conn_keys_lengths[roop_count] + 1;
- spider->m_handler_cid[roop_count] = tmp_cid;
- tmp_cid += SPIDER_SQL_HANDLER_CID_LEN + 1;
result_list->upd_tmp_tbl_prms[roop_count].init();
result_list->upd_tmp_tbl_prms[roop_count].field_count = 1;
spider->conn_kind[roop_count] = SPIDER_CONN_KIND_MYSQL;
@@ -5151,7 +5127,7 @@ SPIDER_SHARE *spider_get_share(
{
pthread_mutex_lock(&share->mutex);
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -5184,7 +5160,7 @@ SPIDER_SHARE *spider_get_share(
FALSE, error_num))
) {
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -5203,7 +5179,7 @@ SPIDER_SHARE *spider_get_share(
*error_num != HA_ERR_END_OF_FILE
) {
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -5233,7 +5209,7 @@ SPIDER_SHARE *spider_get_share(
}
}
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++
) {
if (spider_bit_is_set(share->table_mon_mutex_bitmap, roop_count))
@@ -5317,16 +5293,10 @@ SPIDER_SHARE *spider_get_share(
&spider->conns, sizeof(SPIDER_CONN *) * share->link_count,
&spider->conn_link_idx, sizeof(uint) * share->link_count,
&spider->conn_can_fo, sizeof(uchar) * share->link_bitmap_size,
- &spider->sql_kind, sizeof(uint) * share->link_count,
&spider->connection_ids, sizeof(ulonglong) * share->link_count,
&spider->conn_kind, sizeof(uint) * share->link_count,
&spider->db_request_id, sizeof(ulonglong) * share->link_count,
&spider->db_request_phase, sizeof(uchar) * share->link_bitmap_size,
- &spider->m_handler_opened, sizeof(uchar) * share->link_bitmap_size,
- &spider->m_handler_id, sizeof(uint) * share->link_count,
- &spider->m_handler_cid, sizeof(char *) * share->link_count,
- &tmp_cid, sizeof(char) * (SPIDER_SQL_HANDLER_CID_LEN + 1) *
- share->link_count,
&spider->need_mons, sizeof(int) * share->link_count,
&spider->quick_targets, sizeof(void *) * share->link_count,
&result_list->upd_tmp_tbls, sizeof(TABLE *) * share->link_count,
@@ -5336,7 +5306,6 @@ SPIDER_SHARE *spider_get_share(
sizeof(uchar) * share->link_bitmap_size,
&result_list->tmp_table_created,
sizeof(uchar) * share->link_bitmap_size,
- &result_list->sql_kind_backup, sizeof(uint) * share->link_count,
&result_list->casual_read, sizeof(int) * share->link_count,
&spider->dbton_handler,
sizeof(spider_db_handler *) * SPIDER_DBTON_SIZE,
@@ -5353,8 +5322,6 @@ SPIDER_SHARE *spider_get_share(
spider->conn_keys[roop_count] = tmp_name;
*tmp_name = first_byte;
tmp_name += share->conn_keys_lengths[roop_count] + 1;
- spider->m_handler_cid[roop_count] = tmp_cid;
- tmp_cid += SPIDER_SQL_HANDLER_CID_LEN + 1;
result_list->upd_tmp_tbl_prms[roop_count].init();
result_list->upd_tmp_tbl_prms[roop_count].field_count = 1;
spider->conn_kind[roop_count] = SPIDER_CONN_KIND_MYSQL;
@@ -6403,7 +6370,7 @@ int spider_db_done(
}
spider_free(NULL, spider_table_sts_threads, MYF(0));
- for (roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ for (roop_count= spider_udf_table_mon_mutex_count - 1;
roop_count >= 0; roop_count--)
{
while ((table_mon_list = (SPIDER_TABLE_MON_LIST *) my_hash_element(
@@ -6419,10 +6386,10 @@ int spider_db_done(
spider_udf_table_mon_list_hash[roop_count].array.size_of_element);
my_hash_free(&spider_udf_table_mon_list_hash[roop_count]);
}
- for (roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ for (roop_count= spider_udf_table_mon_mutex_count - 1;
roop_count >= 0; roop_count--)
pthread_cond_destroy(&spider_udf_table_mon_conds[roop_count]);
- for (roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ for (roop_count= spider_udf_table_mon_mutex_count - 1;
roop_count >= 0; roop_count--)
pthread_mutex_destroy(&spider_udf_table_mon_mutexes[roop_count]);
spider_free(NULL, spider_udf_table_mon_mutexes, MYF(0));
@@ -6773,17 +6740,17 @@ int spider_db_init(
if (!(spider_udf_table_mon_mutexes = (pthread_mutex_t *)
spider_bulk_malloc(NULL, 53, MYF(MY_WME | MY_ZEROFILL),
&spider_udf_table_mon_mutexes, (uint) (sizeof(pthread_mutex_t) *
- spider_param_udf_table_mon_mutex_count()),
+ spider_udf_table_mon_mutex_count),
&spider_udf_table_mon_conds, (uint) (sizeof(pthread_cond_t) *
- spider_param_udf_table_mon_mutex_count()),
+ spider_udf_table_mon_mutex_count),
&spider_udf_table_mon_list_hash, (uint) (sizeof(HASH) *
- spider_param_udf_table_mon_mutex_count()),
+ spider_udf_table_mon_mutex_count),
NullS))
)
goto error_alloc_mon_mutxes;
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++)
{
if (mysql_mutex_init(spd_key_mutex_udf_table_mon,
@@ -6791,7 +6758,7 @@ int spider_db_init(
goto error_init_udf_table_mon_mutex;
}
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++)
{
if (mysql_cond_init(spd_key_cond_udf_table_mon,
@@ -6799,7 +6766,7 @@ int spider_db_init(
goto error_init_udf_table_mon_cond;
}
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_mon_mutex_count();
+ roop_count < (int) spider_udf_table_mon_mutex_count;
roop_count++)
{
if (my_hash_init(PSI_INSTRUMENT_ME, &spider_udf_table_mon_list_hash[roop_count],
@@ -6885,7 +6852,7 @@ error_init_table_sts_threads:
spider_free_sts_threads(&spider_table_sts_threads[roop_count]);
}
spider_free(NULL, spider_table_sts_threads, MYF(0));
- roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ roop_count= spider_udf_table_mon_mutex_count - 1;
error_init_udf_table_mon_list_hash:
for (; roop_count >= 0; roop_count--)
{
@@ -6895,11 +6862,11 @@ error_init_udf_table_mon_list_hash:
spider_udf_table_mon_list_hash[roop_count].array.size_of_element);
my_hash_free(&spider_udf_table_mon_list_hash[roop_count]);
}
- roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ roop_count= spider_udf_table_mon_mutex_count - 1;
error_init_udf_table_mon_cond:
for (; roop_count >= 0; roop_count--)
pthread_cond_destroy(&spider_udf_table_mon_conds[roop_count]);
- roop_count = spider_param_udf_table_mon_mutex_count() - 1;
+ roop_count= spider_udf_table_mon_mutex_count - 1;
error_init_udf_table_mon_mutex:
for (; roop_count >= 0; roop_count--)
pthread_mutex_destroy(&spider_udf_table_mon_mutexes[roop_count]);
@@ -7561,16 +7528,14 @@ void spider_set_tmp_share_pointer(
tmp_share->monitoring_kind = &tmp_long[5];
tmp_share->monitoring_bg_flag = &tmp_long[6];
tmp_share->monitoring_bg_kind = &tmp_long[7];
- tmp_share->use_handlers = &tmp_long[13];
- tmp_share->connect_timeouts = &tmp_long[14];
+ tmp_share->connect_timeouts = &tmp_long[13];
+ tmp_share->net_read_timeouts = &tmp_long[14];
tmp_long[13] = -1;
- tmp_share->net_read_timeouts = &tmp_long[15];
+ tmp_share->net_write_timeouts = &tmp_long[15];
tmp_long[14] = -1;
- tmp_share->net_write_timeouts = &tmp_long[16];
- tmp_long[15] = -1;
- tmp_share->access_balances = &tmp_long[17];
- tmp_share->bka_table_name_types = &tmp_long[18];
- tmp_share->strict_group_bys = &tmp_long[19];
+ tmp_share->access_balances = &tmp_long[16];
+ tmp_share->bka_table_name_types = &tmp_long[17];
+ tmp_share->strict_group_bys = &tmp_long[18];
tmp_share->monitoring_limit = &tmp_longlong[0];
tmp_share->monitoring_sid = &tmp_longlong[1];
tmp_share->monitoring_bg_interval = &tmp_longlong[2];
@@ -7627,7 +7592,6 @@ void spider_set_tmp_share_pointer(
tmp_share->monitoring_limit_length = 1;
tmp_share->monitoring_sid_length = 1;
tmp_share->monitoring_bg_interval_length = 1;
- tmp_share->use_handlers_length = 1;
tmp_share->connect_timeouts_length = 1;
tmp_share->net_read_timeouts_length = 1;
tmp_share->net_write_timeouts_length = 1;
@@ -7809,10 +7773,6 @@ longlong spider_split_read_param(
DBUG_RETURN(info_limit);
}
#endif
- if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- DBUG_RETURN(result_list->semi_split_read_base);
- }
spider_get_select_limit(spider, &select_lex, &select_limit, &offset_limit);
DBUG_PRINT("info",("spider result_list->set_split_read=%s", result_list->set_split_read ? "TRUE" : "FALSE"));
if (!result_list->set_split_read)
@@ -8040,8 +8000,6 @@ bool spider_check_direct_order_limit(
}
DBUG_PRINT("info",("spider SQLCOM_HA_READ=%s",
(spider->wide_handler->sql_command == SQLCOM_HA_READ) ? "TRUE" : "FALSE"));
- DBUG_PRINT("info",("spider sql_kinds with SPIDER_SQL_KIND_HANDLER=%s",
- (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER) ? "TRUE" : "FALSE"));
DBUG_PRINT("info",("spider use_index_merge=%s",
spider->use_index_merge ? "TRUE" : "FALSE"));
DBUG_PRINT("info",("spider is_clone=%s",
@@ -8088,11 +8046,6 @@ bool spider_check_direct_order_limit(
first_check = FALSE;
spider->result_list.direct_distinct = FALSE;
spider->result_list.direct_aggregate = FALSE;
- } else if (spider->sql_kinds & SPIDER_SQL_KIND_HANDLER)
- {
- DBUG_PRINT("info",("spider sql_kinds with SPIDER_SQL_KIND_HANDLER"));
- spider->result_list.direct_distinct = FALSE;
- spider->result_list.direct_aggregate = FALSE;
} else if (
!select_lex->group_list.elements &&
!select_lex->with_sum_func
diff --git a/storage/spider/spd_trx.cc b/storage/spider/spd_trx.cc
index 169b412ad3c..8facdebb5f3 100644
--- a/storage/spider/spd_trx.cc
+++ b/storage/spider/spd_trx.cc
@@ -1123,7 +1123,7 @@ int spider_free_trx_alloc(
spider_free_tmp_share_alloc(trx->tmp_share);
}
spider_db_udf_free_set_names(trx);
- for (roop_count = spider_param_udf_table_lock_mutex_count() - 1;
+ for (roop_count = spider_udf_table_lock_mutex_count - 1;
roop_count >= 0; roop_count--)
pthread_mutex_destroy(&trx->udf_table_mutexes[roop_count]);
spider_free_trx_ha(trx);
@@ -1176,7 +1176,7 @@ SPIDER_TRX *spider_get_trx(
&tmp_share, (uint) (sizeof(SPIDER_SHARE)),
&tmp_wide_handler, (uint) sizeof(SPIDER_WIDE_HANDLER),
&udf_table_mutexes, (uint) (sizeof(pthread_mutex_t) *
- spider_param_udf_table_lock_mutex_count()),
+ spider_udf_table_lock_mutex_count),
NullS))
)
goto error_alloc_trx;
@@ -1186,7 +1186,7 @@ SPIDER_TRX *spider_get_trx(
trx->udf_table_mutexes = udf_table_mutexes;
for (roop_count = 0;
- roop_count < (int) spider_param_udf_table_lock_mutex_count();
+ roop_count < (int) spider_udf_table_lock_mutex_count;
roop_count++)
{
if (mysql_mutex_init(spd_key_mutex_udf_table,
@@ -3585,8 +3585,7 @@ int spider_check_trx_and_get_conn(
*spider->conn_keys[0] = first_byte;
for (roop_count = 0; roop_count < (int) share->link_count; roop_count++)
{
- if (!spider->handler_opened(roop_count, SPIDER_CONN_KIND_MYSQL))
- spider->conns[roop_count] = NULL;
+ spider->conns[roop_count]= NULL;
}
bool search_link_idx_is_checked = FALSE;
for (