Commit graph

139 commits

Author SHA1 Message Date
Sergei Petrunia
fd39f25ca7 MariaRocks: fix compilation on Oracle Linux Server 7.3.
#define __STDC_FORMAT_MACROS. Unfortunately there is no single location
that would be #includ'ed before everything else. Have to put the #define
into each .cc file
2017-03-10 14:05:17 +03:00
Vladislav Vaintroub
e19f1dd61e Fix build on Windows.
Remove some GCC specific pragmas, use #ifdef __GNUC__ in other places.
Only use  pthread_setname_np on Linux.
Fix a mismerge
2017-03-07 14:11:19 +00:00
Sergei Petrunia
f9e63b7c59 MariaRocks port: __PRETTY_FUNCTION__ is a gcc extension. Use __func__ when it is not available
For example, on Windows.
2017-03-07 11:38:26 +03:00
Sergei Petrunia
48a5dd945b MariaRocks: fix compilation on kvm-rpm-centos7-amd64
Define __STDC_FORMAT_MACROS before using PRIu64.
RocksDB does this in many files
2017-03-07 11:08:41 +03:00
Sergei Petrunia
e7948e34ee Fix the previous cset: use a proper disabled.def syntax 2017-03-06 23:59:29 +03:00
Sergei Petrunia
f080c93dcd MariaRocks: (Temporarily?) disable MTR tests that run RQG 2017-03-06 14:50:14 +03:00
Sergei Petrunia
ea5cc017e9 Test fixes in rocksdb_sys_vars test suite
- Get the suite to work with dynamically-linked plugin (ha_rocksdb.so)
- Due to the push to keep everything MyRocks-related in storage/rocksdb,
  there is no mysql-test/include/have_rocksdb.* anymore.
  Make a copy of storage/rocksdb/mysql-test/rocksdb/include/have_rocksdb*,
  hopefully these files wont be changed [often].
- Maria-fication of rocksdb_persistent_cache_path test.
2017-02-21 16:49:18 +03:00
Sergei Petrunia
e57ab94cce Update rocksdb submodule to match the rocksdb version used in upstream
This change should have been a part of
    Merge 'merge-myrocks' into 'bb-10.2-mariarocks'

    Merged cset:
        Copy of

        commit d1bb19b8f751875472211312c8e810143a7ba4b6

We probably should make submodule info a part of the mergetree process.
2017-02-21 03:51:09 +03:00
Sergei Petrunia
7d00f0981e Merge between local changes bb-10.2-mariarocks and the merge from upstream 2017-02-20 13:01:32 +00:00
Sergei Petrunia
5e47d08eb6 Merge 'merge-myrocks' into 'bb-10.2-mariarocks'
Merged cset:
    Copy of

    commit d1bb19b8f751875472211312c8e810143a7ba4b6
    Author: Manuel Ung <mung@fb.com>
    Date:   Fri Feb 3 11:50:34 2017 -0800
    ...

        Add cardinality stats to information schema
2017-02-19 16:29:01 +00:00
Sergei Petrunia
7facbc548d MariaRocks: fix a few tests
Test suite parameters for 'rocksdb' test suite were disabled in order
to get mysqld to start at all when ha_rocksdb is a dynamic plugin.

A lot of tests depend on these parameters being enabled, though. Put
them back by using the loose- form.
2017-02-19 18:51:26 +03:00
Vladislav Vaintroub
de49fd842a RocksDB : Add lookup / compiling with optional compression libraries.
This change add WITH_ROCKSDB_{LZ4,BZIP2,ZSTD,snappy} CMake variables
that can be set to ON/OFF/AUTO.

If variable has default value AUTO, rocksdb links with corresponding
compression library. OFF disables compiling/linking with specific compression
library, ON forces compiling with it (cmake would throw error if library
is not available)

Support for ZLIB is added unconditionally, as it is always there.
2017-02-09 16:55:02 +00:00
Vicențiu Ciorbaru
241e8a15a2 Ignore "invisible" files 2017-02-07 22:15:11 +02:00
Vicențiu Ciorbaru
e2f3739aa1 Ignore dynamically generated build_version.cc file 2017-02-07 22:15:05 +02:00
Vicențiu Ciorbaru
f46176cbef Make rocksdb build with clang
We need to provide -fPIC for ROCKSDB files as well as -frtti if we
compile with Clang
2017-02-07 22:14:59 +02:00
Vicențiu Ciorbaru
840f8eab71 Make mysql_ldb work on clang 2017-02-07 22:14:52 +02:00
Vicențiu Ciorbaru
884fd9ac2b Make RocksDB run git submodule init and update if rocksdb is not fetched 2017-02-07 22:14:44 +02:00
Sergei Petrunia
7468ccfadf Copy of
commit d1bb19b8f751875472211312c8e810143a7ba4b6
Author: Manuel Ung <mung@fb.com>
Date:   Fri Feb 3 11:50:34 2017 -0800

    Add cardinality stats to information schema

    Summary: This adds cardinality stats to the INFORMATION_SCHEMA.ROCKSDB_INDEX_FILE_MAP table. This is the only missing user collected properties from SST files that we don't expose, which is useful for debugging cardinality bugs.

    Reviewed By: hermanlee

    Differential Revision: D4509156

    fbshipit-source-id: 2d3918a
