Commit graph

683 commits

Author SHA1 Message Date
unknown
ac590d9ce9 Addendum to WL#4137 "Maria- Framework for testing recovery in mysql-test-run":
possibility, if requested in the test, to do byte-for-byte comparison
of data files after recovery. This makes sense only when testing
REDOs, as UNDO phase generates new log records thus data pages get
new LSNs. First test of maria-recovery.test is changed to test only
REDOs and do byte-for-byte comparison.


mysql-test/include/maria_make_snapshot.inc:
  possibility to compare physically the data files (makes sense
  only if testing REDO phase).
mysql-test/include/maria_verify_recovery.inc:
  allow physical comparison of data files after recovery if requested
mysql-test/r/maria-recovery.result:
  result update (first test tests REDO only now)
mysql-test/t/maria-recovery.test:
  first test tests REDO only now, and thus can do byte-for-byte
  comparison of data files.
2007-11-13 18:49:00 +01:00
unknown
5fbd5dafe7 * WL#4137 Maria- Framework for testing recovery in mysql-test-run
See test maria-recovery.test for a model; all include scripts have
an "API" section at start if they do take parameters from outside.
* Fixing bug reported by Jani and Monty (when two REDOs about the same
page in one group, see ma_blockrec.c). 
* Fixing small bugs in recovery


mysql-test/include/wait_until_connected_again.inc:
  be sure to enter the loop (the previous query by the caller may not have
  failed: it could be
  query;
  mysqladmin shutdown;
  call this script).
mysql-test/lib/mtr_process.pl:
  * Through the "expect" file a test can tell mtr that a server crash
  is expected. What the file contains is irrelevant. Now if its last
  line starts with "wait", mtr will wait before restarting (it will
  wait for the last line to not start with "wait"). This is for
  tests which need to mangle files under the feet of a dead mysqld.
  * Remove "expect" file before restarting; otherwise there could be a
  race condition: tests sees server restarted, does something, writes
  an "expect" file, and then mtr removes that file, then
  test kills mysqld, and then mtr will never restart it.
storage/maria/ma_blockrec.c:
  - when applying a REDO in recovery, we don't anymore put UNDO's LSN on the page
  at once; indeed if in this REDO's group there comes another REDO
  for the same page it would be wrongly skipped. Instead, we keep
  pages pinned, don't change their LSN. When done with all REDOs
  of the group we unpin them and stamp them with UNDO's LSN.
  - fixing bug in applying of REDO_PURGE_BLOCKS in recovery: page_range
  sometimes has TAIL_BIT set, need to turn it down to know the real page
  range.
  - Both bugs are covered in maria-recovery.test
storage/maria/ma_checkpoint.c:
  Capability to, in debug builds only, do some special operations
  (flush all bitmap and data pages, flush state, flush log)
  and crash mysqld, to later test recovery.
   Driven by some --debug=d, symbols.
storage/maria/ma_open.c:
  debugging info
storage/maria/ma_pagecache.c:
  Now that we can _ma_unpin_all_pages() during the REDO phase
  to set page's LSN, the assertion needs to be relaxed.
storage/maria/ma_recovery.c:
  - open trace file in append mode (useful when a test triggers several
  recoveries, we see them all).
  - fixing wrong error detection, it's possible that during recovery
  we want to open an already open table.
  - when applying a REDO in recovery, we don't anymore put UNDO's LSN on the page
  at once; indeed if in this REDO's group there comes another REDO
  for the same page it would be wrongly skipped. Instead, we keep
  pages pinned, don't change their LSN. When done with all REDOs
  of the group we unpin them and stamp them with UNDO's LSN.
  - we verify that all log records of a group are about the same table,
  for debugging.
mysql-test/r/maria-recovery.result:
  result
mysql-test/t/maria-recovery-master.opt:
  crash is expected, core file would take room, stack trace would
  wake pushbuild up.
