List:Commits« Previous MessageNext Message »
From:Andrei Elkin Date:November 9 2006 4:31pm
Subject:bk commit into 5.0 tree (aelkin:1.2298)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 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, 2006-11-09 18:31:14+02:00, aelkin@stripped +3 -0
  Merge dsl-hkibras-fe30f900-107.dhcp.inet.fi:/home/elkin/MySQL/TEAM/BARE/4.1
  into  dsl-hkibras-fe30f900-107.dhcp.inet.fi:/home/elkin/MySQL/TEAM/FIXES/5.0/bug15937_ld_max_allowed
  MERGE: 1.1616.2144.194

  sql/log_event.h@stripped, 2006-11-09 18:31:11+02:00, aelkin@stripped +2 -2
    white spaces conflict
    MERGE: 1.90.1.10

  sql/slave.cc@stripped, 2006-11-09 18:31:11+02:00, aelkin@stripped +0 -1
    white spaces conflict
    MERGE: 1.188.1.95

  sql/sql_repl.cc@stripped, 2006-11-09 18:24:13+02:00, aelkin@stripped +0 -0
    Auto merged
    MERGE: 1.102.1.37

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	aelkin
# Host:	dsl-hkibras-fe30f900-107.dhcp.inet.fi
# Root:	/home/elkin/MySQL/TEAM/FIXES/5.0/bug15937_ld_max_allowed/RESYNC

--- 1.124/sql/log_event.h	2006-11-09 18:31:20 +02:00
+++ 1.125/sql/log_event.h	2006-11-09 18:31:20 +02:00
@@ -200,8 +200,14 @@ struct sql_ex_info
 #define EXECUTE_LOAD_QUERY_EXTRA_HEADER_LEN (4 + 4 + 4 + 1)
 #define EXECUTE_LOAD_QUERY_HEADER_LEN  (QUERY_HEADER_LEN + EXECUTE_LOAD_QUERY_EXTRA_HEADER_LEN)
 
-/*
-   Event header offsets;
+/* amount of byte is contribution of replicaton protocol to a query
+   received from user when the query goes to binlog */
+#define MAX_LOG_EVENT_HEADER   (LOG_EVENT_HEADER_LEN + /* write_header */ \
+				QUERY_HEADER_LEN     + /* write_data */   \
+				NAME_LEN + 1)
+
+/* 
+   Event header offsets; 
    these point to places inside the fixed header.
 */
 

--- 1.282/sql/slave.cc	2006-11-09 18:31:20 +02:00
+++ 1.283/sql/slave.cc	2006-11-09 18:31:20 +02:00
@@ -2882,6 +2882,8 @@ static int init_slave_thread(THD* thd, S
     SYSTEM_THREAD_SLAVE_SQL : SYSTEM_THREAD_SLAVE_IO; 
   thd->security_ctx->skip_grants();
   my_net_init(&thd->net, 0);
+  thd->variables.max_allowed_packet= global_system_variables.max_allowed_packet
+    + MAX_LOG_EVENT_HEADER;  /* reentering secured through using global */
   thd->net.read_timeout = slave_net_timeout;
   thd->slave_thread = 1;
   set_slave_thread_options(thd);
@@ -3481,11 +3483,15 @@ slave_begin:
   thd->proc_info = "Connecting to master";
   // we can get killed during safe_connect
   if (!safe_connect(thd, mysql, mi))
+  {
     sql_print_information("Slave I/O thread: connected to master '%s@%s:%d',\
   replication started in log '%s' at position %s", mi->user,
-		    mi->host, mi->port,
-		    IO_RPL_LOG_NAME,
-		    llstr(mi->master_log_pos,llbuff));
+			  mi->host, mi->port,
+			  IO_RPL_LOG_NAME,
+			  llstr(mi->master_log_pos,llbuff));
+    /* post-net-init for slave */
+    mysql->net.max_packet_size= thd->net.max_packet_size+= MAX_LOG_EVENT_HEADER;
+  }
   else
   {
     sql_print_information("Slave I/O thread killed while connecting to master");

--- 1.151/sql/sql_repl.cc	2006-11-09 18:31:20 +02:00
+++ 1.152/sql/sql_repl.cc	2006-11-09 18:31:20 +02:00
@@ -430,6 +430,8 @@ impossible position";
     goto err;
   }
   packet->set("\0", 1, &my_charset_bin);
+  /* dump thread  the whole header size of query_log_event */
+  thd->variables.max_allowed_packet+= MAX_LOG_EVENT_HEADER;
 
   /*
     We can set log_lock now, it does not move (it's a member of
Thread
bk commit into 5.0 tree (aelkin:1.2298)Andrei Elkin9 Nov