Commit graph

171605 commits

Author SHA1 Message Date
Kristian Nielsen
6a92fa4be5 Merge branch 'mdev8294' into 10.1 2015-06-15 08:28:04 +02:00
Kristian Nielsen
93c039dd3c MDEV-8294: Inconsistent behavior of slave parallel threads at runtime
Follow-up patch to temporarily avoid a sporadic failure in the test
rpl.rpl_000011 due to MDEV-8301.

There is a window during thread exit where the global status is
counted incorrectly - the contribution for the exiting thread is
counted twice. The patch for MDEV-8294 made this window visible to the
test case rpl.rpl_000011, causing it to sporadically fail. Temporarily
silence this with a wait for the expected value; can be removed once
MDEV-8294 is fixed.
2015-06-15 08:13:40 +02:00
Kristian Nielsen
b1b0db294f Merge MDEV-8294 into 10.1 2015-06-10 12:42:18 +02:00
Kristian Nielsen
682ed005c5 MDEV-8294: Inconsistent behavior of slave parallel threads at runtime
There were some cases where the slave SQL thread could stop without
the pool of parallel replication worker threads being correctly
de-activated.
2015-06-10 11:57:42 +02:00
Nirbhay Choubey
f965cae5fb MDEV-7110 : Add missing MySQL variable log_bin_basename and log_bin_index
Add log_bin_index, log_bin_basename and relay_log_basename system
variables. Also, convert relay_log_index system variable to
NO_CMD_LINE and implement --relay-log-index as a command line
option.
2015-06-09 13:38:29 -04:00
Alexander Barkov
c94789c3d3 Adding a test for:
MDEV-8167 XOR returns bad results for an indexed column
The bug itself was earlier fixed by one of the earlier changes.
2015-06-09 15:35:25 +04:00
Alexander Barkov
b0928711e0 Adding a test for "MDEV-6973 XOR aggregates argument collations".
The bug itself was earlier fixed by this patch:

commit 3709c7fc6d
MDEV-8222 "string_field LIKE int_const" returns a wrong result in case of UCS2
MDEV-8257 Erroneous "Impossible where" when mixing decimal comparison and LIKE
2015-06-09 15:02:53 +04:00
Jan Lindström
70b82efd20 MDEV-8273: InnoDB: Assertion failure in file fil0pagecompress.cc line 532
Analysis: Problem was that actual payload size (page size) after compression
was handled incorrectly on encryption. Additionally, some of the variables
were not initialized.

Fixed by encrypting/decrypting only the actual compressed page size.
2015-06-09 11:35:21 +03:00
Jan Lindström
4a6a61cb81 MDEV-8268: InnoDB: Assertion failure in file buf0buf.cc line 5842 failing assertion ut_a(free_slot != NULL);
Analysis: Problem is that there is not enough temporary buffer slots
for pending IO requests.

Fixed by allocating same amount of temporary buffer slots as there
are max pending IO requests.
2015-06-09 11:35:21 +03:00
Jan Lindström
d7f3d889de MDEV-8272: Encryption performance: Reduce the number of unused memcpy's
Removed memcpy's on cases when page is not encrypted and make sure
we use the correct buffer for reading/writing.
2015-06-09 11:35:21 +03:00
Alexander Barkov
f744b2a15f MDEV-8283 crash in get_mm_leaf with xor on binary col 2015-06-09 12:08:46 +04:00
Sergei Petrunia
93fc04ff1d MDEV-6995: EXPLAIN JSON and ORDER BY, GROUP BY, etc
- Make ANALYZE correctly remember and report filesort() calls
- Temp.table use is collected but only basic info is reported.
2015-06-06 00:32:27 +03:00
Jan Lindström
f7002c05ae MDEV-8250: InnoDB: Page compressed tables are not compressed and compressed+encrypted tables cause crash
Analysis: Problem is that both encrypted tables and compressed tables use
FIL header offset FIL_PAGE_FILE_FLUSH_LSN_OR_KEY_VERSION to store
required metadata. Furhermore, for only compressed tables currently
code skips compression.

Fixes:
- Only encrypted pages store key_version to FIL header offset FIL_PAGE_FILE_FLUSH_LSN_OR_KEY_VERSION,
  no need to fix
- Only compressed pages store compression algorithm to FIL header offset FIL_PAGE_FILE_FLUSH_LSN_OR_KEY_VERSION,
  no need to fix as they have different page type FIL_PAGE_PAGE_COMPRESSED
- Compressed and encrypted pages now use a new page type FIL_PAGE_PAGE_COMPRESSED_ENCRYPTED and
  key_version is stored on FIL header offset FIL_PAGE_FILE_FLUSH_LSN_OR_KEY_VERSION and compression
  method is stored after FIL header similar way as compressed size, so that first
  FIL_PAGE_COMPRESSED_SIZE is stored followed by FIL_PAGE_COMPRESSION_METHOD
