Commit graph

31805 commits

Author SHA1 Message Date
Sergei Golubchik
3e9446a742 SHA1 service
(because mysql_ssl library is built with -fvisibility=hidden)
2013-07-13 17:48:06 +02:00
Sergei Golubchik
7da16844ea fix the maria suite
sql/handler.h:
  not "unused"
sql/sql_table.cc:
  move this check where it is in 10.0
2013-07-12 23:07:32 +02:00
Sergei Golubchik
590ba32747 federated.partition test - fix the bad merge 2013-07-12 19:58:06 +02:00
Sergei Golubchik
487b3ba742 binlog_old_versions.test 2013-07-12 17:40:20 +02:00
Sergei Golubchik
ee8195a731 fix lost vcol checks in sql_table.cc,
remove unused FIELD_IS_xxx flags
change vcol tests to use innodb, not xtradb.
2013-07-12 13:32:37 +02:00
Sergei Golubchik
f672d6b7d8 restore ha_example::check_if_incompatible_data(), create_info->fields_option_struct,
create_info->indexes_option_struct lost in the merge.
add test cases.
2013-07-12 11:36:54 +02:00
unknown
f4d5dacf43 Merge the following patch from MySQL 5.6.10, in order to make perfschema.binlog_* tests work.
revno: 4559
committer: Marc Alff <marc.alff@oracle.com>
branch nick: mysql-5.6-bug14741537-v4
timestamp: Thu 2012-11-08 22:40:31 +0100
message:
  Bug#14741537 - MYSQL 5.6, GTID AND PERFORMANCE_SCHEMA
  
  Before this fix, statements using performance_schema tables:
  - were marked as unsafe for replication,
  - did cause warnings during execution,
  - were written to the binlog, either in STATEMENT or ROW format.
  
  When using replication with the new GTID feature,
  unsafe warnings are elevated to errors,
  which prevents to use both the performance_schema and GTID together.
  
  The root cause of the problem is not related to raising warnings/errors
  in some special cases, but deeper: statements involving the performance
  schema should not even be written to the binary log in the first place,
  because the content of the performance schema tables is 'local' to a server
  instance, and may differ greatly between nodes in a replication
  topology.
  
  In particular, the DBA should be able to configure (INSERT, UPDATE, DELETE)
  or flush (TRUNCATE) performance schema tables on one node,
  without affecting other nodes.
  
  This fix introduces the concept of a 'non-replicated' or 'local' table,
  and adjusts the replication logic to ignore tables that are not replicated
  when deciding if or how to log a statement to the binlog.
  
  Note that while this issue was detected using the performance_schema,
  other tables are also affected by the same problem.
  
  This fix define as 'local' the following tables, which are then never
  replicated:
  - performance_schema.*
  - mysql.general_log
  - mysql.slow_log
  - mysql.slave_relay_log_info
  - mysql.slave_master_info
  - mysql.slave_worker_info
  
  Existing behavior for information_schema.* is unchanged by this fix,
  to limit the scope of changes.
  
  Coding wise, this fix implements the following changes:
  
  1)
  
  Performance schema tables are not using any replication flags,
  since performance schema tables are not replicated.
  
  2)
  
  In open_table_from_share(),
  tables with no replication capabilities (performance_schema.*),
  tables with TABLE_CATEGORY_LOG (logs)
  and tables with TABLE_CATEGORY_RPL_INFO (replication)
  are marked as non replicated, with TABLE::no_replicate
  
  3)
  
  A new THD member, THD::m_binlog_filter_state,
  indicate if the current statement is written to the binlog
  (normal cases for most statements), or is to be discarded
  (because the statements affects non replicated tables).
  
  4)
  
  In THD::decide_logging_format(), the replication logic
  is changed to take into account non replicated tables.
  
  Statements that affect only non replicated tables are
  executed normally (no warning or errors), but not written
  to the binlog.
  
  Statements that affect (i.e., write to) a replicated table
  while also using (i.e., reading from or writing to) a non replicated table
  are executed normally in MIXED and ROW binlog format,
  and cause a new error in STATEMENT binlog format.
  
  THD::decide_logging_format() uses THD::m_binlog_filter_state
  to indicate if a statement is to be ignored, when writing to
  the binlog.
  
  5)
  
  In THD::binlog_query(), statements marked as ignored
  are not written to the binary log.
  
  6)
  
  For row based replication, the existing test for 'table->no_replicate',
  has been moved from binlog_log_row() to check_table_binlog_row_based().
2013-07-11 21:23:55 +03:00
Sergei Golubchik
3cd1861a81 merge bugfuxes for sp-error.test 2013-07-12 10:17:52 +02:00
Sergei Golubchik
4d57bfdd48 temporal-related changes. don't apply sql_mode flags on the lower level (str_to_datetime),
do it on the upper level, in items that return temporal values.

