diff options
author | monty@tik.mysql.fi <> | 2001-07-07 23:26:06 +0300 |
---|---|---|
committer | monty@tik.mysql.fi <> | 2001-07-07 23:26:06 +0300 |
commit | 19a99dd3fd926fe7d83242bf59b58d497f55cb83 (patch) | |
tree | e0737023555d3078624f28e147e5c02b88c552ac | |
parent | c66b870cfc4b883e4a2ab808fad91b6e3a7c9bbd (diff) | |
download | mariadb-git-19a99dd3fd926fe7d83242bf59b58d497f55cb83.tar.gz |
dded volatile to replication variable
-rw-r--r-- | Docs/manual.texi | 37 | ||||
-rw-r--r-- | sql/slave.cc | 2 | ||||
-rw-r--r-- | sql/slave.h | 3 | ||||
-rw-r--r-- | sql/sql_base.cc | 3 | ||||
-rw-r--r-- | sql/sql_show.cc | 1 |
5 files changed, 32 insertions, 14 deletions
diff --git a/Docs/manual.texi b/Docs/manual.texi index 3dd61c88b6e..247f453bef7 100644 --- a/Docs/manual.texi +++ b/Docs/manual.texi @@ -46423,7 +46423,9 @@ Our TODO section contains what we plan to have in 4.0. @xref{TODO MySQL 4.0}. @itemize @bullet @item -Don't anymore support the client protocol prior to 3.21. +Multi-table @code{DELETE}. +@item +Don't anymore support old client protocols prior to @strong{MySQL} 3.21. @item Don't include the old C API functions @code{mysql_drop_db}, @code{mysql_create_db} and @code{mysql_connect}, if not compiled with @@ -51898,9 +51900,6 @@ master. @code{DELETE FROM table_name} will return the number of deleted rows. For fast execution one should use @code{TRUNCATE table_name}. @item -Multi-table @code{DELETE} (cascading @code{DELETE} and multi-table -@code{DELETE}. -@item Allow @code{DELETE} on @code{MyISAM} tables to use the record cache. To do this, we need to update the threads record cache when we update the @code{.MYD} file. @@ -51974,7 +51973,19 @@ structure. Don't allow more than a defined number of threads to run MyISAM recover at the same time. @item -Change @code{INSERT ... SELECT} to use concurrent inserts. +Change @code{INSERT ... SELECT} to optionally use concurrent inserts. +@item +Implement @code{RENAME DATABASE}. To make this safe for all table handlers, +it should work as follows: +@itemize @bullet +@item +Create the new database. +@item +For every table do a rename of the table to another database, as +we do with the @code{RENAME} command. +@item +Drop the old database. +@end itemize @item Return the original field types() when doing @code{SELECT MIN(column) ... GROUP BY}. @@ -51989,9 +52000,11 @@ in microseconds. @item Add range checking to @code{MERGE} tables. @item +Link the @code{myisampack} code into the server. +@item Port of @strong{MySQL} to BeOS. @item -Link the @code{myisampack} code into the server. +Port of the @strong{MySQL} clients to LynxOS. @item Add a temporary key buffer cache during @code{INSERT/DELETE/UPDATE} so that we can gracefully recover if the index file gets full. @@ -52019,6 +52032,8 @@ a concurrent insert at the end of the file if the file is read-locked. @item Remember @code{FOREIGN} key definitions in the @file{.frm} file. @item +Cascading @code{DELETE} +@item Server side cursors. @item Check if @code{lockd} works with modern Linux kernels; If not, we have @@ -52028,6 +52043,13 @@ give any errors if @code{lockd} works. @item Allow SQL variables in @code{LIMIT}, like in @code{LIMIT @@a,@@b}. @item +Allow update of variables in @code{UPDATE} statements. For example: +@code{UPDATE TABLE foo SET @@a=a+b,a=@@a, b=@@a+c} +@item +Change when user variables are updated so that one can use them with +@code{GROUP BY}, as in the following example: +@code{SELECT id, @@a:=count(*), sum(sum_col)/@@a FROM table_name GROUP BY id}. +@item Don't add automatic @code{DEFAULT} values to columns. Give an error when using an @code{INSERT} that doesn't contain a column that doesn't have a @code{DEFAULT}. @@ -52166,9 +52188,6 @@ Change that @code{ALTER TABLE} doesn't abort clients that executes Fix that when columns referenced in an @code{UPDATE} clause contains the old values before the update started. @item -Allow update of variables in @code{UPDATE} statements. For example: -@code{UPDATE TABLE foo SET @@a=a+b,a=@@a, b=@@a+c} -@item @code{myisamchk}, @code{REPAIR} and @code{OPTIMIZE TABLE} should be able to handle cases where the data and/or index files are symbolic links. @item diff --git a/sql/slave.cc b/sql/slave.cc index 9b9a4041616..9814f707d93 100644 --- a/sql/slave.cc +++ b/sql/slave.cc @@ -26,7 +26,7 @@ #define RPL_LOG_NAME (glob_mi.log_file_name[0] ? glob_mi.log_file_name :\ "FIRST") -bool slave_running = 0; +volatile bool slave_running = 0; pthread_t slave_real_id; MASTER_INFO glob_mi; HASH replicate_do_table, replicate_ignore_table; diff --git a/sql/slave.h b/sql/slave.h index 311368a4b82..1f3955d8a09 100644 --- a/sql/slave.h +++ b/sql/slave.h @@ -91,8 +91,7 @@ int init_master_info(MASTER_INFO* mi); void end_master_info(MASTER_INFO* mi); extern bool opt_log_slave_updates ; pthread_handler_decl(handle_slave,arg); -extern bool volatile abort_loop, abort_slave; -extern bool slave_running; +extern bool volatile abort_loop, abort_slave, slave_running; extern uint32 slave_skip_counter; // needed for problems when slave stops and // we want to restart it skipping one or more events in the master log that diff --git a/sql/sql_base.cc b/sql/sql_base.cc index 177df8f1e81..fd7945cb5bf 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -121,7 +121,7 @@ int list_open_tables(THD *thd,List<char> *tables, const char *db, VOID(pthread_mutex_lock(&LOCK_open)); bzero((char*) &table_list,sizeof(table_list)); - for (uint idx=0 ; result == 0 && idx < open_cache.records; idx++) + for (uint idx=0 ; idx < open_cache.records; idx++) { TABLE *entry=(TABLE*) hash_element(&open_cache,idx); if ((!entry->real_name) || strcmp(entry->table_cache_key,db)) @@ -152,6 +152,7 @@ int list_open_tables(THD *thd,List<char> *tables, const char *db, if (tables->push_back(thd->strdup(entry->real_name))) { result = -1; + break; } } diff --git a/sql/sql_show.cc b/sql/sql_show.cc index 6f99495d94d..84dc5931139 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -127,7 +127,6 @@ int mysqld_show_open_tables(THD *thd,const char *db,const char *wild) DBUG_RETURN(-1); } - send_eof(&thd->net); DBUG_RETURN(0); } |