- Fix buf_page_encrypt_before_write function to really compress pages if compression is enabled
- Fix buf_page_decrypt_after_read function to really decompress pages if compression is used
- Small style fixes
2015-06-04 09:47:06 +03:00
Sergei Golubchik
cd70bed05e fix for 32-bit tests 2015-06-03 11:12:50 +02:00
Sergei Golubchik
51d67633ef AES-GCM support in file_key_management plugin 2015-06-02 19:00:23 +02:00
Sergei Golubchik
0f0092720f my_aes_encrypt_gcm() and my_aes_decrypt_gcm() 2015-06-02 19:00:23 +02:00
Sergei Golubchik
ebc5e00641 my_aes_get_size()
return unsigned, not signed.
return a value large enough for GCM
2015-06-02 19:00:23 +02:00
Sergei Golubchik
487e5f4590 file_key_management plugin: complain if key id 1 is not found
and don't recommend aes_ctr if it's unavailable
2015-06-02 19:00:23 +02:00
Sergei Golubchik
432b78c903 just like tempfiles: use key id 2 for temp Aria tables
introduce ENCRYPTION_KEY_SYSTEM_DATA and
ENCRYPTION_KEY_TEMPORARY_DATA constants; use them everywhere.
2015-06-02 18:53:37 +02:00
Sergei Golubchik
d9340d6c8e MDEV-8126 encryption for temp files
IO_CACHE tempfiles encryption
2015-06-02 18:53:37 +02:00
Sergei Golubchik
318c826e93 always use my_b_pread() instead of mysql_file_pread()
when working with IO_CACHE's, don't access IO_CACHE::file directly
2015-06-02 18:53:37 +02:00
Sergei Golubchik
6309a30dc9 my_b_fill, inline my_b_* functions instead of hairy macros 2015-06-02 18:53:37 +02:00
Sergei Golubchik
196e852983 misc IO_CACHE cleanups
* remove unused (and not implemented) WRITE_NET type
* remove cast in my_b_write() macro. my_b_* macros are
  function-like, casts are responsibility of the caller
* replace hackish _my_b_write(info,0,0) with the explicit
  my_b_flush_io_cache() in my_b_write_byte()
* remove unused my_b_fill_cache()
* replace pbool -> my_bool
* make internal IO_CACHE functions static
* reformat comments, correct typos, remove obsolete comments (ISAM)
* assert valid cache type in init_functions()
* use IO_ROUND_DN() macro where appropriate
* remove unused DBUG_EXECUTE_IF in _my_b_cache_write()
* remove unnecessary __attribute__((unused))
* fix goto error in parse_file.cc
* remove redundant reinit_io_cache() in uniques.cc
* don't do reinit_io_cache() if the cache was not initialized
  in ma_check.c
* extract duplicate functionality from various _my_b_*_read
  functions into a common wrapper. Same for _my_b_*_write
* create _my_b_cache_write_r instead of having if's in
  _my_b_cache_write (similar to existing _my_b_cache_read and
  _my_b_cache_read_r)
* don't call mysql_file_write() from my_b_flush_io_cache(),
  call info->write_function() instead
2015-06-02 18:53:37 +02:00
Sergei Golubchik
1841557e40 myisam/aria: don't mess with IO_CACHE::file
that is, don't create a "temporary" IO_CACHE with file==-1
and manually swap it later to the valid file descriptor.
2015-06-02 18:53:36 +02:00
Sergei Golubchik
80e61ae21e cleanup: LOAD DATA replication support in IO_CACHE
remove some 14-year old code that added support for
LOAD DATA replication to IO_CACHE:
* three callbacks, of which only two were actually used and that
  were only needed for LOAD DATA replication but were
  tested in every IO_CACHE instance
* an additional opaque void * argument in IO_CACHE, also only
  used for LOAD DATA replication, but present everywhere
* the code to close IO_CACHE prematurely in LOAD DATA to have
  these callbacks called in the correct order and a long
  comment explaining what will happen if IO_CACHE is not
  closed prematurely
* a variable to track whether IO_CACHE was closed prematurely
  (to avoid double-closing it)
2015-06-02 18:53:36 +02:00
Sergei Golubchik
91dab5ddb6 fix cmake dependencies
perfschema after 5.6 merge depends on sql_yacc.h
2015-06-02 18:09:53 +02:00
Sergei Golubchik
72d01f2426 remove few #ifdefs in innodb/xtradb 2015-06-02 17:46:05 +02:00
Sergey Vojtovich
5fc53b7cfe MDEV-8202 - st_select_lex::master_unit() takes 0.17% in OLTP RO
To make st_select_lex::master_unit() inlinable:
- moved it's definition to sql_lex.h
- removed base class virtual master_unit() declaration since this method is
  specific to st_select_lex

