summaryrefslogtreecommitdiff
path: root/sql/repl_failsafe.cc
diff options
context:
space:
mode:
authorunknown <msvensson@pilot.mysql.com>2007-01-29 14:31:48 +0100
committerunknown <msvensson@pilot.mysql.com>2007-01-29 14:31:48 +0100
commita195ad5ea26227dac0d5f503b9e37717b2bc40be (patch)
tree439ceec10fe0ab45b030eb00f2e47e06330862a3 /sql/repl_failsafe.cc
parentb95f107371606a6771e28447750372e172513d95 (diff)
downloadmariadb-git-a195ad5ea26227dac0d5f503b9e37717b2bc40be.tar.gz
Bug#22943 syscall pruning in libmysql
- Set the timeout values only where needed sql/mysql_priv.h: Add new functions for setting read and write timeout on "net" sql/mysqld.cc: - Move the setting of "read_timeout" to the value of "connect_timeout" to just before 'check_connection' which is the function where we want to use the different timeout - With the new functions to set timeout on "net", there is no need to specifically set the default wait_timeout on windows. sql/net_serv.cc: Add new functions for setting read and write timeout of "net, when server is compiled not to use alarms it will set the write/read timeout directly on connection using 'vio_timeout'(using setsockopt if socket) sql/repl_failsafe.cc: Put unused code within "#if NOT_USED" sql/set_var.cc: Use 'net_set_*_timeout' when adjusting timeout value on the current connection sql/slave.cc: The read timeout used when connecting to master server is set using 'mysql_options' in 'connect_to_master' function sql/sql_parse.cc: - Set read and write timeout values to "connect_timeout" during connect phase - Use "read_timeout" value during sslaccept phase, since this is during connect phase it implies "connect-timeout" - Set read and write timeout value back to default after connect phase - Set "read_timeout" to "wait_timeout" while waiting for client. sql/sql_repl.cc: Set "read_timeout" to "wait_timeout" while ask other mysqld to send file sql-common/client.c: Call 'vio_timeout' to set up the read and write timeout's for the newly created connection. It only need to be done once at connect time. vio/vio.c: Use 'vio_timeout' for setting timeout also on an SSL connection since they both use sockets vio/viossl.c: Remove 'vio_ssl_timeout' function
Diffstat (limited to 'sql/repl_failsafe.cc')
-rw-r--r--sql/repl_failsafe.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/sql/repl_failsafe.cc b/sql/repl_failsafe.cc
index 61fd5d9bce4..4c8703226a6 100644
--- a/sql/repl_failsafe.cc
+++ b/sql/repl_failsafe.cc
@@ -57,6 +57,7 @@ static Slave_log_event* find_slave_event(IO_CACHE* log,
functions like register_slave()) are working.
*/
+#if NOT_USED
static int init_failsafe_rpl_thread(THD* thd)
{
DBUG_ENTER("init_failsafe_rpl_thread");
@@ -99,7 +100,7 @@ static int init_failsafe_rpl_thread(THD* thd)
thd->set_time();
DBUG_RETURN(0);
}
-
+#endif
void change_rpl_status(RPL_STATUS from_status, RPL_STATUS to_status)
{
@@ -573,12 +574,14 @@ err:
}
+#if NOT_USED
int find_recovery_captain(THD* thd, MYSQL* mysql)
{
return 0;
}
+#endif
-
+#if NOT_USED
pthread_handler_decl(handle_failsafe_rpl,arg)
{
DBUG_ENTER("handle_failsafe_rpl");
@@ -626,7 +629,7 @@ err:
pthread_exit(0);
DBUG_RETURN(0);
}
-
+#endif
int show_slave_hosts(THD* thd)
{