1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2026-10-23 21:49:05 +03:00
Commit Graph

279 Commits

Author SHA1 Message Date
Patrick LeBlanc
b62b5bcb1e Mass 'Corporaton' -> 'Corporation' substitution for 1.1. 2020-02-10 11:02:41 -05:00
David Hall
f2d8a33ee5 MCOL-3296 CTRL+C should not double remove from dequeue. 2019-05-09 12:42:18 -05:00
Andrew Hutchings
d4418ecf64 Merge branch 'develop-1.0' into 1.1-merge-up-20190308 2019-03-08 10:27:06 +00:00
zdrav1
d2f86b3f8d MCOL-2151, added jemalloc dependency check in columnstoreClusterTester 2019-02-12 14:09:02 +02:00
Roman Nozdrin
7b4cec5757 MCOL-1829 Subquery with limited order by could potentially return onordered set.
There were two code mistakes: Eq::operator() always returned true for
    any pair and Hasher::operator() always returned 0 as a key.
2019-01-14 16:55:41 +03:00
Patrick LeBlanc
8220579b9a Merge pull request #656 from mariadb-corporation/MCOL-1676-1.1
MCOL-1676 Window Functions with FLOAT type gives incorrect answer
2018-12-21 19:33:44 -06:00
Andrew Hutchings
7989ccefe0 MCOL-2018 Fix array bounds issue
StringStore NULL check includes a check for _CpNuLl_ in the
StringStore. This is a case should never happen but we keep it just in
case.

Unfortunately this check was skipping 4*8 bytes instead of just 4 bytes.
This is definitely bad behaviour but it could cause an out-of-bounds read
based crash.
2018-12-12 18:06:09 +00:00
David Hall
9d438f0a24 MCOL-1676 Window Functions with FLOAT type gives incorrect answer 2018-12-11 09:37:12 -06:00
Andrew Hutchings
b1d5f54abe MCOL-1868 Fix error in unused code
There was a a bad line in some code that we don't currently compile. This
patch fixes that code in case we use it in the future.
2018-11-14 14:29:58 +00:00
Andrew Hutchings
65287a0613 MCOL-1826 Fix race in FLOAT/DOUBLE to string
In the FLOAT/DOUBLE to string conversions a class global string was used
to store the result. Unfortunately it is possible for an instance of
this class to be used by multiple threads of PrimProc simultaneously.
This would cause a race and data corruption or more likely a crash.

This fix passes a string object from the caller to use instead.
2018-10-22 17:56:49 +01:00
Andrew Hutchings
ccd9a414eb MCOL-1810 Fix hang on low core count
Anything that links against joblist will spin up a threadpool upon
startup. This includes the tools setConfig/getConfig. It is possible on
a low core count machine or low CPU speed that the signal to the prune
thread to shutdown is sent before the thread has completed startup when
these quick-running tools are used.

This fix adds a mutex so that spin up and shutdown can't happen at the
same time as well as a stop watch in case we are shutting down when
either the thread is running or we haven't fully started.
2018-10-16 18:03:25 +01:00
Andrew Hutchings
5092b4fd13 MCOL-1750 unique_ptr doesn't work in all OSes 2018-09-28 07:55:06 +01:00
Andrew Hutchings
94dfacfe25 MCOL-1750 Fix threadpool stack leaks
When a thread has been idle for 10 minutes and we have too many threads
in the threadpool the thread will be pruned. This is done by the
thread's main function just returning. Unfortunately this does not free
up the memory, the thread either needs to be joined or detatched.

We cannot use detached threads since there are mutexes and conditional
variables between the main thread and the threadpool threads. If the
main thread finishes before the threadpool threads (as would happen in
cpimport) then crashes occur. The parent needs to wait on the child
threads which is the whole point in joining.

So this fix spawns a new thread which every minute will check the list
of threads to be joined due to timeout and join them.

We have had to use an adapted version of boost::thread_group so that we
can join a single thread based off its thread ID.