2017-02-06 17:39:08 +00:00
Vladislav Vaintroub
5875633c2a MDEV-11901 : MariaRocks on Windows
fixed compilation, disabled unix-only tests (the ones that use bash
etc).

Changed plugin library name to ha_rocksdb.dll/so
2017-02-01 21:27:13 +00:00
Sergei Petrunia
13c7839ba7 MariaRocks port: Fix for the previous cset (MariaRocks port: put back the assert)
- Put back the assert on SQL layer at the right location
- Adjust rdb_pack_with_make_sort_key to work around the assert (like
  it is done at other palaces):  MyRocks may need to pack a column
  value even when the column is not in the read set.
2017-01-24 21:51:57 +03:00
Vicențiu Ciorbaru
555b1b9f15 Make rocksdb dynamic plugin 2017-01-24 09:27:15 +02:00
Vicențiu Ciorbaru
024a5ec0ec Add ut0counter.h instead of xtradb linked ut0counter.h 2017-01-23 21:32:11 +02:00
Sergei Petrunia
1f0c28f36e MariaRocks port: move include/atomic_stat.h into storage/rocksdb 2017-01-21 22:58:57 +03:00
Sergei Petrunia
7fb3b348d7 MariaRocks port: Remove handler::init_with_fields
- It turns out, ha_rocksdb::table_flags() can return
  HA_PRIMARY_KEY_IN_READ_INDEX for all kinds of tables (as its meaning
  is "if there is a PK, PK columns contribute to the secondary index
  tuple". There is no assumption that a certain PK column can be decoded
  from the secondary index.
  (Should probably be fixed in the upstream, too, but I was unable to
   construct a testcase showing this is necessary).

- Following the above, we can undo the init_with_fields() changes in
  table.cc. MyRocks calls init_with_fields() from ha_rocksdb::open()
  which sets index-only read capabilities properly.
2017-01-21 22:58:04 +03:00
Sergei Petrunia
2d789dd9dd MariaRocks: fix a few tests in rocksdb_sys_vars test suite 2017-01-11 22:29:34 +03:00
Sergei Petrunia
1a8731952d MariaRocks port: get rocksdb_sys_vars.rocksdb_deadlock_detect_basic to work 2017-01-11 19:40:25 +03:00
Sergei Petrunia
80be676fc0 MariaRocks port
- Use rocksdb_sys_vars/my.cnf so that one can run tests from that suite
  by just  "./mtr rocksdb_sys_vars.$TESTNAME"
- Add rocksdb and rocksdb_sys_vars to the set of default test suites.
  Don't run with embedded server, yet.
2017-01-11 17:32:47 +03:00
Sergei Petrunia
edfe980aa1 MariaRocks port: fix rocksdb.rpl_row_stats test
"Userstat" feature in MariaDB does not have
I_S.table_statistics.rows_requested column.

We'll use I_S.table_statistics.rows_read instead. The testcase
doesn't do anything where rows_requested != rows_read.
2017-01-11 13:14:52 +03:00
Sergei Petrunia
f89e07785a MariaRocks port: Get rocksdb.autoinc_vars_thread test to work
MariaDB doesn't have NO_CLEAR_EVENT support in DEBUG_SYNC facility.
Luckily, the test can be re-written to use two different sync points
instead. (I've checked that the modified test fails with fb/mysql-5.6
without the fix for e004fd9f (PR #394)
2017-01-11 12:41:22 +03:00
Sergei Petrunia
520d206365 MariaRocks port: get rocksdb.rocksdb_icp[_rev] to work
- Fix the test cases to not use userstat counters specific to
  facebook/mysql-5.6
- Make testcase also check MariaDB's ICP counters
- Remove ha_rocksdb::check_index_cond(), call handler_index_cond_check
  instead.
2017-01-08 18:29:14 +00:00
Sergei Petrunia
93d3a39ba9 MariaRocks port: fix rocksdb.rocksdb_row_stats test
Make rocksdb_rows_XXX counters to work
2017-01-07 19:43:27 +00:00
Sergei Petrunia
ebbe59fa33 MariaRocks port: fix rocksdb.bloomfilter3 test
In MySQL 5.6, QUICK_SELECT_DESC calls handler->set_end_range() to
inform the storage engine about the bounds of the range being scanned.

MariaDB doesn't have that (handler::set_end_range call was back-ported
but it is not called from QUICK_SELECT_DESC).
Instead, it got prepare_*scan() methods from TokuDB.

Implement these methods so that MyRocks has information about the range
end.
2017-01-07 16:03:47 +00:00
Sergei Petrunia
69d5ee58c6 MariaRocks port: Temporarily disable tests related to Gap Lock detector (MDEV-11735) 2017-01-06 23:36:23 +03:00
Sergei Petrunia
e3df50c4b9 MariaRocks port: fix rocksdb.table_stats
- Need to manually enable userstat
- MariaDB has a lot fewer columns in table_statistics table.
2017-01-03 00:21:04 +03:00
Sergei Petrunia
31b2237c68 Merge branch '10.2' of github.com:MariaDB/server into 10.2-mariarocks
and a few trivial test result updates
2017-01-02 21:09:31 +00:00
Sergei Petrunia
a597e0e164 MariaRocks port: fix tests
- rocksdb.tmpdir works (however @@rocksdb_tmpdir has no effect yet!)
- trx_info_rpl is only run in RBR mode
- type_char_indexes_collation now works
  = take into account that characters with the same weight can have
    any order after sorting (and they do in MariaDB)
  = MariaDB doesn't use index-only for extended keys that have partially-
    covered columns.
2017-01-02 22:50:35 +03:00
Sergei Petrunia
3ecd9e0bfc Post-merge fixes for rocksdb.add_index_inplace_crash 2017-01-02 00:15:45 +00:00
Sergei Petrunia
7c4ebec82d MariaRocks: trivial post-merge test fixes 2017-01-02 00:06:26 +00:00
Sergei Petrunia
302ec9ab26 Merge branch '10.2-mariarocks' of github.com:MariaDB/server into 10.2-mariarocks 2017-01-01 23:33:50 +00:00
Sergei Petrunia
d8288b306c Merge remote-tracking branch 'mergetrees/merge-myrocks' into 10.2-mariarocks 2017-01-01 23:33:18 +00:00
Sergei Petrunia
3e7e559150 Fix the "fatal error: mysqld_error.h: No such file or directory" compile error 2017-01-01 01:50:17 +03:00
Sergei Petrunia
cfb59f3196 Copy of
commit f6ed777697db4ad7aee1e98c53243dced2b5891c
Author: Chenyu Yan <seayan@outlook.com>
Date:   Thu Dec 29 16:10:25 2016 -0800

    Fix BIG_TIMEOUT constant

    Summary: Update the constant to reflect what the comments indicates.

    Reviewed By: gunnarku

    Differential Revision: D4374476

    fbshipit-source-id: dd7f484
2016-12-31 23:30:09 +03:00
Sergei Petrunia
ae0a490eb3 MariaRocks port: Remove ifdef in ha_rocksdb::set_skip_unique_check_tables
We expose @@rocksdb_skip_unique_check_tables anyway, so it's not
really disabled.
2016-12-31 22:08:05 +03:00
Sergei Petrunia
d1af31b3c2 MariaRocks port: Make rocksdb_sys_vars suite pass
- Fix include paths, add suite.opt
- Add a test for @@rocksdb_supported_compression_types
Now all tests pass, except rocksdb_sysvars.rocksdb_rpl_skip_tx_api_basic
2016-12-31 21:31:50 +03:00
Sergei Petrunia
d379963d73 MariaRocks port: remove target_lsn parameter of rocksdb_flush_wal
- It's from a webscalesql feature that we dont have
- MyRocks ignores it anyway
2016-12-30 02:18:56 +03:00
Sergei Petrunia
9ca608028f MariaRocks port: make rocksdb.rocksdb_qcache test pass 2016-12-27 00:13:32 +00:00
Sergei Petrunia
8f2d58b26b MariaRocks port: run rocksdb.rpl_row_stats with binlog_format=row only
The test still fails but at least we do not try to run it with
wrong binlog_format.
2016-12-26 22:31:46 +03:00
Sergei Petrunia
122bc4b54c MariaRocks port: Remove ifdef MARIAROCKS_NOT_YET in rocksdb_start_tx_and_assign_read_view
Looked though the code: MariaDB's method of doing START TRANSACTION
WITH CONSISTENT SNAPSHOT doesn't require mysql_bin_log_lock_commits
calls.
2016-12-26 19:12:16 +00:00
Sergei Petrunia
9f7dc2bbf5 MariaRocks port: make rocksdb.rpl_savepoint pass
Run it only with binlog_format=row, update test result
2016-12-15 20:56:27 +03:00
Sergei Petrunia
24224839d8 MariaRocks port: make rocksdb.rpl_statement_not_found work 2016-12-15 19:25:32 +03:00