Backport of:
------------------------------------------------------------ revno: 2630.4.18 committer: Dmitry Lenev <dlenev@mysql.com> branch nick: mysql-6.0-3726-w2 timestamp: Tue 2008-06-03 21:07:58 +0400 message: WL#3726 "DDL locking for all metadata objects". After review fixes in progress. Now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. This makes API a bit more clear and makes adjust_mdl_locks_upgradability() much nicer. sql/lock.cc: lock_table_names(): Set TABLE_LIST::mdl_lock_data when allocating new metadata lock request object for table list element. sql/mdl.cc: Now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. Adjusted upgrade/ downgrade functions accordingly. We also got rid of mdl_release_exclusive_locks() and now release locks individually. To simplify this process mdl_release_all_locks_for_name() was introduced. sql/mdl.h: Now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. Adjusted upgrade/ downgrade functions accordingly. We also got rid of mdl_release_exclusive_locks() and now release locks individually. To simplify this process mdl_release_all_locks_for_name() was introduced. sql/sql_base.cc: Now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. We also got rid of mdl_release_exclusive_locks() and now release locks individually. sql/sql_parse.cc: adjust_mdl_locks_upgradability() is much simplier now due to the fact that now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. sql/sql_table.cc: Now during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context. Adjusted upgrade/ downgrade functions accordingly. We also got rid of mdl_release_exclusive_locks() and now release locks individually. To simplify this process mdl_release_all_locks_for_name() was introduced. sql/sql_trigger.cc: ow during upgrading/downgrading metadata locks we deal with individual metadata lock requests rather than with all requests for this object in the context.
Showing
This diff is collapsed.
Please register or sign in to comment