--source setup.inc --source include/have_debug.inc --echo # --echo # Test INPLACE ALTER failures at various stages --echo # - on failure, they should rollback restoring the --echo # original table definitions if not already committed. --echo # --echo # Failure when meta-data is missing when trying to commit SHOW CREATE TABLE t8; SELECT * FROM t8 ORDER BY a; set @save_debug = @@global.debug; set global debug='-d'; # Switch DEBUG/TRACING OFF set global debug='+d,ndb_missing_table_in_inplace_alter'; call mtr.add_suppression("Failed to complete inplace alter table commit"); --error ER_INTERNAL_ERROR ALTER TABLE t8 RENAME COLUMN d to d_new, ALGORITHM = INPLACE; set global debug=@save_debug; # ALTER TABLE is not properly rolled back (Bug#30302405) SHOW CREATE TABLE t8; --let $ndb_describe_db= ndb_ddl_test --let $ndb_describe_table= t8 --let $ndb_describe_indexes= 1 --source suite/ndb/include/ndb_describe_table.inc --echo # --echo # Bug#31419144 FIX MEMORY LEAK OF NDB_ALTER_DATA IN PREPARE_INPLACE_ALTER_TABLE --echo # # Simulate failure during Ndb_schema_dist_client's prepare phase and verify the following : # a) A proper error is returned to the user # b) The internal structures are properly freed - this is verified when the subsequent # shutdown of the mysql server completes without any issues. If it faces an issues, # like a DBUG_ASSERT() failure for example, the shutdown_report will fail. set @save_debug = @@global.debug; set global debug='+d,ndb_schema_dist_not_ready_early'; --error ER_GET_ERRMSG ALTER TABLE t1 ADD INDEX idx(a), ALGORITHM = INPLACE; set global debug=@save_debug; --source cleanup.inc