3899 Gopal Shankar 2012-06-24
WL#6292 - Make TIMESTAMP columns nullable by default.
This patch represents post-push fixes to address following issues:
Change1) The following is done as part of Bug#14162406.
#1: one valgrind issue visible with e.g rpl_udf,
#2: rpl_wl6292 failed with mismatch in MTS mode.
Fixed avoiding read deleted but not-nullified
Slave_worker::info_thd (#1),
correcting Slave_worker::set_rli_description_event() to match
the Coordinator's branch logic (#2).
Change2)
* Do not show deprecation warning with --help option.
This avoids extra warning displayed on every MTR run.
modified:
sql/mysqld.cc
sql/rpl_rli.cc
sql/rpl_rli_pdb.h
sql/rpl_slave.cc
3898 Sergey Vojtovich 2012-06-24 [merge]
Merge.
=== modified file 'sql/mysqld.cc'
--- a/sql/mysqld.cc 2012-06-21 14:22:07 +0000
+++ b/sql/mysqld.cc 2012-06-24 09:38:18 +0000
@@ -8449,7 +8449,7 @@ static int get_options(int *argc_ptr, ch
--explicit_defaults_for_timestamp is not set.
This behavior is deprecated now.
*/
- if (!global_system_variables.explicit_defaults_for_timestamp)
+ if (!opt_help && !global_system_variables.explicit_defaults_for_timestamp)
sql_print_warning("TIMESTAMP with implicit DEFAULT value is deprecated. "
"Please use --explicit_defaults_for_timestamp server "
"option (see documentation for more details).");
=== modified file 'sql/rpl_rli.cc'
--- a/sql/rpl_rli.cc 2012-06-21 02:57:40 +0000
+++ b/sql/rpl_rli.cc 2012-06-24 09:38:18 +0000
@@ -2122,28 +2122,29 @@ bool Relay_log_info::write_info(Rpl_info
Although notice that MTS worker runs it, inefficiently (see assert),
once at its destruction time.
todo: fix Slave_worker and Relay_log_info inheritance relation.
+
+ @param a pointer to be installed into execution context
+ FormatDescriptor event
*/
-void Relay_log_info::set_rli_description_event
- (Format_description_log_event *fdle)
+void Relay_log_info::set_rli_description_event(Format_description_log_event *fe)
{
- DBUG_ASSERT(!info_thd || !is_mts_worker(info_thd) || !fdle);
+ DBUG_ASSERT(!info_thd || !is_mts_worker(info_thd) || !fe);
- if (fdle)
+ if (fe)
{
- adapt_to_master_version(fdle);
+ adapt_to_master_version(fe);
if (info_thd && is_parallel_exec())
{
for (uint i= 0; i < workers.elements; i++)
{
Slave_worker *w= *(Slave_worker **) dynamic_array_ptr(&workers, i);
- w->set_rli_description_event(fdle);
+ w->set_rli_description_event(fe);
}
}
}
- if (rli_description_event)
- delete rli_description_event;
- rli_description_event= fdle;
+ delete rli_description_event;
+ rli_description_event= fe;
}
struct st_feature_version
=== modified file 'sql/rpl_rli_pdb.h'
--- a/sql/rpl_rli_pdb.h 2012-06-21 02:57:40 +0000
+++ b/sql/rpl_rli_pdb.h 2012-06-24 09:38:18 +0000
@@ -357,9 +357,9 @@ public:
*/
void set_rli_description_event(Format_description_log_event *fdle)
{
- rli_description_event= fdle;
- if (fdle && fdle->server_id != (uint32) ::server_id)
+ if (fdle)
adapt_to_master_version(fdle);
+ rli_description_event= fdle;
}
protected:
=== modified file 'sql/rpl_slave.cc'
--- a/sql/rpl_slave.cc 2012-06-20 07:39:11 +0000
+++ b/sql/rpl_slave.cc 2012-06-24 09:38:18 +0000
@@ -4424,6 +4424,7 @@ pthread_handler_t handle_slave_worker(vo
mysql_mutex_lock(&w->jobs_lock);
w->running_status= Slave_worker::NOT_RUNNING;
+ w->info_thd= NULL; // required by ~Slave_worker; thd is deleted by this thread
if (log_warnings > 1)
sql_print_information("Worker %lu statistics: "
"events processed = %lu "
No bundle (reason: useless for push emails).
| Thread |
|---|
| • bzr push into mysql-trunk branch (gopal.shankar:3898 to 3899) WL#6292 | Gopal Shankar | 25 Jun |