From: Andrei Elkin Date: March 30 2011 2:11pm Subject: bzr commit into mysql-next-mr-wl5569 branch (andrei.elkin:3271) WL#5754 List-Archive: http://lists.mysql.com/commits/134267 Message-Id: <201103301411.p2UEBYX3006995@mysql1000.dsl.inet.fi> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1825490381==" --===============1825490381== MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline #At file:///home/andrei/MySQL/BZR/2a-23May/WL/mysql-next-mr-wl5569/ based on revid:andrei.elkin@stripped 3271 Andrei Elkin 2011-03-30 wl#5754 Query event parallel execution Small cleanup for comments as requested by reviewer. @ sql/log_event.cc only comments cleanup. @ sql/rpl_slave.cc only comments cleanup. modified: sql/log_event.cc sql/rpl_slave.cc === modified file 'sql/log_event.cc' --- a/sql/log_event.cc 2011-02-27 17:35:25 +0000 +++ b/sql/log_event.cc 2011-03-30 14:11:24 +0000 @@ -2823,20 +2823,26 @@ int Log_event::apply_event(Relay_log_inf { if (parallel) { - // There are two classes of events that Coordinator executes - // itself. One requires all Workers to finish up their assignments. - // The other does not need (actually can not have) this synchronization. + /* + There are two classes of events that Coordinator executes + itself. One requires all Workers to finish up their assignments. + The other does not need (actually can not have) this synchronization. + */ if (!mts_async_exec_by_coordinator(::server_id)) { - // this event does not split the current group but is indeed - // a separator beetwen two master's binlog therefore requiring - // Workers to sync. + /* + this event does not split the current group but is indeed + a separator beetwen two master's binlog therefore requiring + Workers to sync. + */ DBUG_ASSERT(!rli->curr_group_seen_begin); - // marking the event as not being executed in parallel that affects - // memory deallocation in the following execution path. + /* + marking the event as not being executed in parallel that affects + memory deallocation in the following execution path. + */ c_rli->curr_group_is_parallel= FALSE; (void) wait_for_workers_to_finish(rli); } @@ -2844,9 +2850,11 @@ int Log_event::apply_event(Relay_log_inf { if (rli->curr_group_is_parallel) { - // the event is artifical to splits the current group into separate - // relay-logs. Differently to the previous events of the group this one - // is applied by Coordinator and w/o any synchronization with Workers. + /* + the event is artifical to splits the current group into separate + relay-logs. Differently to the previous events of the group this one + is applied by Coordinator and w/o any synchronization with Workers. + */ c_rli->curr_group_split= TRUE; c_rli->curr_group_is_parallel= FALSE; } @@ -2889,8 +2897,10 @@ int Log_event::apply_event(Relay_log_inf if (rli->curr_group_da.elements > 0) { - // the current event sorted out which partion the current group belongs to. - // It's time now to processed deferred array events. + /* + the current event sorted out which partion the current group belongs to. + It's time now to processed deferred array events. + */ for (i= 0; i < rli->curr_group_da.elements; i++) { Slave_job_item da_item; @@ -3112,11 +3122,6 @@ err: if (ev && ev->get_type_code() != ROWS_QUERY_LOG_EVENT) delete ev; // after ev->update_pos() event is garbage - // thd->mem_root of the Worker is engaged either - // inside of the event execution or for holding the updated db:s list. - // It's safe to release it now mem-root now when the applying is over and - // the updated dbs won't be in use any longer. - DBUG_RETURN(error); } === modified file 'sql/rpl_slave.cc' --- a/sql/rpl_slave.cc 2011-02-27 17:35:25 +0000 +++ b/sql/rpl_slave.cc 2011-03-30 14:11:24 +0000 @@ -3793,8 +3793,10 @@ err: { mysql_mutex_lock(&LOCK_thread_count); THD_CHECK_SENTRY(thd); - // to avoid close_temporary_tables() closing temp tables as those - // are Coordinator's burden. + /* + to avoid close_temporary_tables() closing temp tables as those + are Coordinator's burden. + */ thd->system_thread= NON_SYSTEM_THREAD; delete thd; mysql_mutex_unlock(&LOCK_thread_count); --===============1825490381== MIME-Version: 1.0 Content-Type: text/bzr-bundle; charset="us-ascii"; name="bzr/andrei.elkin@stripped" Content-Transfer-Encoding: 7bit Content-Disposition: inline # Bazaar merge directive format 2 (Bazaar 0.90) # revision_id: andrei.elkin@stripped # target_branch: file:///home/andrei/MySQL/BZR/2a-23May/WL/mysql-next-\ # mr-wl5569/ # testament_sha1: 8a054304f076bbe9d171d5f8d45908f46f4deb2f # timestamp: 2011-03-30 17:11:34 +0300 # source_branch: file:///home/andrei/MySQL/BZR/2a-23May/mysql-trunk/ # base_revision_id: andrei.elkin@stripped\ # e185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