In addition with have modified PriorityThreadPool to use detached
threads since this does not need to signal the child threads at the end.
2018-09-28 07:21:49 +01:00
David Hill
8043674432 MCOL-1591 - add umask test to tester 2018-08-01 16:34:40 -05:00
drrtuy
0e856ce9b0 MCOL-1551 CS now supports hostnames in Columnstore.xml. 2018-07-24 23:05:09 +03:00
David Hall
db4279dac7 MCOL-1535 caseOperationType adjusted for new simple case order 2018-07-23 17:32:38 -05:00
Andrew Hutchings
e05250915b MCOL-1545
Remove getPool call. It is completely unused and it breaks compiling in
GCC 8.1
2018-07-19 09:29:06 +01:00
Andrew Hutchings
5fe9a91290 MCOL-1496 Fix array bug in joiner
Found using -D_GLIBCXX_ASSERTIONS
2018-06-25 11:17:50 +01:00
Andrew Hutchings
40405c792a MCOL-1474 Add error handling to PTP
PriorityThreadPool didn't have very good error handling. If something
failed it would just ignore whatever was being processed. This could
lead to a query continuing without retreiving all of the required data.

This patch adds error handling, sending a message back to the client
and a log message. It also destroys and recreates the pool thread.
2018-06-14 16:28:06 +01:00
Andrew Hutchings
250d90a9bc MCOL-1474 Catch errors in PriorityThreadPool
PriorityThreadPool errors cause crashes in PrimProc. This patch catches
the errors and causes the thread to end cleanly.
2018-06-14 14:43:37 +01:00
Andrew Hutchings
5b1f5d5fe4 MCOL-1412 Ubuntu 18.04 support
Backport Ubuntu 18.04 support to 1.1
2018-05-14 22:03:25 +01:00
Andrew Hutchings
baf42e7b4a MCOL-1390 Fix SUBSTRING_INDEX for negative count
If negative count number is more than the number of characters in the
string then it should always return the string.

For example if a table contains SUBSTRING_INDEX('zzz', 'z', -5) should
return 'zzz'. Before this patch it would return NULL.
2018-05-10 18:32:22 +01:00
Andrew Hutchings
ac3e702a3e MCOL-1396 Allow StringStore to hold more than 2GB
StringStore originally worked by returning a 32bit pointer to a memory
location and storing the length with that pointer. This allowed 4GB to
be stored in 64KB blocks. With 1.1 we used the high bit to signify a
TEXT/BLOB string of > 64KB reducing the max capacity to 2GB but without
any bounds checking.

So, if you went over the 2GB mark the getter would think you are trying
to get a long string instead of a short one and come up empty. It would
then return NULL.

This patch uses 64bit memory points still retaining the high bit to
signify long strings. It also now stores the length with the string
rather than with the pointer to allow the full 64bits for pointers.

It also adds a bounds check for small strings.
2018-05-08 19:38:06 +01:00
david hill
f2d748cff1 MCOL-1293 2018-04-16 16:22:03 -05:00
Andrew Hutchings
0c6dc5e15c MCOL-1341 Fix CASE handling with 10.2.14
MariaDB Server 10.2.14 changed the order that CASE items are processed.
This broke the engine's CASE handling. This patch uses the new order
instead since this is what will be used in 10.2 and 10.3 going forward.
2018-04-16 19:21:28 +01:00
david hill
333f848a2f MCOL-1317 Mcol-1318 2018-04-05 13:24:55 -05:00
david hill
4067d69278 MCOL-1317 Mcol-1318 2018-04-05 13:23:06 -05:00
David Hall
73b1ac68fa MCOL-1196 Error when using OR in case THEN portion
In ha_calpont_execplan, Allow OR to be parsed; in searched_case parsing, reverse the order of processing arguments so that ptWorkStack.pop() is executed in the same order as the arguments being processed.