mysql-test/t/maria-recovery.test:
  Test of recovery from mysql-test (it is already tested as unit tests
  in ma_test_recovery) (WL#4137)
  - test that, if recovery is made to start on an empty table it can
  replay the effects of committed and uncommitted statements (having only
  the committed ones in the end result). This should be the first test
  for someone writing code of new REDOs.
  - test that, if mysqld is crashed and recovery runs we have only
  committed statements in the end result. Crashes are done in different
  ways: flush nothing (so, uncommitted statement is often missing
  from the log => no rollback to do); flush pagecache (implicitely flushes
  log (WAL)) and flush log, both causes rollbacks; flush log can also
  flush state (state.records etc) to test recovery of the state
  (not tested well now as we repair the index anyway).
  - test of bug found by Jani and Monty in recovery (two REDO about
  the same page in one group).
mysql-test/include/maria_empty_logs.inc:
  removes logs, to have a clean sheet for testing recovery.
mysql-test/include/maria_make_snapshot.inc:
  copies a table to another directory, or back, or compares both
  (comparison is not implemented as physical comparison is impossible
  if an UNDO phase happened).
mysql-test/include/maria_make_snapshot_for_comparison.inc:
  copies tables to another directory so that they can later
  serve as a comparison reference (they are the good tables,
  recovery should produce similar ones).
mysql-test/include/maria_make_snapshot_for_feeding_recovery.inc:
  When we want to force recovery to start on old tables, we prepare
  old tables with this script: we put them in a spare directory.
  They are later copied back over mysqltest tables while mysqld is dead.
  We also need to copy back the control file, otherwise mysqld,
  in recovery, would start from the latest checkpoint: latest
  checkpoint plus old tables is not a recovery-possible scenario of course.
mysql-test/include/maria_verify_recovery.inc:
  causes mysqld to crash, restores old tables if requested,
  lets recovery run, compares resulting tables with reference tables
  by using CHECKSUM TABLE.
  We don't do any sanity checks on page's LSN in resulting tables, yet.
2007-11-13 17:12:29 +01:00
unknown
f4afcec393 Merge hynda.mysql.fi:/home/my/mysql-5.1-main
into  hynda.mysql.fi:/home/my/mysql-maria


BitKeeper/etc/ignore:
  auto-union
BUILD/SETUP.sh:
  Auto merged
BitKeeper/deleted/.del-CMakeLists.txt~99a50df6:
  Auto merged
Makefile.am:
  Auto merged
client/mysqldump.c:
  Auto merged
configure.in:
  Auto merged
include/Makefile.am:
  Auto merged
include/keycache.h:
  Auto merged
include/m_string.h:
  Auto merged
include/my_sys.h:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
mysql-test/extra/rpl_tests/rpl_insert_delayed.test:
  Auto merged
mysql-test/lib/mtr_cases.pl:
  Auto merged
mysql-test/lib/mtr_misc.pl:
  Auto merged
mysql-test/lib/mtr_process.pl:
  Auto merged
mysql-test/lib/mtr_report.pl:
  Auto merged
mysql-test/lib/mtr_timer.pl:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/r/alter_table.result:
  Auto merged
mysql-test/r/merge.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/query_cache.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/suite/ndb/r/ps_7ndb.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_events.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_insert.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_row_insert_delayed.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_stm_flsh_tbls.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_stm_insert_delayed.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_switch_stm_row_mixed.result:
  Auto merged
mysql-test/suite/rpl/t/rpl_insert.test:
  Auto merged
mysql-test/suite/rpl/t/rpl_stm_flsh_tbls.test:
  Auto merged
mysql-test/suite/rpl/t/rpl_switch_stm_row_mixed.test:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/myisam.test:
  Auto merged
mysql-test/t/mysqldump.test:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/view.test:
  Auto merged
mysys/array.c:
  Auto merged
mysys/mf_keycache.c:
  Auto merged
mysys/my_init.c:
  Auto merged
mysys/my_symlink2.c:
  Auto merged
mysys/safemalloc.c:
  Auto merged
mysys/thr_lock.c:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_partition.cc:
  Auto merged
sql/ha_partition.h:
  Auto merged
sql/handler.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_xmlfunc.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/net_serv.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/share/errmsg.txt:
  Auto merged
sql/sql_test.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/udf_example.c:
  Auto merged
sql/uniques.cc:
  Auto merged
sql/unireg.cc:
  Auto merged
storage/csv/ha_tina.h:
  Auto merged
storage/myisam/ft_boolean_search.c:
  Auto merged
storage/myisam/ft_nlq_search.c:
  Auto merged
storage/myisam/ft_parser.c:
  Auto merged
storage/myisam/ft_stopwords.c:
  Auto merged
storage/myisam/ha_myisam.cc:
  Auto merged
storage/myisam/ha_myisam.h:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_create.c:
  Auto merged
storage/myisam/mi_delete.c:
  Auto merged
storage/myisam/mi_dynrec.c:
  Auto merged
storage/myisam/mi_extra.c:
  Auto merged
storage/myisam/mi_key.c:
  Auto merged
storage/myisam/mi_locking.c:
  Auto merged
storage/myisam/mi_log.c:
  Auto merged
storage/myisam/mi_packrec.c:
  Auto merged
storage/myisam/mi_rkey.c:
  Auto merged
storage/myisam/mi_search.c:
  Auto merged
storage/myisam/mi_test1.c:
  Auto merged
storage/myisam/mi_test2.c:
  Auto merged
storage/myisam/mi_update.c:
  Auto merged
storage/myisam/mi_write.c:
  Auto merged
storage/myisam/myisamchk.c:
  Auto merged
storage/myisam/myisamlog.c:
  Auto merged
storage/myisam/myisampack.c:
  Auto merged
storage/myisam/sort.c:
  Auto merged
storage/myisam/sp_test.c:
  Auto merged
storage/myisammrg/ha_myisammrg.cc:
  Auto merged
storage/myisammrg/ha_myisammrg.h:
  Auto merged
storage/ndb/src/mgmapi/mgmapi.cpp:
  Auto merged
support-files/compiler_warnings.supp:
  Auto merged
client/mysqltest.c:
  Manual merge between mysql-5.1 and mysql-maria
include/my_base.h:
  Manual merge between mysql-5.1 and mysql-maria
include/my_global.h:
  Manual merge between mysql-5.1 and mysql-maria
include/myisam.h:
  Manual merge between mysql-5.1 and mysql-maria
libmysql/Makefile.shared:
  Manual merge between mysql-5.1 and mysql-maria
mysql-test/r/events_logs_tests.result:
  Manual merge between mysql-5.1 and mysql-maria
mysql-test/suite/rpl/r/rpl_row_flsh_tbls.result:
  Manual merge between mysql-5.1 and mysql-maria
mysql-test/suite/rpl/t/rpl_row_flsh_tbls.test:
  Manual merge between mysql-5.1 and mysql-maria
mysql-test/t/disabled.def:
  Manual merge between mysql-5.1 and mysql-maria
mysql-test/t/events_logs_tests.test:
  Manual merge between mysql-5.1 and mysql-maria
mysys/my_compress.c:
  Manual merge between mysql-5.1 and mysql-maria
mysys/my_getsystime.c:
  Manual merge between mysql-5.1 and mysql-maria
mysys/my_open.c:
  Manual merge between mysql-5.1 and mysql-maria
sql/handler.cc:
  Manual merge between mysql-5.1 and mysql-maria
sql/set_var.h:
  Manual merge between mysql-5.1 and mysql-maria
sql/sql_class.h:
  Manual merge between mysql-5.1 and mysql-maria
sql/sql_show.cc:
  Manual merge between mysql-5.1 and mysql-maria
sql/sql_sort.h:
  Manual merge between mysql-5.1 and mysql-maria
sql/sql_yacc.yy:
  Manual merge between mysql-5.1 and mysql-maria
sql/table.cc:
  Manual merge between mysql-5.1 and mysql-maria
storage/csv/ha_tina.cc:
  Manual merge between mysql-5.1 and mysql-maria
storage/myisam/mi_open.c:
  Manual merge between mysql-5.1 and mysql-maria
storage/myisam/myisamdef.h:
  Manual merge between mysql-5.1 and mysql-maria
unittest/mysys/my_atomic-t.c:
  Manual merge between mysql-5.1 and mysql-maria
2007-09-27 17:05:07 +03:00
unknown
0e8d541d58 Merge mysql.com:/home/gluh/MySQL/Merge/5.1
into  mysql.com:/home/gluh/MySQL/Merge/5.1-opt


mysql-test/suite/rpl/r/rpl_row_tabledefs_2myisam.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_row_tabledefs_3innodb.result:
  Auto merged
2007-09-19 14:09:23 +05:00
unknown
edbc2ca91d Merge magare.gmz:/home/kgeorge/mysql/work/B31001-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/work/B31001-5.1-opt


mysql-test/include/mix1.inc:
  merge 5.0-opt -> 5.1-opt
mysql-test/r/innodb_mysql.result:
  merge 5.0-opt -> 5.1-opt
sql/sql_select.cc:
  merge 5.0-opt -> 5.1-opt
2007-09-14 19:03:14 +03:00
unknown
c0850719bc Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


sql/log_event.cc:
  Auto merged
2007-09-14 11:13:00 +02:00
unknown
5b541452a8 Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt


mysql-test/r/sp.result:
  SCCS merged
mysql-test/t/sp.test:
  SCCS merged
sql/sql_lex.h:
  SCCS merged
sql/sql_parse.cc:
  SCCS merged
sql/sql_yacc.yy:
  SCCS merged
2007-09-13 00:44:50 +05:00
unknown
4c888fcb67 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge


mysql-test/suite/rpl/r/rpl_row_tabledefs_2myisam.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_row_tabledefs_3innodb.result:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster_binlog.h:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/rpl_record.cc:
  Auto merged
sql/rpl_rli.h:
  Auto merged
sql/rpl_utility.cc:
  Auto merged
sql/rpl_utility.h:
  Auto merged
2007-09-11 16:17:28 +02:00
unknown
e763095f6b Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
2007-09-06 22:31:25 +05:00
unknown
f215ae978c correct include file 2007-09-05 18:02:46 +02:00
unknown
c458f7f6a3 Merge weblab.(none):/home/marcsql/TREE/mysql-5.1-base
into  weblab.(none):/home/marcsql/TREE/mysql-5.1-rt50-merge


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/mysql.test:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/rpl_utility.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
2007-09-04 12:25:54 -06:00
unknown
d7463b5e1b Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  ibm.opbmk:/home/alik/Documents/MySQL/devel/5.1-rt-bug25843


sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
2007-08-31 22:13:27 +04:00
unknown
7e0ad09edf Fix for BUG#25843: changing default database between PREPARE and EXECUTE
of statement breaks binlog.

There were two problems discovered by this bug:

  1. Default (current) database is not fixed at the creation time.
     That leads to wrong output of DATABASE() function.

  2. Database attributes (@@collation_database) are not fixed at
     the creation time. That leads to wrong resultset.

Binlog breakage and Query Cache wrong output happened because of
the first problem.

The fix is to remember the current database at the PREPARE-time and
set it each time at EXECUTE.


mysql-test/include/query_cache_sql_prepare.inc:
  The first part of the test case for BUG#25843.
mysql-test/r/query_cache_ps_no_prot.result:
  Update result file.
mysql-test/r/query_cache_ps_ps_prot.result:
  Update result file.
mysql-test/suite/rpl/r/rpl_ps.result:
  Update result file.
mysql-test/suite/rpl/t/rpl_ps.test:
  The second part of the test case for BUG#25843.
sql/mysql_priv.h:
  Added mysql_opt_change_db() prototype.
sql/sp.cc:
  1. Polishing;
  2. sp_use_new_db() has been removed;
  3. Use mysql_opt_change_db() instead of sp_use_new_db().
sql/sp.h:
  sp_use_new_db() has been removed.
  This function has nothing to do with a) sp and b) *new* database.
  It was merely "switch the current database if needed".