Overhead change:
st_select_lex::master_unit()      0.17% -> out of radar
execute_sqlcom_select()           0.13% -> 0.12%
JOIN::save_explain_data_intern()  0.27% -> 0.23%
JOIN::optimize_inner()            0.76% -> 0.72%
JOIN::exec_inner()                0.30% -> 0.24%
JOIN::prepare()                   0.30% -> 0.29%
JOIN::optimize()                  0.05% -> 0.05%
2015-06-02 18:02:32 +04:00
Sergey Vojtovich
adb952f548 MDEV-8192 - THD::set_command() takes 0.05% in OLTP RO
Moved THD::set_command() definition to sql_class.h so that it can be inlined.

Overhead change:
THD::set_command        0.05% -> out of radar
2015-06-02 18:02:32 +04:00
Sergey Vojtovich
d298b02233 MDEV-8191 - THD::set_query() takes 0.07% in OLTP RO
Moved THD::set_query() definition to sql_class.h so that it can be inlined.

Overhead change:
THD::set_query       0.07% -> out of radar
2015-06-02 18:02:32 +04:00
Alexander Barkov
3709c7fc6d MDEV-8222 "string_field LIKE int_const" returns a wrong result in case of UCS2
MDEV-8257 Erroneous "Impossible where" when mixing decimal comparison and LIKE
2015-06-02 15:42:01 +04:00
Sergei Golubchik
8f92a70e21 update for 32-bit, again 2015-06-02 09:26:16 +02:00
Sergei Golubchik
0d54cb12eb compilation failure on windows 2015-06-01 21:35:02 +02:00
Sergei Golubchik
2133230305 avoid ulong sysvars, prefer uint or ulonglong
ulong is not portable - different width on different architectures
2015-06-01 21:31:31 +02:00
Sergei Golubchik
78c10ccad8 MDEV-7913 main.openssl_6975 'tlsv10' fails in buildbot on Wheezy and Precise
version_ssl_library should show the version
of openssl library that is being used, not the one
that server was compiled with.
2015-06-01 17:31:39 +02:00
Sergei Golubchik
9c41b35b6a MDEV-8220 Server crashes if started with --enforce-storage-engine option 2015-06-01 16:33:41 +02:00
Sergei Golubchik
d602574542 Merge remote-tracking branch 'github/10.1' into 10.1 2015-06-01 16:01:42 +02:00
Sergei Golubchik
fce4ab0ab4 generalize ER_TABLE_NEEDS_UPGRADE to work for views too 2015-06-01 16:01:23 +02:00
Sergei Golubchik
5091a4ba75 Merge tag 'mariadb-10.0.19' into 10.1 2015-06-01 15:51:25 +02:00
Jan Lindström
528378920b Fix test warnings by adding global supression to InnoDB warnings. 2015-05-31 08:10:07 +03:00
Jan Lindström
13235a549d Fix compiler warning. 2015-05-31 07:53:20 +03:00
Jan Lindström
59815a268b MDEV-7484: Log Time not consistent with InnoDB errors nor with MySQL error log time format 2015-05-30 20:45:17 +03:00
Sergei Golubchik
84eaf0911f MDEV-7913 main.openssl_6975 'tlsv10' fails in buildbot on Wheezy and Precise
don't run this test on 1.0.1c
2015-05-30 14:06:31 +02:00
Vicențiu Ciorbaru
3839e91223 MDEV-8248: mysqldump incorrect identifier quoting during equality comparison
Use quote_for_equal to correctly escape characters.
2015-05-30 13:15:05 +03:00
Vicențiu Ciorbaru
ae4b24340d MDEV-6714 mysqldump slow with tables in big databases
mysqldump now attempts to make use of the INFORMATION_SCHEMA tables.
If the table name is not found with a case sensitive search, it
fallbacks to a case insensitive search.
2015-05-30 13:15:04 +03:00
Sergei Golubchik
c6b4212821 temporarily disable failing test 2015-05-30 09:16:06 +02:00
Oleksandr Byelkin
0f01bf2676 MDEV-8241: Debug build on Windows is broken: error LNK2019: unresolved external symbol pthread_detach referenced in function ma_checkpoint_init
pthread_detach() replaced with pthread_detach_this_thread()

pthread_detach_this_thread() definition fixed
2015-05-29 23:07:49 +02:00
Sergei Golubchik
c1c22c043b update test results
(yes, we no longer add all variables to sys_vars suite!)
2015-05-29 21:23:52 +02:00
Nirbhay Choubey
903cfde149 MDEV-7067: Server outputs Galera (WSREP) information, even if Galera is disabled
* mysqld_safe: Since wsrep_on variable is mandatory in 10.1, skip wsrep
position recovery if its OFF.
* mysqld: Remove "-wsrep" from server version
* mysqld: Remove wsrep patch version from @@version_comment
* mysqld: Introduce @@wsrep_patch_version
2015-05-29 11:26:46 -04:00
Oleksandr Byelkin
1b00edc49a MDEV-7011: MAX_STATEMENT_TIME has no effect in a procedure after a previous successful statement
Do not reset timer inside stored procedures and functions.
2015-05-29 11:43:02 +02:00