--- a/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
|
+++ b/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
|
@@ -133,10 +133,10 @@ BEGIN
|
'YES')
|
WHERE THREAD_ID NOT IN (SELECT THREAD_ID FROM tmp_threads);
|
|
- DROP TEMPORARY TABLE tmp_setup_actors;
|
- DROP TEMPORARY TABLE tmp_setup_consumers;
|
- DROP TEMPORARY TABLE tmp_setup_instruments;
|
- DROP TEMPORARY TABLE tmp_threads;
|
+ DROP TABLE tmp_setup_actors;
|
+ DROP TABLE tmp_setup_consumers;
|
+ DROP TABLE tmp_setup_instruments;
|
+ DROP TABLE tmp_threads;
|
|
SELECT RELEASE_LOCK('sys.ps_setup_save') INTO v_lock_result;
|
|
diff --git a/scripts/sys_schema/procedures/ps_setup_save.sql b/scripts/sys_schema/procedures/ps_setup_save.sql
|
index a5a2197e935..e5fd9385a2d 100644
|
--- a/scripts/sys_schema/procedures/ps_setup_save.sql
|
+++ b/scripts/sys_schema/procedures/ps_setup_save.sql
|
@@ -75,15 +75,15 @@ BEGIN
|
SELECT GET_LOCK('sys.ps_setup_save', in_timeout) INTO v_lock_result;
|
|
IF v_lock_result THEN
|
- DROP TEMPORARY TABLE IF EXISTS tmp_setup_actors;
|
- DROP TEMPORARY TABLE IF EXISTS tmp_setup_consumers;
|
- DROP TEMPORARY TABLE IF EXISTS tmp_setup_instruments;
|
- DROP TEMPORARY TABLE IF EXISTS tmp_threads;
|
-
|
- CREATE TEMPORARY TABLE tmp_setup_actors LIKE performance_schema.setup_actors;
|
- CREATE TEMPORARY TABLE tmp_setup_consumers LIKE performance_schema.setup_consumers;
|
- CREATE TEMPORARY TABLE tmp_setup_instruments LIKE performance_schema.setup_instruments;
|
- CREATE TEMPORARY TABLE tmp_threads (THREAD_ID bigint unsigned NOT NULL PRIMARY KEY, INSTRUMENTED enum('YES','NO') NOT NULL);
|
+ DROP TABLE IF EXISTS tmp_setup_actors;
|
+ DROP TABLE IF EXISTS tmp_setup_consumers;
|
+ DROP TABLE IF EXISTS tmp_setup_instruments;
|
+ DROP TABLE IF EXISTS tmp_threads;
|
+
|
+ CREATE TABLE tmp_setup_actors LIKE performance_schema.setup_actors;
|
+ CREATE TABLE tmp_setup_consumers LIKE performance_schema.setup_consumers;
|
+ CREATE TABLE tmp_setup_instruments LIKE performance_schema.setup_instruments;
|
+ CREATE TABLE tmp_threads (THREAD_ID bigint unsigned NOT NULL PRIMARY KEY, INSTRUMENTED enum('YES','NO') NOT NULL);
|
cvicentiu, I was thinking this would be enough to for the bug but no, still ER_ILLEGAL_HA_CREATE_OPTION error.
git diff
--- a/scripts/sys_schema/after_setup.sql
+++ b/scripts/sys_schema/after_setup.sql
@@ -14,5 +14,6 @@
--- a/scripts/sys_schema/before_setup.sql
+++ b/scripts/sys_schema/before_setup.sql
@@ -16,6 +16,8 @@
from diagnostics.sql will also fail when trying to create temporary table LIKE, that will use peformance_schema engine, that is not allowed.
CREATE TEMPORARY TABLE tmp_setup_actors LIKE performance_schema.setup_actors;
So IMHO the patch f7216fa63d69448c3de1532a1dd197d0f28faefd exposed the bug in sys_schema in general since sys_scheme used PERFORMANCE_SCHEMA as an temporary storage engine, to create the temporary tables and that is not what PS is allowing and older patch just prevents that (note previous we had silently substitution with MyISAM).
Also changing the code to use TABLE instead of TEMPORARY is not supported by the PS engine
--- a/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
+++ b/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
--- a/scripts/sys_schema/procedures/ps_setup_save.sql
+++ b/scripts/sys_schema/procedures/ps_setup_save.sql
-
+
Leads to
mysqltest: At line 1: query 'call sys.ps_setup_save(0)' failed: ER_CANT_CREATE_TABLE (1005): Can't create table `sys`.`tmp_setup_actors` (errno: 131 "Command not supported by the engine")
P.S. you should run cmake . && make for each change.
Is it possible to use views here? Otherwise I would vote to disable tests pr_diagnostic.