Commit graph

9 commits

Author SHA1 Message Date
unknown
763f105dff Fixed federated and some replication tests to not stop slave until it's up and running.
(Removes some warnings about UNIX_TIMESTAMP from the slave.err logs)
Marked federated_server as a '--big-test'
Change error in net_clear to 'Note', as it interfered with mysql-test-run.


client/mysqltest.c:
  More DBUG messages
  Adding missing DBUG_RETURN
mysql-test/extra/rpl_tests/rpl_max_relay_size.test:
  Added missing sync_slave_with_master
mysql-test/extra/rpl_tests/rpl_relayrotate.test:
  Added missing sync_slave_with_master
mysql-test/include/federated.inc:
  Don't do stop slave before the slave has started properly
  (Removes some warnings about UNIX_TIMESTAMP from the slave.err logs)
mysql-test/include/federated_cleanup.inc:
  Trivial cleanup
mysql-test/t/federated_server.test:
  Don't run this unless under --big-test
  Made test-loop smaller. (We will find out errors in code over time, as the test is run under a lot of difference machines which will compensate for the smaller loop)
mysql-test/t/rpl_flushlog_loop.test:
  Added missing sync_slave_with_master
sql/net_serv.cc:
  Change error to Note (low level warning), as it interfered with mysql-test-run.
  This is probably fine as we in some context on sever shutdown can get information about connection shutdown on the connection while we are doing a query at the same time.
  Still, in normal context one should get this, so it's good to have it in the log as it enables one to find errors easier.
sql/slave.cc:
  Added reason to why things failed to error message
2007-04-17 14:41:16 +03:00
unknown
6575e2d296 fix test for bug#25721
did not run properly on a fast Windows machine
2007-04-04 21:35:58 +00:00
unknown
99c5c28c3c BUG#26257 New Federated Server Functionality Doesn't support differently named tables
* Modified Federated memory allocation to use MEM_ROOT
* Modified sql_servers and federated to allocate share connection
  parameters to use MEM_ROOT
* Modified Federated to allow tablename in addition to server name
* Implicit flushing of tables using altered/dropped server name
* Added tests to prove new functionality works

Contributors to this patch: Patrick Galbraith, Antony Curtis


mysql-test/r/federated_server.result:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
    New test results
mysql-test/t/federated_server.test:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  New test which ensures that one can use the new 'create server'
  functionality and have tables point to the correct table, using CONNECTION='server',
  CONNECTION="server/tablename" and CONNECTION="mysql://...url"
sql/mysql_priv.h:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  new function: close_cached_connection_tables()
sql/sql_base.cc:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  new function: close_cached_connection_tables()
    closes all open tables which match connection string
    provides functionality to allow flushing of altered/dropped server names.
sql/sql_servers.cc:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  * Added function clone_server() to allocate a new server for use by
    get_server_by_name() when creating a federated table
  
  * Now using MEM_ROOT allocation (mark and sweep) to account for meta
    data parameters being allocated properly, particularly with regards to
    to SERVER object. Also cleans up code allocating share.
  
  * Tables using the old definition of server name are now flushed on successful
    execution of ALTER/DROP SERVER.
  
  style: fixed some line-wrapping
sql/sql_servers.h:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  * change in prototype to get_server_by_name()
    caller can now provide mem_root which strings will be copied in to.
storage/federated/ha_federated.cc:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  * Simplified share and share member memory allocaton to use MEM_ROOT
  * Modified parse_url to parse table names along with server names
storage/federated/ha_federated.h:
  BUG #26257 New Federated Server Functionality Doesn't support differently named tables
  
  * Added MEM_ROOT share member
2007-03-24 01:18:19 -07:00
unknown
cb5b56c8ef Bug#25721
"Concurrent ALTER/CREATE SERVER can lead to deadlock"
  Deadlock caused by inconsistant use of mutexes in sql_server.cc
  One mutex has been removed to resolve deadlock.
  Many functions were made private which should not be exported.
  Unused variables and function removed.


mysql-test/r/federated_server.result:
  Bug 25721 "Concurrent ALTER/CREATE SERVER can lead to deadlock"
  
  New test results
mysql-test/t/federated_server.test:
  Bug 25721 "Concurrent ALTER/CREATE SERVER can lead to deadlock"
  
  Test for bug by using stored procedure. Unpatched server would deadlock frequently.
sql/sql_parse.cc:
  Bug 25721 "Concurrent ALTER/CREATE SERVER can lead to deadlock"
  
  check for correct error code when dropping server