sql/sp_head.cc:
  1. Polishing.
  2. Use mysql_opt_change_db() instead of sp_use_new_db().
sql/sql_class.cc:
  Move THD::{db, db_length} into Statement.
sql/sql_class.h:
  Move THD::{db, db_length} into Statement.
sql/sql_db.cc:
  Introduce mysql_opt_change_db() as a replacement (and inspired by)
  sp_use_new_db().
sql/sql_prepare.cc:
  1. Remember the current database in Prepared_statement::prepare().
  2. Switch/restore the current database in Prepared_statement::execute().
2007-08-31 20:42:14 +04:00
unknown
cebc1abcc3 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2007-08-30 14:54:19 -06:00
unknown
89d3d58511 Merge weblab.(none):/home/marcsql/TREE/mysql-5.1-base
into  weblab.(none):/home/marcsql/TREE/mysql-5.1-rt50-merge


client/mysql.cc:
  Auto merged
mysql-test/r/query_cache.result:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2007-08-30 13:23:59 -06:00
unknown
ad49aa0649 Merge bk-internal:/home/bk/mysql-5.1-maint
into  pilot.(none):/data/msvensson/mysql/mysql-5.1-new-maint
2007-08-30 07:25:18 +02:00
unknown
674f49f8f4 Added ORDER BY to udf select so that results are ordered.
mysql-test/include/rpl_udf.inc:
  ORDER BY to force order
mysql-test/suite/rpl/r/rpl_udf.result:
  Fix for ORDER BY
2007-08-29 14:36:08 -07:00
unknown
30678bc067 Merge moksha.local:/Users/davi/mysql/push/bugs/old/30632-5.0
into  moksha.local:/Users/davi/mysql/push/bugs/30632-5.1


sql/sql_handler.cc:
  Auto merged
mysql-test/include/handler.inc:
  Auto merged
mysql-test/r/handler_myisam.result:
  Auto merged
2007-08-29 18:32:19 -03:00
unknown
48193af489 Merge sita.local:/Users/tsmith/m/bk/maint/51-target22
into  sita.local:/Users/tsmith/m/bk/maint/51


sql/field.cc:
  Auto merged
sql/log_event_old.cc:
  Auto merged
sql/rpl_record.h:
  Auto merged
sql/rpl_utility.cc:
  Auto merged
sql/rpl_utility.h:
  Auto merged
sql/slave.h:
  Auto merged
storage/innobase/handler/ha_innodb.cc:
  Auto merged
sql/log_event.cc:
  Manual merge
sql/log_event.h:
  Manual merge
sql/log_event_old.h:
  Manual merge
sql/rpl_record.cc:
  Manual merge
sql/slave.cc:
  Manual merge
2007-08-29 15:28:38 -06:00
unknown
b201a6c7ac Move instance manager tests to it's own suite
mysql-test/suite/im/t/im_daemon_life_cycle-im.opt:
  Rename: mysql-test/t/im_daemon_life_cycle-im.opt -> mysql-test/suite/im/t/im_daemon_life_cycle-im.opt
mysql-test/suite/im/t/im_instance_conf-im.opt:
  Rename: mysql-test/t/im_instance_conf-im.opt -> mysql-test/suite/im/t/im_instance_conf-im.opt
mysql-test/suite/im/t/im_life_cycle-im.opt:
  Rename: mysql-test/t/im_life_cycle-im.opt -> mysql-test/suite/im/t/im_life_cycle-im.opt
mysql-test/suite/im/t/im_options-im.opt:
  Rename: mysql-test/t/im_options-im.opt -> mysql-test/suite/im/t/im_options-im.opt
mysql-test/suite/im/t/im_utils-im.opt:
  Rename: mysql-test/t/im_utils-im.opt -> mysql-test/suite/im/t/im_utils-im.opt
mysql-test/suite/im/r/im_cmd_line.result:
  Rename: mysql-test/r/im_cmd_line.result -> mysql-test/suite/im/r/im_cmd_line.result
mysql-test/suite/im/r/im_daemon_life_cycle.result:
  Rename: mysql-test/r/im_daemon_life_cycle.result -> mysql-test/suite/im/r/im_daemon_life_cycle.result
mysql-test/suite/im/r/im_instance_conf.result:
  Rename: mysql-test/r/im_instance_conf.result -> mysql-test/suite/im/r/im_instance_conf.result
