mariadb/mysql-test/suite/perfschema/r
Jon Olav Hauglid 41a3dfe490 A 5.5 version of the fix for Bug #54360 "Deadlock DROP/ALTER/CREATE
DATABASE with open HANDLER"

Remove LOCK_create_db, database name locks, and use metadata locks instead.
This exposes CREATE/DROP/ALTER DATABASE statements to the graph-based
deadlock detector in MDL, and paves the way for a safe, deadlock-free
implementation of RENAME DATABASE.

Database DDL statements will now take exclusive metadata locks on
the database name, while table/view/routine DDL statements take
intention exclusive locks on the database name. This prevents race
conditions between database DDL and table/view/routine DDL.
(e.g. DROP DATABASE with concurrent CREATE/ALTER/DROP TABLE)

By adding database name locks, this patch implements
WL#4450 "DDL locking: CREATE/DROP DATABASE must use database locks" and
WL#4985 "DDL locking: namespace/hierarchical locks".

The patch also changes code to use init_one_table() where appropriate.
The new lock_table_names() function requires TABLE_LIST::db_length to
be set correctly, and this is taken care of by init_one_table().

This patch also adds a simple template to help work with 
the mysys HASH data structure.

Most of the patch was written by Konstantin Osipov.
2010-07-01 15:53:46 +02:00
..
aggregate.result Misc cleanup 2010-01-27 08:26:05 -07:00
bad_option_1.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
bad_option_2.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
binlog_mix.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
binlog_row.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
binlog_stmt.result BUG#50670: Slave stops with error code 1644 2010-04-28 14:47:49 +02:00
cnf_option.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
column_privilege.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_cond_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_events_waits_current.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_events_waits_history.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_events_waits_history_long.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_ews_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_ews_by_instance.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_ews_by_thread_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_file_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_fs_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_fs_by_instance.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_mutex_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_performance_timers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_processlist.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_rwlock_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_setup_consumers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_setup_instruments.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_setup_objects.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
ddl_setup_timers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_cond_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_events_waits_current.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_events_waits_history.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_events_waits_history_long.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_ews_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_ews_by_instance.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_ews_by_thread_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_file_instances.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_file_summary_by_event_name.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_file_summary_by_instance.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_mutex_instances.result Bug#50596 Spurious test failures in perfschema.dml_mutex_instances 2010-01-25 20:12:20 -07:00
dml_performance_timers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_processlist.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_rwlock_instances.result Bug#50596 Spurious test failures in perfschema.dml_mutex_instances 2010-01-25 20:12:20 -07:00
dml_setup_consumers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_setup_instruments.result Patch that changes approach to how we acquire metadata 2010-06-07 11:06:55 +04:00
dml_setup_objects.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
dml_setup_timers.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
func_file_io.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
func_mutex.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
global_read_lock.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
information_schema.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
misc.result Bug#51447 performance schema evil twin files 2010-02-26 10:39:57 -07:00
myisam_file_io.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
no_threads.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
one_thread_per_con.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
pfs_upgrade.result Post-fix for Bug#52444: update test result. 2010-04-15 12:12:03 +04:00
privilege.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
query_cache.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
read_only.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
schema.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
selects.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
server_init.result A 5.5 version of the fix for Bug #54360 "Deadlock DROP/ALTER/CREATE 2010-07-01 15:53:46 +02:00
start_server_no_cond_class.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_cond_inst.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_file_class.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_file_inst.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_mutex_class.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_mutex_inst.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_rwlock_class.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_rwlock_inst.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_thread_class.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_no_thread_inst.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_off.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
start_server_on.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00
tampered_perfschema_table1.result WL#2360 Performance schema 2010-01-11 18:47:27 -07:00