sql/sql_servers.cc:
  Bug 25721 "Concurrent ALTER/CREATE SERVER can lead to deadlock"
  
  Removed unneccessary mutex, only need THR_LOCK_servers rwlock to
  guard data structures against race conditions. Misuse of other mutex
  caused deadlock by inconsistant ordering of mutex lock operations.
  Alter order of some operations to hit memory before disk.
  Removed unused function.
  Removed servers_version and servers_cache_initialised variables.
  Made many internal functions static.
sql/sql_servers.h:
  Bug 25721 "Concurrent ALTER/CREATE SERVER can lead to deadlock"
  
  remove internal functions from being exported.
2007-03-23 17:31:27 -07:00
unknown
6d98913be6 Bug#25671
"CREATE/DROP/ALTER SERVER should require privileges"
  Add check for SUPER privilege when executing CREATE/DROP/ALTER SERVER.
  Previously, any user even with only USAGE priv can execute those commands.


mysql-test/r/federated_server.result:
  Bug25671 - CREATE/DROP/ALTER SERVER should require privileges
mysql-test/t/federated_server.test:
  Bug25671 - CREATE/DROP/ALTER SERVER should require privileges
sql/sql_parse.cc:
  Bug25671 - CREATE/DROP/ALTER SERVER should require privileges
    Add check for SUPER privilege when executing CREATE/DROP/ALTER SERVER
2007-03-13 11:58:24 -07:00
unknown
1a95fcff76 WL# 3031
Found that the results from select had to be fixed too.
2006-12-12 19:39:45 -05:00
unknown
19ab3d0966 WL #3031
changed to test verbiage to test PB on 5.1 arch tree
2006-12-12 19:12:30 -05:00
unknown
3e56082709 WL #3031
Trying again (!) to commit the fix containing replace-result to fix the problem
with hard-coded ports in the result file of the federated_server test.
2006-12-12 17:23:11 -05:00
unknown
4e72191ce9 WL# 3031
Backport of functionality in private 5.2 tree. 

Added new language to parser, new mysql.servers table and associated code
to be used by the federated storage engine to allow central connection information
per WL entry.


libmysqld/Makefile.am:
  WL# 3031
  
  Added sql_servers.cc to libmysqld Makefile.am
mysql-test/lib/init_db.sql:
  WL# 3031
  
  Added mysql.servers creation to init_db.sql, which is in turn called by mysql-test-run.pl
scripts/mysql_create_system_tables.sh:
  WL# 3031
  
  Added mysql.servers table creation to script called by non-perl mysql-test-run
sql/Makefile.am:
  WL# 3031
  
  Added sql_servers source and headers to Makefile.am to be built
sql/lex.h:
  WL# 3031
  
  Added tokens needed for SERVERS scheme
sql/mysql_priv.h:
  WL #3031
  
  Added sql_servers.h to mysql_priv.h so mysqld.cc and other code can link with sql_servers code
sql/mysqld.cc:
  WL# 3031
  
  Added servers_free and servers_init to mysqld
sql/sql_lex.cc:
  WL# 3031
  
  Added lex->server_options parameter initialisation
sql/sql_lex.h:
  WL #3031
  
  Added SQLCOM commands needed for sql_server actions
sql/sql_parse.cc:
  WL# 3031
  
  Added switch actions for new SQLCOM sql_server actions
sql/sql_yacc.yy:
  WL #3031
  
  Added tokens needed for sql_servers, CREATE/DROP/ALTER server functionality
sql/share/errmsg.txt:
  WL# 3031
  
  Added two new errors to errormsg.sys
storage/federated/ha_federated.cc:
  WL #3031
  
  Modified federated storage engine to use new connection scheme (servers 
  table) if connection string only specifies connection name vs. complete
  URL
storage/federated/ha_federated.h:
  WL# 3031
  
  Added new share members needed for connection scheme
sql/sql_servers.cc:
  WL #3031
  
  sql_servers.cc - all methods required for manipulating mysql.servers table
  to work with federated new connection scheme (CREATE/ALTER/DROP SERVER ...)
sql/sql_servers.h:
  WL #3031
  
  New header file for sql_servers functionality
mysql-test/r/federated_server.result:
  WL #3031
  
  New test results for testing new connection scheme
sql/sql_yacc.yy.bak:
  WL #3031
  
  Added tokens and definitions required for new CREATE/ALTER/DROP SERVER
  for sql_servers functionality. See WL for details.
mysql-test/t/federated_server.test:
  WL #3031
  
  New test for testing CREATE/ALTER/DROP SERVER, as well as testing that
  federated works with both tradition connection scheme as well as new
  connection scheme.
2006-12-01 19:47:45 -05:00