mysql-test/suite/im/r/im_life_cycle.result:
  Rename: mysql-test/r/im_life_cycle.result -> mysql-test/suite/im/r/im_life_cycle.result
mysql-test/suite/im/r/im_options.result:
  Rename: mysql-test/r/im_options.result -> mysql-test/suite/im/r/im_options.result
mysql-test/suite/im/r/im_utils.result:
  Rename: mysql-test/r/im_utils.result -> mysql-test/suite/im/r/im_utils.result
mysql-test/suite/im/t/utils.sh:
  Rename: mysql-test/t/utils.sh -> mysql-test/suite/im/t/utils.sh
mysql-test/suite/im/t/wait_for_process.sh:
  Rename: mysql-test/t/wait_for_process.sh -> mysql-test/suite/im/t/wait_for_process.sh
mysql-test/suite/im/t/wait_for_socket.sh:
  Rename: mysql-test/t/wait_for_socket.sh -> mysql-test/suite/im/t/wait_for_socket.sh
mysql-test/suite/im/t/log.sh:
  Rename: mysql-test/t/log.sh -> mysql-test/suite/im/t/log.sh
mysql-test/suite/im/t/kill_n_check.sh:
  Rename: mysql-test/t/kill_n_check.sh -> mysql-test/suite/im/t/kill_n_check.sh
mysql-test/suite/im/t/im_check_env.inc:
  Rename: mysql-test/include/im_check_env.inc -> mysql-test/suite/im/t/im_check_env.inc
mysql-test/suite/im/t/im_cmd_line.imtest:
  Update location of im_check_env.inc
mysql-test/suite/im/t/im_daemon_life_cycle.imtest:
  Update location of im_check_env.inc
  Add variable UTIL that points to the "ugly" .sh scripts
mysql-test/suite/im/t/im_instance_conf.imtest:
  Update location of im_check_env.inc
mysql-test/suite/im/t/im_life_cycle.imtest:
  Update location of im_check_env.inc
  Add variable UTIL that points to the "ugly" .sh scripts
mysql-test/suite/im/t/im_options.imtest:
  Update location of im_check_env.inc
mysql-test/suite/im/t/im_utils.imtest:
  Update location of im_check_env.inc
  Add variable UTIL that points to the "ugly" .sh scripts
mysql-test/t/disabled.def:
  Move disabled im test to suite/im/t/disabled.def
mysql-test/suite/im/t/disabled.def:
  New BitKeeper file ``mysql-test/suite/im/t/disabled.def''
2007-08-29 19:02:33 +02:00
unknown
53daf2e674 Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  linux-st28.site:/home/martin/mysql/src/5.1o-bug30596


sql/sql_select.cc:
  Auto merged
2007-08-28 18:17:44 +02:00
unknown
22440b5387 Bug #30596 GROUP BY optimization gives wrong result order
The optimization that uses a unique index to remove GROUP BY did not 
ensure that the index was actually used, thus violating the ORDER BY
that is implied by GROUP BY.
Fixed by replacing GROUP BY with ORDER BY if the GROUP BY clause contains
a unique index over non-nullable field(s). In case GROUP BY ... ORDER BY 
null is used, GROUP BY is simply removed.


mysql-test/include/mix1.inc:
  Bug#30596: Test case for InnoDB
  Here, as opposed to for MyISAM, row lookup is done using index 
  whenever the index covers the group list.
mysql-test/r/distinct.result:
  Bug#30596: Changed test case. 
  Prior to Bug#16458, These queries use temp table and filesort. The
  bug was that they used a temp table. However, that patch removed
  filesort also, in which case we can no longer gurantee correct ordering.
mysql-test/r/group_by.result:
  Bug#30596: Correct result
  The test case for IGNORE INDEX FOR GROUP BY gets degraded performance 
  (unneccesary filesort). This is due to Bug#30665, which will be fixed separately.
mysql-test/r/innodb_mysql.result:
  Bug#30596: Test result
mysql-test/t/group_by.test:
  Bug#30596: Test case
sql/sql_select.cc:
  Bug#30596: The fix: 
  - replace GROUP BY with ORDER BY unless ORDER BY [NULL|<constant>]
  - make sure to use the keys for GROUP BY in this ORDER BY.
2007-08-28 18:01:29 +02:00
unknown
95834a51f4 Merge ramayana.hindu.god:/home/tsmith/m/bk/51-target22-X
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51


configure.in:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/partition_pruning.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/suite/rpl/include/rpl_mixed_ddl.inc:
  Auto merged
mysql-test/suite/rpl/include/rpl_mixed_dml.inc:
  Auto merged
mysql-test/suite/rpl/r/rpl_timezone.result:
  Auto merged
mysql-test/suite/rpl/t/rpl_relayspace.test:
  Auto merged
mysql-test/suite/rpl/t/rpl_timezone.test:
  Auto merged
mysql-test/t/select.test:
  Auto merged
netware/BUILD/compile-netware-END:
  Auto merged
netware/Makefile.am:
  Auto merged
sql/field.cc:
  Auto merged
sql/ha_partition.cc:
  Auto merged
sql/ha_partition.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/time.cc:
  Auto merged
storage/innobase/handler/ha_innodb.cc:
  Auto merged
storage/innobase/log/log0recv.c:
  Auto merged
storage/innobase/srv/srv0srv.c:
  Auto merged
storage/innobase/trx/trx0trx.c:
  Auto merged
mysql-test/suite/rpl/r/rpl_innodb_mixed_dml.result:
  manual merge (use remote)
mysql-test/suite/rpl/t/disabled.def:
  Manual merge - both rpl_innodb_mixed_ddl and rpl_innodb_mixed_dml
  are fixed, and should be run as part of the rpl suite.
2007-08-27 18:41:29 -06:00
unknown
05d3b8d682 Merge quant.(none):/ext/mysql/bkroot/mysql-5.1-target-5.1.22
into  quant.(none):/ext/mysql/bk/mysql-5.1-bug21842-5.1.22-merge
2007-08-27 22:51:13 +02:00
unknown
bfed329e17 Fixes for the following bugs:
Bug #30316: Some "parts" tests fail because the server uses "--secure-file-priv"
Bug #30341: Test suite "parts" needs to be adapted to the new rules disallowing many functio
Bug #30408: Suite "parts" needs bug numbers updated
Bug #30411: Suite "parts" needs bug numbers updated: ER_UNIQUE_KEY_NEED_ALL_FIELDS_IN_PF
Bug #30576: part_supported_sql_func_innodb.test tries to LOAD DATA outside of var dir
Bug #30581: partition_value tests use disallowed CAST() function

