Below is the list of changes that have just been committed into a local
5.1 repository of elkin. When elkin does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-10-15 12:38:21+03:00, aelkin@stripped
+4 -0
bug#20435 wl#342 heartbeat
addressing windows' failure and warnings.
sql/log_event.h@stripped, 2007-10-15 12:38:17+03:00,
aelkin@stripped +1 -1
correcting the type of pos member
sql/rpl_mi.cc@stripped, 2007-10-15 12:38:17+03:00,
aelkin@stripped +5 -3
explicit cast is safe
sql/sql_repl.cc@stripped, 2007-10-15 12:38:17+03:00,
aelkin@stripped +1 -2
windows have different names for the members.
sql/sql_yacc.yy@stripped, 2007-10-15 12:38:18+03:00,
aelkin@stripped +1 -1
explicit cast is safe - no data loss - as the range of the heartbeat period allows
that.
diff -Nrup a/sql/log_event.h b/sql/log_event.h
--- a/sql/log_event.h 2007-10-13 23:41:04 +03:00
+++ b/sql/log_event.h 2007-10-15 12:38:17 +03:00
@@ -623,7 +623,7 @@ typedef struct st_print_event_info
struct event_coordinates
{
char * file_name; // binlog file name (directories stripped)
- ulong pos; // event's position in the binlog file
+ my_off_t pos; // event's position in the binlog file
};
/*****************************************************************************
diff -Nrup a/sql/rpl_mi.cc b/sql/rpl_mi.cc
--- a/sql/rpl_mi.cc 2007-10-13 23:41:05 +03:00
+++ b/sql/rpl_mi.cc 2007-10-15 12:38:17 +03:00
@@ -73,10 +73,12 @@ void init_master_info_with_options(MASTE
mi->port = master_port;
mi->connect_retry = master_connect_retry;
/*
- always request heartbeat unless master_heartbeat_period is set explicitly zero.
- Here is the default value for heartbeat period if CHANGE MASTER did not specify it:
+ always request heartbeat unless master_heartbeat_period is set
+ explicitly zero. Here is the default value for heartbeat period
+ if CHANGE MASTER did not specify it. (no data loss in conversion
+ as hb period has a max)
*/
- mi->heartbeat_period= slave_net_timeout/2.0;
+ mi->heartbeat_period= (float) slave_net_timeout/2.0;
mi->ssl= master_ssl;
if (master_ssl_ca)
diff -Nrup a/sql/sql_repl.cc b/sql/sql_repl.cc
--- a/sql/sql_repl.cc 2007-10-13 23:41:05 +03:00
+++ b/sql/sql_repl.cc 2007-10-15 12:38:17 +03:00
@@ -418,8 +418,7 @@ void mysql_binlog_send(THD* thd, char* l
if (heartbeat_period != LL(0))
{
heartbeat_ts= &heartbeat_buf;
- heartbeat_ts->tv_sec= 0;
- heartbeat_ts->tv_nsec= 0;
+ set_timespec_nsec(*heartbeat_ts, 0);
coord= &coord_buf;
coord->file_name= log_file_name; // initialization basing on what slave remembers
coord->pos= pos;
diff -Nrup a/sql/sql_yacc.yy b/sql/sql_yacc.yy
--- a/sql/sql_yacc.yy 2007-10-13 23:41:06 +03:00
+++ b/sql/sql_yacc.yy 2007-10-15 12:38:18 +03:00
@@ -1526,7 +1526,7 @@ master_def:
}
| MASTER_HEARTBEAT_PERIOD_SYM EQ NUM_literal
{
- Lex->mi.heartbeat_period= $3->val_real();
+ Lex->mi.heartbeat_period= (float) $3->val_real();
if (Lex->mi.heartbeat_period > SLAVE_MAX_HEARTBEAT_PERIOD ||
Lex->mi.heartbeat_period < 0.0)
{
| Thread |
|---|
| • bk commit into 5.1 tree (aelkin:1.2606) BUG#20435 | Andrei Elkin | 15 Oct |