MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Dmitry Lenev Date:February 3 2010 7:55pm
Subject:bzr commit into mysql-5.5-next-mr branch (dlenev:3070) Bug#37346
Bug#46272
View as plain text  
#At file:///home/dlenev/src/bzr/mysql-next-4284/ based on revid:kostja@stripped

 3070 Dmitry Lenev	2010-02-03
      A follow-up for the patch which implemented new
      type-of-operation-aware metadata locks and added a
      wait-for graph based deadlock detector to the MDL
      subsystem (this patch fixed bug #46272 "MySQL 5.4.4,
      new MDL: unnecessary deadlock" and bug #37346
      "innodb does not detect deadlock between update and
      alter table").
      
      Removed unused and redundant method.

    modified:
      sql/mdl.cc
      sql/mdl.h
=== modified file 'sql/mdl.cc'
--- a/sql/mdl.cc	2010-02-01 23:22:16 +0000
+++ b/sql/mdl.cc	2010-02-03 19:55:46 +0000
@@ -1141,36 +1141,6 @@ bool MDL_ticket::is_incompatible_when_wa
 
 
 /**
-  Acquire global intention exclusive lock.
-
-  @param[in]  mdl_request  Lock request object for lock to be acquired
-
-  @retval  FALSE   Success. The lock has been acquired.
-  @retval  TRUE    Error.
-*/
-
-bool
-MDL_context::acquire_global_intention_exclusive_lock(MDL_request *mdl_request)
-{
-  DBUG_ASSERT(mdl_request->key.mdl_namespace() == MDL_key::GLOBAL &&
-              mdl_request->type == MDL_INTENTION_EXCLUSIVE);
-
-  /*
-    If this is a non-recursive attempt to acquire global intention
-    exclusive lock we might have to wait until active global shared
-    lock or pending requests will go away. Since we won't hold any
-    resources (except associated with open HANDLERs) while doing it
-    deadlocks are not possible.
-  */
-  DBUG_ASSERT(is_lock_owner(MDL_key::GLOBAL, "", "", MDL_INTENTION_EXCLUSIVE) ||
-              ! has_locks() ||
-              (m_trans_sentinel && m_tickets.front() == m_trans_sentinel));
-
-  return acquire_lock(mdl_request);
-}
-
-
-/**
   Check whether the context already holds a compatible lock ticket
   on an object.
   Start searching the transactional locks. If not

=== modified file 'sql/mdl.h'
--- a/sql/mdl.h	2010-02-03 14:09:27 +0000
+++ b/sql/mdl.h	2010-02-03 19:55:46 +0000
@@ -515,8 +515,6 @@ public:
 
   inline THD *get_thd() const { return m_thd; }
 
-  bool acquire_global_intention_exclusive_lock(MDL_request *mdl_request);
-
   /**
     Wake up context which is waiting for a change of MDL_lock state.
   */


Attachment: [text/bzr-bundle] bzr/dlenev@mysql.com-20100203195546-pcjoum5lb4744jng.bundle
Thread
bzr commit into mysql-5.5-next-mr branch (dlenev:3070) Bug#37346Bug#46272Dmitry Lenev3 Feb