update tests results to match 5.6 better and to fix old bugs.
2013-07-11 23:16:33 +02:00
Sergei Golubchik
bcbdf5d68a fix signal_demo3.test: fix a typo in the merge, and update results to match 5.6 2013-07-11 21:40:30 +02:00
Sergei Golubchik
bb672474cc remove unused function 2013-07-11 14:10:44 +02:00
Sergei Golubchik
2f14d5747e fix alter_table.test: remove old assert as it was removed from 5.6,
add extra_func code from 5.5, that was lost in a merge
2013-07-11 14:08:51 +02:00
unknown
b8d9889e80 added lost part about preopened temporary tables 2013-07-11 16:27:57 +03:00
Sergei Golubchik
b9b41a5fb0 fix plugin.test - bad merge in TABLE_SHARE::destroy, ha_share must be deleted before the plugin 2013-07-10 20:11:01 +02:00
Sergei Golubchik
d641028ff5 fix func_time.test - WEEK(), WEEKDAY(), WEEKOFYEAR() must require TIME_NO_ZERO_IN_DATE 2013-07-10 19:22:19 +02:00
Sergei Golubchik
899d0ad421 fix status.test - don't use lock_tables_precheck() for SHOW PROC STATUS,
it shouldn't require LOCK_TABLE_ACL
2013-07-10 18:58:34 +02:00
Sergei Golubchik
4620c7af60 clearly mark unused error messages as such 2013-07-10 13:34:07 +02:00
Sergei Golubchik
0ce9391008 fix for alter_table_online test.
Map ALTER ONLINE TABLE to ALTER TABLE ... ALGORITHM=INPLACE.
Make MERGE engine to announce its support of inplace operations.
2013-07-10 12:48:56 +02:00
Sergei Golubchik
e06cc1adce MDEV-4758 10.0-monty tree: ALTER TABLE CHANGE COLUMN doesn't drop EITS stats
add missing rename_column_in_stat_tables(), delete_statistics_for_column(),
delete_statistics_for_index(), rename_table_in_stat_tables() calls.
2013-07-09 22:36:53 +02:00
Sergey Petrunya
56a6e71f9c Fix merge.test failure
- Problem: mysql_admin_table() calls open_temporary_tables(). This 
  causes assertion failure, because mysql_execute_command() has 
  already called open_temporary_tables()
- Solution: call close_thread_tables() at the start of 
  mysql_admin_table(), like mysql-5.6 does
2013-07-09 15:42:36 +04:00
Sergey Petrunya
eb288af54d Automatic merge 2013-07-08 20:45:02 +04:00
Igor Babaev
f1848be746 Fixed a failure in partition_truncate.test. 2013-07-08 12:55:11 -07:00
Sergey Petrunya
c3e70a0104 Fix assert failures in main.merge test (line 234) and main.merge_mmap (line 44)
- After the merge from mysql-5.6, open_tables() did not call
  open_and_process_table() for temporary table. The logic was that temporary
  tables were already opened when mysql_execute_command() has called 
  open_temporary_tables().
  This worked for the most part, except for temporary tables of type MERGE. for
  which open_and_process_table() must call 
    table->file->extra(HA_EXTRA_ADD_CHILDREN_LIST).
  Failure to make this call resulted in crash further in execution.

  tables->table->file->extra(HA_EXTRA_ADD_CHILDREN_LIST)
2013-07-08 20:21:27 +04:00
Sergey Petrunya
964d42631c Fix test failure in myisam.test:
- Put back the code tht produces the warning about 
  "Table storage engine %s does not support the create option 'TRANSACTIONAL=1'"
2013-07-08 18:14:24 +04:00
Sergey Petrunya
97d125084d Automatic merge 2013-07-08 12:59:50 +04:00
unknown
54999b2863 Merge performance schema test cases from MySQL 5.6.10
Merged the majority of the PFS test cases.
There are still 19 failing test cases that need more attention.
2013-07-08 15:19:50 +03:00
Sergey Petrunya
50dda403b7 Fix test errors like:
-Note 1031 Table storage engine for 't1' doesn't have this option
+Note 1031 Table storage engine for 'InnoDB' doesn't have this option

They were caused by a change in MariaDB which changed ER_ILLEGAL_HA message 
text to be like:
"Storage engine InnoDB of the table `test`.`t1` doesn't have this option"

Some the error calls were changed to pass new parameters, but some were left
to be old. Also the error text in errmsg-ut8.txt was not changed.
2013-07-08 12:57:58 +04:00
unknown
928b21a93c The compiler warning about ';' fix. 2013-07-08 09:50:18 +03:00
Sergey Petrunya
dd7c52d19e Merge from mysql-5.6 fix for bug#11761752 (was already partially merged) 2013-07-05 19:40:34 +04:00
Sergey Petrunya
1b3a5deec5 Fix limit_rows_examined.test:
- Take into account that Dynamic_array::back() now returns 
  pointer to the last element (it used to return pointer to 
  right after the last element)
- Fix error messages merge: ER_INTERNAL_ERROR was defined 
  independently by both mysql-5.6 and mariadb-5.5. Switch 
  to their error number, and still support ours for compatibility.