Included are some general fixes to allow the "parts" test suite to be run
successfully.  This includes disabling a few tests or parts of tests,
cleaning up the test cases and their results, etc.  Basically, these tests
have not been run for some time, and had suffered some bit rot.

The bugs were fixed as a single changeset, because in some ways they depend
on each other.  I couldn't be sure I'd updated all the error codes (for
bugs 30408 and 30411) without also adapting to the new allowed functions
rules (bug 30341), and vice versa.


mysql-test/include/partition_layout.inc:
  Ensure that the contents of $MYSQLTEST_VARDIR are not in the result file
mysql-test/suite/parts/inc/part_blocked_sql_funcs_main.inc:
  Add ASCII(), ORD() and WEEKOFYEAR() as blocked functions (they depend
  too much on character set, etc.).
  
  Remove DATEDIFF() as a blocked function (it is implemented in terms
  of TO_DAYS() and the minus operator).
mysql-test/suite/parts/inc/part_supported_sql_funcs_main.inc:
  Remove ASCII(), ORD() and WEEKOFYEAR(), which are not allowed functions.
  
  Remove uses of CAST() in partitioning functions - it is not allowed.
  
  Disable testing of FLOOR() and CEILING on non-integer fields, due to
  Bug 30577.
  
  Test MOD() with an integer field instead of floating point (it has a
  hybrid result type, like FLOOR() and CEILING(), but makes sense to use
  with an integer field).
  
  Add DATEDIFF() as an allowed function, because it is implemented in
  terms of TO_DAYS() and the minus operator.
mysql-test/suite/parts/inc/partition_alter3.inc:
  Remove use of disallowed CAST() function in partitioning
mysql-test/suite/parts/inc/partition_blocked_sql_funcs.inc:
  The blocked functions are actually blocked now, so expect errors.
  
  This is a result of the fix for bug 18198.
mysql-test/suite/parts/inc/partition_date.inc:
  Remove uses of CAST() in partitioning functions - it is not allowed.
mysql-test/suite/parts/inc/partition_datetime.inc:
  Remove uses of CAST() in partitioning functions - it is not allowed.
mysql-test/suite/parts/inc/partition_decimal.inc:
  Remove uses of CAST() in partitioning functions - it is not allowed.
  
  Disable testing of FLOOR() and CEILING(), due to Bug 30577.
mysql-test/suite/parts/inc/partition_directory.inc:
  Ensure that the contents of $MYSQLTEST_VARDIR are not in the result file
mysql-test/suite/parts/inc/partition_double.inc:
  Remove uses of CAST() in partitioning functions - it is not allowed.
  
  Disable testing of FLOOR() and CEILING(), due to Bug 30577.
mysql-test/suite/parts/inc/partition_enum.inc:
  Remove use of CAST(), which is disallowed.
  
  Remove test which relies on CAST().
mysql-test/suite/parts/inc/partition_float.inc:
  Remove uses of CAST() in partitioning functions - it is not allowed.
  
  Disable testing of FLOOR() and CEILING(), due to Bug 30577.
mysql-test/suite/parts/inc/partition_layout_check1.inc:
  Ensure that the contents of $MYSQLTEST_VARDIR are not in the result file
mysql-test/suite/parts/inc/partition_layout_check2.inc:
  Ensure that the contents of $MYSQLTEST_VARDIR are not in the result file
mysql-test/suite/parts/inc/partition_methods1.inc:
  Ensure that the contents of $MYSQLTEST_VARDIR are not in the result file
mysql-test/suite/parts/inc/partition_set.inc:
  Remove test which relies on CAST(), which is disallowed.
