- 11 Nov, 2010 1 commit
-
-
Dmitry Lenev authored
bug #57006 "Deadlock between HANDLER and FLUSH TABLES WITH READ LOCK" and bug #54673 "It takes too long to get readlock for 'FLUSH TABLES WITH READ LOCK'". The first bug manifested itself as a deadlock which occurred when a connection, which had some table open through HANDLER statement, tried to update some data through DML statement while another connection tried to execute FLUSH TABLES WITH READ LOCK concurrently. What happened was that FTWRL in the second connection managed to perform first step of GRL acquisition and thus blocked all upcoming DML. After that it started to wait for table open through HANDLER statement to be flushed. When the first connection tried to execute DML it has started to wait for GRL/the second connection creating deadlock. The second bug manifested itself as starvation of FLUSH TABLES WITH READ LOCK statements in cases when there was a constant stream of concurrent DML statements (in two or more connections). This has happened because requests for protection against GRL which were acquired by DML statements were ignoring presence of pending GRL and thus the latter was starved. This patch solves both these problems by re-implementing GRL using metadata locks. Similar to the old implementation acquisition of GRL in new implementation is two-step. During the first step we block all concurrent DML and DDL statements by acquiring global S metadata lock (each DML and DDL statement acquires global IX lock for its duration). During the second step we block commits by acquiring global S lock in COMMIT namespace (commit code acquires global IX lock in this namespace). Note that unlike in old implementation acquisition of protection against GRL in DML and DDL is semi-automatic. We assume that any statement which should be blocked by GRL will either open and acquires write-lock on tables or acquires metadata locks on objects it is going to modify. For any such statement global IX metadata lock is automatically acquired for its duration. The first problem is solved because waits for GRL become visible to deadlock detector in metadata locking subsystem and thus deadlocks like one in the first bug become impossible. The second problem is solved because global S locks which are used for GRL implementation are given preference over IX locks which are acquired by concurrent DML (and we can switch to fair scheduling in future if needed). Important change: FTWRL/GRL no longer blocks DML and DDL on temporary tables. Before this patch behavior was not consistent in this respect: in some cases DML/DDL statements on temporary tables were blocked while in others they were not. Since the main use cases for FTWRL are various forms of backups and temporary tables are not preserved during backups we have opted for consistently allowing DML/DDL on temporary tables during FTWRL/GRL. Important change: This patch changes thread state names which are used when DML/DDL of FTWRL is waiting for global read lock. It is now either "Waiting for global read lock" or "Waiting for commit lock" depending on the stage on which FTWRL is. Incompatible change: To solve deadlock in events code which was exposed by this patch we have to replace LOCK_event_metadata mutex with metadata locks on events. As result we have to prohibit DDL on events under LOCK TABLES. This patch also adds extensive test coverage for interaction of DML/DDL and FTWRL. Performance of new and old global read lock implementations in sysbench tests were compared. There were no significant difference between new and old implementations.
-
- 08 Nov, 2010 7 commits
-
-
Jon Olav Hauglid authored
No conflicts
-
Sven Sandberg authored
-
Jon Olav Hauglid authored
-
Jon Olav Hauglid authored
GCOV builds were broken after the patch for Bug#57933 which added add -Wdeclaration-after-statement to gcc builds. This patch fixes: stacktrace.c:328: warning: ISO C90 forbids mixed declarations and code No test case added.
-
Jon Olav Hauglid authored
No conflicts
-
Jon Olav Hauglid authored
GCOV builds were broken after the patch for Bug#57933 which added add -Wdeclaration-after-statement to gcc builds. This patch fixes: stacktrace.c:328: warning: ISO C90 forbids mixed declarations and code No test case added.
-
Anitha Gopi authored
Bug#58041 : Moved rpl_binlog_row to daily. Run just main suite for ps_row and embedded per push. Other suites run daily
-
- 07 Nov, 2010 3 commits
-
-
Dmitry Shulga authored
-
Dmitry Shulga authored
sporadically. The cause of the sporadic time out was a leaking protection against the global read lock, taken by the RENAME statement, and not released in case of an error occurred during RENAME. The leaking protection counter would lead to the value of protect_against_global_read never dropping to 0. Consequently FLUSH TABLES in all connections, including the one that leaked the protection, could not proceed. The fix is to ensure that all branchesin RENAME code properly release GRL protection.
-
He Zhenxing authored
-
- 05 Nov, 2010 8 commits
-
-
Mats Kindahl authored
-
Jon Olav Hauglid authored
No conflicts
-
Guilhem Bichot authored
from 5.1; extended here to Cmake builds.
-
Guilhem Bichot authored
first part, for autotools build.
-
Guilhem Bichot authored
add boolean command-line option --autocommit.
-
Luis Soares authored
mysql-5.5-bugteam.
-
Luis Soares authored
mysql-5.5-bugteam.
-
Luis Soares authored
Small fix for the test case. The column named "slow" was used twice in the SELECTs. As a consequence, the column named "ignore_server_ids" was not used. To fix this we simply replace the second column selected named "slow" with a column named "ignore_server_ids".
-
- 04 Nov, 2010 6 commits
-
-
Jorgen Loland authored
Assertion `fixed == 1' failed Followup patch. Test case relied on system variable that is only available if replication is compiled in. Replaced with variable available in all builds.
-
smenon authored
-
smenon authored
(win/README updated with some more changes)
-
Mats Kindahl authored
If a relative path is supplied to option --defaults-file or --defaults-extra-file, the server will crash when executing an INSTALL PLUGIN command. The reason is that the defaults file is initially read relative the current working directory when the server is started, but when INSTALL PLUGIN is executed, the server has changed working directory to the data directory. Since there is no check that the call to my_load_defaults() inside mysql_install_plugin(), the subsequence call to free_defaults() will crash the server. This patch fixes the problem by: - Prepending the current working directory to the file name when a relative path is given to the --defaults-file or --defaults- extra-file option the first time my_load_defaults() is called, which is just after the server has started in main(). - Adding a check of the return value of my_load_defaults() inside mysql_install_plugin() and aborting command (with an error) if an error is returned. - It also adds a check of the return value for load_defaults in lib_sql.cc for the embedded server since that was missing. To test that the relative files for the options --defaults-file and --defaults-extra-file is handled properly, mysql-test-run.pl is also changed to not add a --defaults-file option if one is provided in the tests *.opt file.
-
Jorgen Loland authored
Assertion `fixed == 1' failed (also fixes duplicate bug 57515) agg_item_set_converter() (item.cc) handles conversion of character sets by creating a new Item. fix_fields() is then called on this newly created item. Prior to this patch, it was not checked whether fix_fields() was successful or not. Thus, agg_item_set_converter() would return success even when an error occured. This patch makes it return error (TRUE) if fix_fields() fails.
-
He Zhenxing authored
Function delegetas_init() did not report proper error messages when there are failures, which made it hard to know where the problem occurred. Fixed the problem by adding specific error message for every possible place that can fail. And since these failures are supposed to never happen, ask the user to report a bug if they happened.
-
- 03 Nov, 2010 9 commits
-
-
Luis Soares authored
In MySQL 5.5 the new reserved words include: SLOW as in FLUSH SLOW LOGS GENERAL as in FLUSH GENERAL LOGS IGNORE_SERVER_IDS as in CHANGE MASTER ... IGNORE_SERVER_IDS MASTER_HEARTBEAT_PERIOD as in CHANGE MASTER ... MASTER_HEARTBEAT_PERIOD These are not reserved words in standard SQL, or in Oracle 11g, and as such, may affect existing applications. We fix this by adding the new words to the list of keywords that are allowed for labels in SPs.
-
Georgi Kodinov authored
-
Georgi Kodinov authored
-
Georgi Kodinov authored
-
Georgi Kodinov authored
-
Georgi Kodinov authored
-
Alexander Nozdrin authored
-
Georgi Kodinov authored
dependent.
-
smenon authored
-
- 02 Nov, 2010 5 commits
-
-
Joerg Bruehe authored
otherwise RPM builds will fail due to "unpackaged file".
-
Joerg Bruehe authored
Before this, a text suffix (like "-rc") after the numeric version was needed.
-
Georgi Kodinov authored
1. Fixed the name of the table to proxies_priv 2. Fixed the column names to be of the form Capitalized_lowecarse instead of Capitalized_Capitalized 3. Added Timestamp and Grantor columns 4. Added tests to plugin_auth to check the table structure 5. Updated the existing tests
-
Georgi Kodinov authored
-
Georgi Kodinov authored
in sql_show.cc, find_files() Removed the extra allocation.
-
- 01 Nov, 2010 1 commit
-
-
karen.langford@oracle.com authored
-