In func_case, modify to pass left and right to getBoolVal, if they exist.
2018-03-27 12:43:43 -05:00
Andrew Hutchings
fa3574b6b1 MCOL-1246 Make matching SQL-92 compliant(ish)
SQL-92 basically specifies for a NOPAD collation that only space should
be ignored for matches. Tabs and other whitespace are handled
differently. We don't fully support collations yet so we assume the
defaults.
2018-03-09 13:08:09 +00:00
Andrew Hutchings
17e954db7d MCOL-1246 Fix string matching for whitespace
For equality string matches other engines ignore trailing whitespace
(this does not apply to LIKE matches). So we should do the same. This
patch trims whitespace for MIN/MAX extent elimination checks, fixed
width columns and dictionary columns during equality matches against
constants (SELECT * FROM t1 WHERE b = 'ABC').
2018-03-07 16:56:42 +00:00
benthompson15
05431bf705 Merge pull request #389 from mariadb-corporation/MCOL-962
Mcol 962
2018-02-05 15:55:59 -06:00
David Hall
30b4edb0cd MCOL-1178 Add bool processing to CASE 2018-02-02 15:30:12 -06:00
David Hall
2bdcb159ed MCOL-962 change mcssystemreadonly to a tri state return flag. Test for 0 to see if the system is in a writable state, 2018-01-30 16:07:51 -06:00
david hill
c1035dae73 MCOL-1060 - test tool change #2 2018-01-19 15:21:28 -06:00
benthompson15
3748036772 Merge pull request #371 from mariadb-corporation/1.1-merge-up-20180118
1.1 merge up 20180118
2018-01-19 12:19:42 -06:00
benthompson15
5d5a93cb5f Merge pull request #370 from mariadb-corporation/davidhilldallas-patch-1
MCOL-1060 - fix spelling/grammer issues
2018-01-18 16:48:49 -06:00
Andrew Hutchings
5d9f9c819b Merge branch 'develop-1.0' into 1.1-merge-up-20180118 2018-01-18 16:28:08 +00:00
Andrew Hutchings
12e4960a04 Merge pull request #367 from mariadb-corporation/MCOL-1165
MCOL-1165 use the threadpool's idle down feature
2018-01-18 16:00:01 +00:00
david hill
8a78fbacd2 MCOL-1060 - fix spelling/grammer issues 2018-01-17 15:41:10 -06:00
david hill
3ed23512e1 MCOL-1058 - added check for maradin password and mariadb-libs paclage 2018-01-17 11:18:39 -06:00
David Hall
9749d825b5 MCOL-1165 use the threadpool's idle down feature 2018-01-16 13:26:44 -06:00
benthompson15
468421be66 Merge pull request #359 from mariadb-corporation/MCOL-962
MCOL-962 Add mcsSystemReady(), mcsSystemReadOnly() and mcsWritesSuspe…
2018-01-16 12:32:26 -06:00
David Hall
504fcf0778 MCOL-1128 Allow exeMgrThreadPool to use unlimited threads. The number will be limited by the number of sessions allowed in server. 2018-01-12 16:29:01 -06:00
David Hall
1ffeda44d6 MCOL-962 Add mcsSystemReady(), mcsSystemReadOnly() and mcsWritesSuspended() 2018-01-10 12:17:57 -06:00
Andrew Hutchings
c31c836352 MCOL-1085 Add crash dump to daemons
This patch adds an automated crash dump which logs in
/var/log/mariadb/columnstore/trace/ when one of the ColumnStore daemons
crashes.
2018-01-03 09:20:09 +00:00
benthompson15
39a2253ee1 Merge pull request #346 from drrtuy/MCOL-939
MCOL-939 Moved columnstore version information to columnstoreversion.h for 1.1.X
2017-12-19 13:21:19 -06:00
David.Hall
a89438c5fe Merge pull request #345 from mariadb-corporation/1.0-merge-up
1.0 merge up
2017-12-12 16:44:54 -06:00
Roman Nozdrin
bea47cc657 MCOL-939 Moved columnstore version information to columnstoreversion.h for 1.1.X 2017-12-12 22:53:33 +03:00
Andrew Hutchings
8babe4a35d Merge branch 'develop-1.0' into 1.0-merge-up 2017-12-12 10:01:14 +00:00
David.Hall
ca2c511f59 Merge pull request #337 from mariadb-corporation/1.0-merge-up
Merge develop-1.0 to develop-1.1
2017-12-11 15:25:56 -06:00