mysql-test/suite/parts/inc/partition_supported_sql_funcs.inc:
  Fix Bug #30576: part_supported_sql_func_innodb.test tries to LOAD DATA outside of var dir
  
  Move data files into std_data/parts/*, so they can be used with LOAD
  DATA INFILE '../std_data_ln/parts/*' while --secure-file-priv is in
  force.
mysql-test/suite/parts/inc/partition_syntax.inc:
  Remove use of CAST(), which is disallowed.
mysql-test/suite/parts/inc/partition_time.inc:
  Remove use of CAST(), which is disallowed.
mysql-test/suite/parts/inc/partition_timestamp.inc:
  Remove use of CAST(), which is disallowed.
mysql-test/suite/parts/inc/partition_value.inc:
  Disable this entire test file, because it relies on using CAST() as
  a partitioning function, which is disallowed.  See Bug 30581,
  "partition_value tests use disallowed CAST() function".
mysql-test/suite/parts/r/part_blocked_sql_func_innodb.result:
  Update test case results
mysql-test/suite/parts/r/part_blocked_sql_func_myisam.result:
  Update test case results
mysql-test/suite/parts/r/part_supported_sql_func_innodb.result:
  Update test case results
mysql-test/suite/parts/r/part_supported_sql_func_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_alter3_innodb.result:
  Update test case results
mysql-test/suite/parts/r/partition_alter3_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_basic_innodb.result:
  Update test case results
mysql-test/suite/parts/r/partition_basic_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_datetime_innodb.result:
  Update test case results
mysql-test/suite/parts/r/partition_datetime_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_decimal_innodb.result:
  Update test case results
mysql-test/suite/parts/r/partition_decimal_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_float_myisam.result:
  Update test case results
mysql-test/suite/parts/r/partition_syntax_innodb.result:
  Update test case results
mysql-test/suite/parts/r/partition_syntax_myisam.result:
  Update test case results
mysql-test/suite/parts/t/disabled.def:
  Mark several more tests as disabled: partition_value_myisam,
  partition_value_innodb, part_supported_sql_func_ndb,
  rpl_ndb_dd_partitions, and partition_float_innodb
mysql-test/std_data/parts/part_supported_sql_funcs_int_ch1.inc:
  Rename: mysql-test/suite/parts/inc/part_supported_sql_funcs_int_ch1.inc -> mysql-test/std_data/parts/part_supported_sql_funcs_int_ch1.inc
mysql-test/std_data/parts/part_supported_sql_funcs_int_date.inc:
  Rename: mysql-test/suite/parts/inc/part_supported_sql_funcs_int_date.inc -> mysql-test/std_data/parts/part_supported_sql_funcs_int_date.inc
mysql-test/std_data/parts/part_supported_sql_funcs_int_float.inc:
  Rename: mysql-test/suite/parts/inc/part_supported_sql_funcs_int_float.inc -> mysql-test/std_data/parts/part_supported_sql_funcs_int_float.inc
mysql-test/std_data/parts/part_supported_sql_funcs_int_int.inc:
  Rename: mysql-test/suite/parts/inc/part_supported_sql_funcs_int_int.inc -> mysql-test/std_data/parts/part_supported_sql_funcs_int_int.inc
mysql-test/std_data/parts/part_supported_sql_funcs_int_time.inc:
  Rename: mysql-test/suite/parts/inc/part_supported_sql_funcs_int_time.inc -> mysql-test/std_data/parts/part_supported_sql_funcs_int_time.inc
mysql-test/suite/parts/inc/partition_alter_1.inc:
  Correct expected error codes, which changed due to bug 29245.
mysql-test/suite/parts/inc/partition_check.inc:
  Correct expected error codes, which changed due to bug 29245.
mysql-test/suite/parts/inc/partition_syntax_1.inc:
  Correct expected error codes, which changed due to bug 29245.
2007-08-27 14:08:32 -06:00
unknown
e7d7a2382f Merge moksha.local:/Users/davi/mysql/push/bugs/25164-5.0
into  moksha.local:/Users/davi/mysql/push/bugs/25164-5.1


sql/lock.cc:
  Auto merged
mysql-test/include/deadlock.inc:
  Auto merged
mysql-test/r/deadlock_innodb.result:
  Auto merged
2007-08-27 10:19:58 -03:00
unknown
642eda2229 BUG#21842 (Cluster fails to replicate to innodb or myisam with err 134
using TPC-B):
 
Problem: A RBR event can contain incomplete row data (only key value and
fields which have been changed). In that case, when the row is unpacked
into record and written to a table, the missing fields get incorrect NULL
values leading to master-slave inconsistency.
 
Solution: Use values found in slave's table for columns which are not given
in the rows event. The code for writing a single row uses the following 
algorithm: 

1. unpack row_data into table->record[0],
2. try to insert record,
3. if duplicate record found, fetch it into table->record[0],
4. unpack row_data into table->record[0],
5. write table->record[0] into the table.

Where row_data is the row as stored in the data area of a rows event. 
Thus:

a) unpacking of row_data happens at the time when row is written into 
 a table,

b) when unpacking (in step 4), only columns present in row_data are 
 overwritten - all other columns remain as they were found in the table.
 
Since all data needed for the above algorithm is stored inside 
Rows_log_event class, functions which locate and write rows are turned 
into methods of that class.

replace_record()     -> Rows_log_event::write_row()
find_and_fetch_row() -> Rows_log_event::find_row()

Both methods take row data from event's data buffer - the row being 
processed is pointed by m_curr_row. They unpack the data as needed into 
table's record buffers record[0] or record[1]. When row is unpacked, 
m_curr_row_end is set to point at next row in the data buffer.

Other changes introduced in this changeset:

- Change signature of unpack_row(): don't report errors and don't
setup table's rw_set here. Errors can happen only when setting default 
values in prepare_record() function and are detected there.
 
- In Rows_log_event and derived classes, don't pass arguments to
the execution primitives (do_...() member functions) but use class
members instead.

- Move old row handling code into log_event_old.cc to be used by 
*_rows_log_event_old classes.

Also, a new test rpl_ndb_2other is added which tests basic replication 
from master using ndb tables to slave storing the same tables using 
(possibly) different engine (myisam,innodb).
  
Test is based on existing tests rpl_ndb_2myisam and rpl_ndb_2innodb. 
However, these tests doesn't work for various reasons and currently are 
disabled (see BUG#19227).
  
The new test differs from the ones it is based on as follows:
  
1. Single test tests replication with different storage engines on slave 
(myisam, innodb, ndb).
  
2. Include file extra/rpl_tests/rpl_ndb_2multi_eng.test containing 
original tests is replaced by extra/rpl_tests/rpl_ndb_2multi_basic.test 
which doesn't contain tests using partitioned tables as these don't work 
currently. Instead, it tests replication to a slave which has more or 
less columns than master.
  
3. Include file include/rpl_multi_engine3.inc is replaced with 
include/rpl_multi_engine2.inc. The later differs by performing slightly 
different operations (updating more than one row in the table) and 
clearing table with "TRUNCATE TABLE" statement instead of "DELETE FROM" 
as replication of "DELETE" doesn't work well in this setting.
  
4. Slave must use option --log-slave-updates=0 as otherwise execution of 
replication events generated by ndb fails if table uses a different 
storage engine on slave (see BUG#29569).


sql/log_event.cc:
  - Initialization of new Rows_log_event members.
  - Fixing some typos in documentation.
  
  In Rows_log_event::do_apply_event:
  - Set COMPLETE_ROWS_F flag (when master and slave have the same number of 
  columns and all colums are present in the row)
  - Move initialization of tables write/read sets here, outside the rows
  processing loop (and out of unpack_row() function).
  - Remove calls to do_prepare_row() - no longer needed.
  - Add code managing m_curr_row and m_curr_row_end pointers.
  
  - Change signatures of row processing methods of Rows_log_event and it
  descendants - now most arguments are taken from class members.
  - Remove do_prepare_row() methods which are no longer used.
  - The auto_afree_ptr template is moved to rpl_utility.h (so that it can
  be used in log_event_old.cc).
  - Removed copy_extra_fields() function - no longer used.
  
  In Rows_log_event::write_row (former replace_record):
  - The old code is moved to log_event_old.cc.
  - Use prepare_record() and non-destructive unpack_current_row() to fill record
  with data.
  - In case a record being inserted already exists on slave and row data is 
  incomplete use the record found and non-destructive unpack_current_row() to 
  combine new column values with existing ones.
  - More debug info added.
  
  In Rows_log_event::find_row (former find_and_fetch_row function):
  - The old code is moved to log_event_old.cc.
  - Unpacking of the row is moved here.
  - In case of search using PK, the key data is prepared here.
  - More debug info added.
  
  - Remove initialization of Rows_log_event::m_after_image buffer which is no
  longer used. 
  - Use new row unpacking methods in Update_rows_log_event::do_exec_row() to 
  create before and after image.
  
  Note: all existing code used by Rows_log_event::do_apply_event() has been moved
  to log_event_old.cc to be used by *_rows_log_event_old classes.
sql/log_event.h:
  - Add new COMPLETE_ROWS_F flag in Rows_log_event.
  - Add Rows_log_event members describing the row being processed.
  - Add a pointer to key buffer which is used in derived classes.
  - Add new methods: find__row(), write_row() and unpack_current_row().
  - Change signatures of do_...() methods (replace method arguments by
  class members).
  - Remove do_prepare_row() method which is no longer used.
  - Update method documentation.
  - Add Old_rows_log_event class, which contains the old row processing code, as
  a friend of Rows_log_event so that it can access all members of an event 
  instance.
sql/log_event_old.cc:
  Move here old implementation of Rows_log_event::do_apply_event() and 
  helper methods.
sql/log_event_old.h:
  - Define new class Old_rows_log_event encapsulating old version of
  Rows_log_event::do_apply_event() and the helper methods.
  - Add the Old_rows_log_event class as a base for *_old versions of RBR event
  classes, ensure that the old version of do_apply_event() is called.
  - For *_old classes, declare the helper methods used in the old version of
  do_apply_event().
sql/rpl_record.cc:
  - Make unpack_row non-destructive for columns not present in the row.
  - Don't fill read/write set here as it is done outside these functions.
  - Move initialization of a record with default values to a separate
  function prepare_record().
sql/rpl_record.h:
  - Change signature of unpack_row().
  - Declare function prepare_record().
sql/rpl_utility.cc:
  Make tabe_def::calc_field_size() a const method.
sql/rpl_utility.h:
  Make table_def::calc_field_size() a const method.
  
  Move auto_afree_ptr template here so that it can be re-used (currently
  in log_event.cc and log_event_old.cc). Similar with DBUG_PRINT_BITSET 
  macro.
mysql-test/extra/rpl_tests/rpl_ndb_2multi_basic.test:
  Modification of rpl_ndb_2multi_eng test. Tests with partitioned tables 
  are removed and a setup with slave having different number of columns 
  than master is added.
mysql-test/include/rpl_multi_engine2.inc:
  Modification of rpl_multi_engine3.inc which operates on more rows and
  replaces "DELETE FROM t1" with "TRUNCATE TABLE t1" as the first form
  doesn't replicate in NDB -> non-NDB setting (BUG#28538).
mysql-test/suite/rpl_ndb/r/rpl_ndb_2other.result:
  Results of the test.
mysql-test/suite/rpl_ndb/t/rpl_ndb_2other-slave.opt:
  Test options. --log-slave-updates=0 is compulsory as otherwise non-NDB 
  slave applying row events from NDB master will fail when trying to log
  them.
mysql-test/suite/rpl_ndb/t/rpl_ndb_2other.test:
  Test replication of NDB table to slave using other engine. The main test
  is in extra/rpl_tests/rpl_ndb_2multi_basic.test. It is included here
  several times with different settings of default storage engine on slave.
2007-08-26 14:31:10 +02:00
unknown
3fa6127979 Merge dfischer@bk-internal.mysql.com:/home/bk/mysql-5.1-build
into  pippilotta.erinye.com:/shared/home/df/mysql/build/mysql-5.1-build


libmysql/libmysql.c:
  Auto merged
mysql-test/r/information_schema.result:
  Auto merged
mysql-test/t/information_schema.test:
  Auto merged
sql/ha_partition.cc:
  Auto merged
sql/ha_partition.h:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
2007-08-24 10:13:03 +02:00
unknown
30f5bb9ec8 Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
into  bk-internal.mysql.com:/users/gshchepa/mysql-5.1-opt


sql/item.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
2007-08-23 21:38:24 +02:00
unknown
caab3177ac Merge trift2.:/MySQL/M51/target-5.1.22
into  trift2.:/MySQL/M51/push-5.1
2007-08-22 19:52:30 +02:00
unknown
fc766e515e Bug#30359
"Test federated_bug_25714 issues non-existing shell command"
  Problem caused by missing '$' symbol in eval statement causing it
  to always attempt to run test even if the test was not compiled.


mysql-test/include/have_bug25714.inc:
  bug30359
    missing '$' in eval statement
2007-08-22 10:15:20 -07:00
unknown
4a61b16b7c Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt


sql/sql_base.cc:
  Auto merged
2007-08-21 16:38:29 +05:00
unknown
56a6c1d04d Merge gleb.loc:/home/uchum/work/bk/5.1
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-08-21 16:16:50 +05:00
unknown
5f40dafcd3 Fixed 5.0 -> 5.1 merge 2007-08-20 17:50:42 -06:00
unknown
8d201090f4 Merge weblab.(none):/home/marcsql/TREE/mysql-5.0-runtime
into  weblab.(none):/home/marcsql/TREE/mysql-5.1-rt50-merge


mysql-test/r/handler_myisam.result:
  Auto merged
mysql-test/r/query_cache.result:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
sql/lock.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
mysql-test/include/handler.inc:
  Auto merged
2007-08-20 16:13:54 -06:00
unknown
92838cc448 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2007-08-18 00:36:18 -06:00
unknown
4f3c8e7723 Bug #29307: status.test fails with different Table_locks_immediate
When using --log --log-output=table, we increment Table_locks_immediate
with every query.  The wait_condition.inc runs a query a variable number
of times, depending on server load, etc.  This is a problem, when the
test is checking the Table_locks_immediate value.

Fix is to adjust the Table_locks_immediate value based on how many times
the wait_condition query was executed.


mysql-test/include/wait_condition.inc:
  Add a $wait_condition_reps variable, which lets the caller check how
  many times the wait_condition query was executed.
  
  This is used in the main.status test to adjust the value of
  Table_locks_immediate (it gets incremented with each query
  when --log --log-output=table).
mysql-test/t/status.test:
  Adjust Table_locks_immediate value based on how many times the
  wait_condition query had to run.
2007-08-17 19:29:08 -06:00
unknown
eea647b5d2 Merge linux-st28.site:/home/martin/mysql/src/bug28570/my50-bug28570
into  linux-st28.site:/home/martin/mysql/src/bug28570/my51-bug28570


sql/opt_range.cc:
  Auto merged
mysql-test/include/mix1.inc:
  Bug#28570: Hand merged test case
mysql-test/r/innodb_mysql.result:
  Bug#28570: Hand merged test result
sql/handler.cc:
  Bug#28570: Hand merged file
2007-08-15 12:03:11 +02:00
unknown
d287334638 Merge jmiller@bk-internal.mysql.com:/home/bk/mysql-5.1-new-rpl
into  mysql.com:/data2/mysql-5.1-new-rpl-30128-30209
2007-08-11 00:08:00 +02:00
unknown
d30181e16c rpl_packet.test:
Changed patch to Mats suggestion from review. Patch is for Bug#30209
.del-wait_for_slave_running_off.inc:
  Delete: mysql-test/include/wait_for_slave_running_off.inc


BitKeeper/deleted/.del-wait_for_slave_running_off.inc:
  Delete: mysql-test/include/wait_for_slave_running_off.inc
mysql-test/suite/rpl/t/rpl_packet.test:
  Changed patch to Mats suggestion
2007-08-11 00:07:11 +02:00
unknown
7a9b90ce09 Merge mysql_cab_desk.:C:/source/c++/mysql-5.1-new-rpl
into  mysql_cab_desk.:C:/source/c++/mysql-5.1_BUG_22086


sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/rpl_utility.cc:
  Auto merged
sql/rpl_utility.h:
  Auto merged
2007-08-10 14:58:46 -04:00
unknown
9ad300d50d BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash
This patch adds functionality to row-based replication to ensure the
slave's column sizes are >= to that of the master.

It also includes some refactoring for the code from WL#3228.


mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  Removed commented out portion of test referenced in bug report. This
  test supports the original request of the bug report.
mysql-test/suite/rpl/r/rpl_extraCol_innodb.result:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  New result file for additional test.
mysql-test/suite/rpl/r/rpl_extraCol_myisam.result:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  New result file for additional test.
mysql-test/suite/rpl_ndb/r/rpl_ndb_extraCol.result:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  New result file for additional test.
sql/field.cc:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch refactors the additions made by this bug patch and those
  made by WL#3228. The effort consolidates the large switches on type()
  into functions within the field classes.
sql/field.h:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch refactors the additions made by this bug patch and those
  made by WL#3228. The effort consolidates the large switches on type()
  into functions within the field classes.
sql/log_event.cc:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch refactors the calc_field_size() method to use the new
  methods implemented in the field classes. It also corrects comments 
  concerning how replication of field metadata works.
sql/log_event.h:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch refactors out the calc_field_size() method into the method
  save_field_metadata().
sql/rpl_utility.cc:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch adds a method to check the size of the field on the master 
  using the field metadata from WL#3228. Each column is checked to ensure 
  the slave's column is >= to the master's column in size.
sql/rpl_utility.h:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  This patch changes the table_def class so that it records the size of
  the metadata. This is a result of refactoring out the calc_field_size()
  method into the method save_field_metadata(). Prevents access via 
  field_metadata(col) to unitialized memory when there is no metadata
  transmitted from the master.
mysql-test/suite/rpl/r/rpl_row_colSize.result:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  New result file for additional test.
mysql-test/suite/rpl/t/rpl_row_colSize.test:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  Added a test file to test each variable type that relies on field
  metadata from the master.
mysql-test/include/test_fieldsize.inc:
  BUG#22086 : Extra Slave Col: Char(5) on slave and Char(10) on master cause mysqld crash 
  
  Sub unit file to test each variable type that relies on field
  metadata from the master.
2007-08-10 12:48:01 -04:00
unknown
5dfb186178 rpl_packet.test:
Updated test to use new include function
wait_for_slave_running_off.inc:
  Created new include to resolve the timing issue recorded by Bug#30209
rpl_events.inc:
  The issue shown in Bug#30128 is that 'from er' shows up in a part of the test that it should not show up in. This event really is not created until later in the test, yet since the test runs row and then turns around and runs statement, I am guessing that the first run may not have cleaned up like it should, so I am adding a sync with master after the drop of table t1 to ensure that both master and slave are clean.


mysql-test/suite/rpl/t/rpl_packet.test:
  Updated test to use new include function
mysql-test/include/wait_for_slave_running_off.inc:
  Created new include to resolve the timing issue recorded by Bug#30209
mysql-test/include/rpl_events.inc:
  The issue shown in Bug#30128 is that 'from er' shows up in a part of the test that it should not show up in. This event really is not created until later in the test, yet since the test runs row and then turns around and runs statement, I am guessing that the first run may not have cleaned up like it should, so I am adding a sync with master after the drop of table t1 to ensure that both master and slave are clean.
2007-08-09 23:18:44 +02:00
unknown
9eea112d9d Merge mysql_cab_desk.:C:/source/c++/mysql-5.1
into  mysql_cab_desk.:C:/source/c++/mysql-5.1-new-rpl-merge


mysql-test/lib/mtr_report.pl:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/log_event.cc:
  Auto merged
mysql-test/suite/rpl/r/rpl_row_create_table.result:
  Merge with 5.1 main.
2007-08-02 15:27:47 -04:00
unknown
48eb7f8c85 Merge 50 -> 51 (-opt changesets)
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sp_rcontext.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
mysql-test/include/read_many_rows.inc:
  Manual merge
mysql-test/r/read_many_rows_innodb.result:
  Manual merge
sql/sql_class.cc:
  Manual merge
sql/sql_class.h:
  Manual merge
storage/innobase/handler/ha_innodb.cc:
  Manual merge
2007-08-01 18:59:41 -06:00
unknown
4ea92b81a7 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51


mysql-test/include/mix1.inc:
  Auto merged
mysql-test/r/innodb_mysql.result:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
2007-08-01 18:15:24 -06:00
unknown
82fbe7a418 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/jul31/51


mysql-test/r/federated.result:
  Auto merged
mysql-test/t/federated.test:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
storage/federated/ha_federated.h:
  Auto merged
storage/innobase/handler/ha_innodb.cc:
  Auto merged
mysql-test/include/mix1.inc:
  Manual merge
mysql-test/r/innodb_mysql.result:
  Manual merge
2007-07-31 17:36:19 -06:00
unknown
2914bad6ac Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into  bodhi.(none):/opt/local/work/mysql-5.1-runtime


client/mysqldump.c:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
mysql-test/t/mysqldump.test:
  Auto merged
sql/handler.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
mysql-test/include/mix1.inc:
  Manual merge.
mysql-test/r/innodb_mysql.result:
  Manual merge.
2007-07-31 23:47:38 +04:00
unknown
4c11e05ad2 Merge bodhi.(none):/opt/local/work/mysql-5.0-runtime
into  bodhi.(none):/opt/local/work/mysql-5.1-runtime


sql/mysql_priv.h:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
mysql-test/include/mix1.inc:
  Manual merge.
mysql-test/r/innodb_mysql.result:
  Manual merge.
sql/handler.h:
  Manual merge.
sql/lock.cc:
  Manual merge.
sql/opt_range.cc:
  Manual merge.
sql/sql_base.cc:
  Manual merge.
sql/sql_table.cc:
  Manual merge.
2007-07-31 20:00:05 +04:00
unknown
f5ef5cb0af WL#3228 (RBR using different table defs on slave/master):
Fixing tests and results to work when replicating to fewer columns on
slave than on master. One test that previously should fail, now works,
and some log positions have changed as a result of adding metadata to
the events.


mysql-test/extra/rpl_tests/rpl_row_tabledefs.test:
  Replication to fewer columns on slave now works.
mysql-test/include/wait_for_slave_to_stop.inc:
  Adding subsitutions for SHOW SLAVE STATUS
mysql-test/suite/binlog/r/binlog_row_binlog.result:
  Result change.
mysql-test/suite/rpl/r/rpl_rbr_to_sbr.result:
  Result change.
mysql-test/suite/rpl/r/rpl_row_tabledefs_2myisam.result:
  Result change.
mysql-test/suite/rpl/r/rpl_row_tabledefs_3innodb.result:
  Result change.
mysql-test/suite/rpl/r/rpl_slave_skip.result:
  Result change.
mysql-test/suite/rpl/t/rpl_skip_error-slave.opt:
  Error number changed [!]
2007-07-30 13:32:15 +02:00