Commit graph

35 commits

Author SHA1 Message Date
Jan Lindström
9d9a2253c6 Merge remote-tracking branch 10.2 into 10.3
Conflicts:
	mysql-test/suite/galera/t/galera_binlog_event_max_size_max-master.opt
	mysql-test/suite/innodb/r/innodb-mdev-7513.result
	mysql-test/suite/innodb/t/innodb-mdev-7513.test
	mysql-test/suite/wsrep/disabled.def
	storage/innobase/ibuf/ibuf0ibuf.cc
2019-12-02 14:35:10 +02:00
willhan
3551cd32a8 MDEV-17508 Fix bug for spider when using "not like"
fix bug for spider where using "not like" (#890)

test case:
t1 is a spider engine table;
  CREATE TABLE `t1` (
  `id` int(11) NOT NULL DEFAULT '0',
  `name` char(64) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=SPIDER

query: "select * from t1 where name  not like 'x%' " would dispatch "select xxx name name like 'x%' " to remote mysqld, is wrong
2019-11-25 15:40:01 +01:00
Marko Mäkelä
be85d3e61b Merge 10.2 into 10.3 2019-05-14 17:18:46 +03:00
Marko Mäkelä
26a14ee130 Merge 10.1 into 10.2 2019-05-13 17:54:04 +03:00
Vicențiu Ciorbaru
cb248f8806 Merge branch '5.5' into 10.1 2019-05-11 22:19:05 +03:00
Kentoku
4e599c74bb MDEV-18313 Supports 'wrapper mariadb' for connection information 2019-01-31 08:51:34 +01:00
Kentoku
bef6b197fc MDEV-16520 Out-Of-Memory running big aggregate query on Spider Engine
Change default value of the followings
quick_mode 0 -> 3
quick_page_size 100 -> 1024

Add the following parameter for limiting result page size by byte
- quick_page_byte(qpb)
  Number of bytes in a page when acquisition one by one.
  When quick_mode is 1 or 2, Spider stores at least 1 record even if
  quick_page_byte is smaller than 1 record. When quick_mode is 3,
  quick_page_byte is used for judging using temporary table.
  That is given to priority when server parameter spider_quick_page_byte
  is set.
  The default value is 10485760

Fix "out of sync" issue at using quick_mode = 1 or 2
2019-01-31 08:51:34 +01:00
Kentoku
6caf9ec425 Update Spider to version 3.3.14. Add direct left outer join/right outer join/inner join feature 2019-01-31 08:51:34 +01:00
Jacob Mathew
4885baf682 MDEV-16889: Spider Crash mysqld got exception 0xc0000005
The SELECT with the INNER JOIN is executed with one of the two tables being
optimized as a constant table, which is pre-read.  Spider nevertheless attempts
to push down the join to the data node.  The crash occurs because the constant
table is excluded from the optimized query that Spider attempts to push down.

In order for Spider to be able to push down a join, the following conditions
need to be met:
- All of the tables involved in the join need to be included in the optimized
  query that Spider pushes down.  When any of the tables involved in the join
  is a constant table, it is excluded from the optimized query that Spider
  attempts to push down.
- All fields involved in the query need to be members of tables included in the
  optimized query.

I fixed the problem by preventing Spider from pushing down queries that include
a field that is not a member of a table included in the optimized query.  This
solution fixes the reported problem and also fixes other potential problems.

Author:
  Jacob Mathew.

Reviewer:
  Kentoku Shiba.
2018-08-29 17:36:16 -07:00
Jacob Mathew
813b739850 MDEV-16246: insert timestamp into spider table from mysqldump gets wrong time zone.
The problem occurred because the Spider node was incorrectly handling
timestamp values sent to and received from the data nodes.

The problem has been corrected as follows:
- Added logic to set and maintain the UTC time zone on the data nodes.
  To prevent timestamp ambiguity, it is necessary for the data nodes to use
  a time zone such as UTC which does not have daylight savings time.
- Removed the spider_sync_time_zone configuration variable, which did not
  solve the problem and which interfered with the solution.
- Added logic to convert to the UTC time zone all timestamp values sent to
  and received from the data nodes.  This is done for both unique and
  non-unique timestamp columns.  It is done for WHERE clauses, applying to
  SELECT, UPDATE and DELETE statements, and for UPDATE columns.
- Disabled Spider's use of direct update when any of the columns to update is
  a timestamp column.  This is necessary to prevent false duplicate key value
  errors.
- Added a new test spider.timestamp to thoroughly test Spider's handling of
  timestamp values.

Author:
  Jacob Mathew.

Reviewer:
  Kentoku Shiba.

Cherry-Picked:
  Commit 97cc9d3 on branch bb-10.3-MDEV-16246
2018-07-09 16:09:20 -07:00
Kentoku SHIBA
207594afac merge Spider 3.3.13
New features in 3.3.13 are:
- Join Push Down for 1 by 1 table and single partition.
2017-12-03 13:58:36 +02:00
Jacob Mathew
7afcee4cf6 MDEV-8954 unnecessary fetch of entire table
Merged fix into 10.2.
2017-05-01 16:04:47 -07:00
Sergei Golubchik
da4d71d10d Merge branch '10.1' into 10.2 2017-03-30 12:48:42 +02:00
iangilfillan
f0ec34002a Correct FSF address 2017-03-10 18:21:29 +01:00
Marko Mäkelä
89d80c1b0b Fix many -Wconversion warnings.
Define my_thread_id as an unsigned type, to avoid mismatch with
ulonglong.  Change some parameters to this type.

Use size_t in a few more places.

Declare many flag constants as unsigned to avoid sign mismatch
when shifting bits or applying the unary ~ operator.

When applying the unary ~ operator to enum constants, explictly
cast the result to an unsigned type, because enum constants can
be treated as signed.

In InnoDB, change the source code line number parameters from
ulint to unsigned type. Also, make some InnoDB functions return
a narrower type (unsigned or uint32_t instead of ulint;
bool instead of ibool).
2017-03-07 19:07:27 +02:00
Kentoku SHIBA
14eea2f8c2 merge spider-3.2.37 2015-10-29 07:34:53 +09:00
Kentoku SHIBA
cf3b51b1d5 Merge Spider 3.2.18 2015-02-20 00:41:26 +09:00
Kentoku SHIBA
391fddf660 Merge Spider 3.2.11 2014-09-18 09:26:30 +09:00
Kentoku SHIBA
29cf8fb348 merge Spider 3.2.4 2014-06-08 19:52:11 +09:00
Kentoku SHIBA
89441877e7 fix for MariaDB 10.0.9 2014-03-25 05:38:08 +09:00
Kentoku SHIBA
da522fc1cd fix for MariaDB 10.0.8 2014-03-25 05:32:12 +09:00
Kentoku SHIBA
f41f5f742f use handler no where clause 2014-03-25 05:24:16 +09:00
Kentoku SHIBA
3a931cdc5f casual search 2014-03-25 05:14:10 +09:00
Kentoku SHIBA
74195f40b4 current date 2014-03-25 05:10:40 +09:00
Kentoku SHIBA
51040beb6e handler clause 2014-03-25 05:00:34 +09:00
Kentoku SHIBA
993dd378b7 fix for MariaDB 10.0.7 building errors 2014-03-25 04:48:23 +09:00
Kentoku SHIBA
ad54787d55 append group by for no order by 2014-03-25 04:26:48 +09:00
Kentoku SHIBA
dc01d230ed add some direct aggregate feature. 2013-09-17 03:22:54 +09:00
Kentoku SHIBA
e9d53a384c fix a case of different linked table name for mrr. 2013-09-17 03:19:55 +09:00
Kentoku SHIBA
6458e115a0 add spider_bka_mode=2 2013-09-17 03:14:36 +09:00
Kentoku SHIBA
38c9476513 Change for mearging MariaDB 10.0.4. 2013-08-24 18:37:49 +09:00
Kentoku SHIBA
0a286927d9 Fulltext search optimization. Discard match fields. 2013-08-24 14:23:11 +09:00
Kentoku SHIBA
e48e717bef Revert change for 10.0.4. It's remerge later. 2013-08-24 14:11:23 +09:00
Sergey Vojtovich
43946c0888 MDEV4786 - merge 10.0-monty → 10.0
sql/sql_table.cc:
  Removed false assertion that HA_NO_COPY_ON_ALTER is merge specific.
  This flag is used at least by Spider and Connect.
storage/spider/ha_spider.cc:
  Renamed THD::stmt_da -> THD::get_stmt_da().
  Renamed KEY::key_parts -> KEY::user_defined_key_parts.
  Renamed ALTER_* flags -> Alter_info::ALTER_*.
storage/spider/spd_conn.cc:
  Renamed THD::stmt_da -> THD::get_stmt_da().
storage/spider/spd_db_conn.cc:
  Renamed MYSQL_ERROR -> Sql_condition.
  Renamed KEY::key_parts -> KEY::user_defined_key_parts.
storage/spider/spd_db_include.h:
  current_comment_start argument of generate_parition_syntax()
  was removed during merge.
storage/spider/spd_db_mysql.cc:
  Renamed KEY::key_parts -> KEY::user_defined_key_parts.
storage/spider/spd_ping_table.cc:
  Renamed THD::stmt_da -> THD::get_stmt_da().
storage/spider/spd_table.cc:
  Include my_getopt.h so that it exports my_defaults_file and
  my_defaults_extra_file.
  Renamed KEY::key_parts -> KEY::user_defined_key_parts.
2013-07-23 17:22:02 +04:00
Sergey Vojtovich
0b116de7c5 MDEV-4438 - Spider storage engine 2013-06-27 15:18:48 +04:00