2013-07-05 15:25:01 +04:00
Sergey Petrunya
f2fcd7bdbc Fix compile error on Windows 2013-07-05 15:20:39 +04:00
unknown
f231edcda3 fixed opening temporary tables. 2013-07-05 16:58:37 +03:00
Sergey Petrunya
8448c68705 Fix trivial compile failures observed in buildbot 2013-07-05 13:56:05 +04:00
Sergey Petrunya
87990b62be Fix type_newdecimal.test: Warning was produced instead of NOTE. The cause was typo in the merge. 2013-07-05 09:53:18 +04:00
Sergey Petrunya
77584dd6d7 MDEV-4756: 10.0-monty tree: log_state.test fails
- make the test output stable
- make Log_to_csv_event_handler::log_slow() to write the value 
  of thd->thread_id (it didn't, and so 0 was always logged).
2013-07-04 15:45:58 +04:00
unknown
6135585efa fixed typo. 2013-07-04 10:39:19 +03:00
Michael Widenius
8ad34c8f9e Automatic merge 2013-07-03 22:57:13 +03:00
Michael Widenius
a9d1d76e5e Fixed issues with partitions and create temporary table SELECT ...
Merged all ddl_logging code.
Merged sql_partition.cc
innodb_mysql_lock2.test and partition_cache.test now works.
Changed interface to strconvert() to make it easier to use with not \0 terminated strings.

sql/sql_partition.cc:
  Full merge with 5.6
sql/sql_table.cc:
  Merged all ddl_logging code
sql/strfunc.cc:
  Added from_length argument to strconvert() to make it possible to use without end terminated strings.
sql/strfunc.h:
  Added from_length argument to strconvert() to make it possible to use without end terminated strings.
2013-07-03 22:50:34 +03:00
unknown
5f0d489da8 MDEV-4058
MySQL 5.6.10 performance schema: merge of the test files for the host_cache table
2013-07-03 12:19:03 +03:00
Michael Widenius
82a0b8ae30 strict.test now works. 2013-07-02 22:11:12 +03:00
Michael Widenius
99aae21ed2 mdl_sync now works.
mysql-test/r/mdl_sync.result:
  Full merge with 5.6
mysql-test/t/mdl_sync.test:
  Full merge with 5.6
sql/debug_sync.cc:
  Full merge with 5.6
sql/debug_sync.h:
  Full merge with 5.6
sql/mdl.cc:
  Full merge with 5.6
sql/sql_base.cc:
  Removed code not in 5.6 anymore
2013-07-02 20:43:35 +03:00
unknown
b7b2a7ce81 Pull of revision 3313 (Pre-requisite patch for Bug#11763162 (55843 - Handled condition
appears as not handled) fixed.
2013-07-02 16:44:53 +03:00
Michael Widenius
ecf9b1b754 Fixed some wrong format strings.
Fixed OPTIMIZE with innodb


include/my_sys.h:
  Removed ATTRIBUTE_FORMAT() as it gave warnings for %'s
sql/log_event.cc:
  Optimization: 
  use my_b_write() and my_b_write_byte() instead of my_b_printf()
  use strmake() instead of my_snprintf()
sql/sql_admin.cc:
  Fixed bug in admin_recreate_table()
  Fixed OPTIMIZE with innodb
sql/sql_table.cc:
  Indentation fixes
strings/my_vsnprintf.c:
  Changed fprintf() to fputs()
2013-06-28 01:53:41 +03:00
unknown
70092601bc merge of 2876.430.11 & 2876.430.1
CF_PREOPEN_TMP_TABLES & CF_HA_CLOSE & Patch for Bug#11746602 (27480: Extend CREATE TEMPORARY TABLES 
  privilege to allow temp table operations).
2013-06-27 17:42:18 +03:00
Michael Widenius
94d722b6a4 ha_partition.cc and ha_partition.h are now completely merged
Added sql_mode_t to simplify merges
2013-06-27 14:01:03 +03:00
unknown
ecbf36a914 MDEV-4058
MySQL 5.6.10 performance schema: merge of host_cache table
2013-06-27 12:51:34 +03:00
unknown
e7606294b2 A fix of unions with duplicate rows and returning bug fix for lp:732124 union + limit returns wrong result 2013-06-26 13:17:27 +03:00
Igor Babaev
68929e8e3f Some corrections of the merge for the partition code. 2013-06-25 18:55:12 -07:00
Michael Widenius
5f4e0e8767 Don't update table and index statics for temporary tables
Fixed type and testing of last_update type for innodb_table_stats

mysql-test/r/connect.result:
  Removed tables which are not created anymore
sql/item_sum.h:
  Fixed typo
sql/sql_base.cc:
  Don't update table and index statics for temporary tables
sql/sys_vars.cc:
  Merge
storage/innobase/dict/dict0stats.cc:
  Fixed type last_update to TIMESTAMP.
2013-06-22 18:47:12 +03:00
unknown
1f08a51858 Case when we close temporary table which was not opened in its engine (ALTER TABLE) fixed. 2013-06-21 15:17:48 +03:00