Commit Graph

14103 Commits

Author SHA1 Message Date
e7e40b0179 MXS-2713 Classify SET PASSWORD as QUERY_TYPE_WRITE
A change of the password is replicated to the slaves, so it
must only be sent to the master.
2019-10-07 14:33:53 +03:00
2a7f320cf4 MXS-2713 Add test that reveals problem 2019-10-07 14:24:06 +03:00
4791e043f1 Merge branch '2.3' into 2.4
MXS-2645 was already fixed in 2.4.
2019-10-04 15:54:45 +03:00
c54e254ea0 MXS-2645 Add test case to connection_limit test
Tests max_connections with repeated failed logins.
2019-10-04 15:11:09 +03:00
428bc5740b MXS-2645 Decrement service client count also when authentication fails
The client count was incremented before authentication was complete, and
should be decremented if it fails. Otherwise service connection limit can
be easily reached.
2019-10-04 15:11:09 +03:00
2d9d9356c9 Merge branch '2.3' into 2.4 2019-10-04 12:56:52 +03:00
5a6d6733ae Fix qlafilter example config
`filebase` is a mandatory parameter.
2019-10-04 09:42:04 +03:00
64d19cf018 MXS-2711: Fix updating of retain_last_statements
The value is now correctly expected to be a non-negative integer.
2019-10-04 09:42:03 +03:00
869effc352 MXS-2707: Retain commands that respond
Only commands that return a response should to be retained. Otherwise the
bookkeeping of m_current_query will be wrong.
2019-10-03 22:17:44 +03:00
237cdd798b MXS-2687: Detect invalid socket arguments
Cherry-pick of 5a94f09cb97d7da5ca4a71b398f14ec32e6c90e7.
2019-10-03 09:29:52 +03:00
7f7b052f0e Print stacktrace in one message
By printing the stacktrace in one log message, it prevents it from
interleaving with other messages. This happens on busy systems and makes
crash analysis harder.
2019-10-02 10:44:57 +03:00
9c62aafa93 Merge branch '2.3' into 2.4 2019-10-01 15:25:41 +03:00
fffbb9f791 MXS-2600 Update MariaDB-Monitor documentation
Clarified info on privileges.
2019-10-01 15:14:43 +03:00
b223e6eed3 MXS-2264: Add support for RENAME TABLE
RENAME TABLE is now fully supported and works as expected. With the fix to
table versioning, the new table name will receive the latest version
number.
2019-09-30 16:09:04 +03:00
e3b7804462 Fix URL to Avro package download page 2019-09-30 14:29:00 +03:00
7767231c8f MXS-2264: Fix table versioning
The table versions are now stored in memory and are only resolved on
startup. This simplifies things and removes the need to know where the
data is stored as that information is not available to the Rpl class.
2019-09-30 11:47:30 +03:00
2eb6a25534 MXS-2264: Add support for ALTER TABLE RENAME
This adds preliminary support for renaming tables. There is still a
problem where the table version will always be set to 1 on a rename. This
should not be done and the version should be set to the largest value that
ever was for that table.
2019-09-30 11:47:30 +03:00
a444484310 MXS-2702: Update m_current_master on session command
When lazy_connect is enabled and the first query is `SET autocommit=0`, a
master connection can be created. If it is, then the m_current_master
pointer must also be updated.

Also fixed the case where a failure to connect to one slave would cause
the connection attempts to stop too early.
2019-09-30 11:47:29 +03:00
f6b2a7f3d5 MXS-2354: Extend datatype test case
Added proper test cases for fractional temporal types.
2019-09-30 11:47:29 +03:00
27675ed41d MXS-2354: Fix subsecond part of temporal values
TIMESTAMP2, DATETIME2 and TIME2 values with decimal parts are now
correctly converted into their string forms. Previously the decimal part
was ignored but most of the code required to extract it was in place.
2019-09-30 11:47:29 +03:00
72d9e41ccb MXS-2263: Process unsigned integer columns correctly
The unsigned integers that would previously be interpreted as negative
values are now correctly converted into their corresponding avro
values. Due to a limitation in the Avro file format, 64-bit unsigned
integers cannot be represented in their unsigned form.

Since both the signed and unsigned versions of a 32-bit integer cannot fit
into a single Avro int, the type for these was changed to long. This is a
backwards incompatible change which means files generated with older
versions will not convert unsigned values correctly.
2019-09-30 11:47:27 +03:00
e1ff978b80 MXS-2263: Retain integer sign information
The unsignedness of a column is now retained in the Column type as well as
the JSON schema. This allows correct conversion of unsigned integer types
which will be done in a later commit.
2019-09-30 11:45:01 +03:00
117e2e7e88 Deliver notifications to registered clients
The notifications were delivered to all clients regardless of the
registration state.
2019-09-30 11:45:01 +03:00
bcf26fba3e Add missing COMMIT detection for non-transactional engines
Non-transactional engines will use a query event with a COMMIT in it to
signal that the transaction is over.
2019-09-30 11:45:01 +03:00
51d2d6c1f2 Fix GTID file path generation
The path would be invalid if there was no trailing slash.
2019-09-30 11:45:01 +03:00
0dce20e5e7 Merge branch '2.3' into 2.4 2019-09-27 12:30:58 +03:00
a9f07844b3 MXS-2699 Accept '_[character_set] hex' as string
The purpose is to recognize e.g. /_utf8mb4 0xD091D092D093/ as
a valid string. The rule actually accepts /id integer/, but in
case the statement is something else but an '_' immediately
followed by a character set, followed by a hex number, it will
be rejected by the server so no harm done.
2019-09-27 12:23:04 +03:00
c01ecfed05 MXS-2699 Add test that reveals other bug 2019-09-27 12:23:04 +03:00
5bbb2e239d MXS-2699 Add rule for (expr [, expr]*)
Sofar at most (expr, expr) was accepted.
2019-09-27 12:23:04 +03:00
0c2a84c3a5 MXS-2699 Add test that reveals problem 2019-09-27 12:23:04 +03:00
5b4af80b15 Clean up temparary directories after creation of binary repo
During the build first binary packages are generated and copied into
'pre-repo' direcotory. Then binary repository is created and next
step is to copy repository into final directory according agreed
binary repo sirectories structure. After it temparal direcotries
are not needed.
2019-09-26 11:08:23 +03:00
661c104d39 Merge branch '2.3' into 2.4 2019-09-26 09:31:21 +03:00
54ec30cc8e MXS-2654 Document QC cache statistics 2019-09-26 09:30:52 +03:00
f9a6649d77 Merge branch '2.3' into 2.4 2019-09-24 21:42:32 +03:00
fcc7642328 MXS-2694: Add support for COM_BINLOG_DUMP
The resultset processing now understands COM_BINLOG_DUMP and treats it as
a never-ending resultset.
2019-09-24 21:41:24 +03:00
752dfbeaa8 Merge branch '2.3' into 2.4 2019-09-23 18:43:18 +03:00
74016322fd Update .gitignore 2019-09-23 18:36:19 +03:00
4fbb18535b MXS-2620 Mention that a normal master server shutdown may lose events 2019-09-23 18:35:41 +03:00
4d513941a7 Merge commit '8ac11a97c29ac9ce3e4099e77a9aa9475c1002b4' into 2.4 2019-09-23 14:07:32 +03:00
893f16fa53 Fix galeramon TOC
The syntax was wrong.
2019-09-21 21:17:23 +03:00
d499ff84af Speed up mxs1713_lots_of_databases
The SHOW DATABASES greatly slows down the test. By doing that only from
time to time, the test time drops from roughly 160 seconds to 15
seconds. There's also no point in continuing the test after a failure has
been seen.

Also added a missing sync_slaves to the database creation to make sure
they are created on all servers before the test starts.
2019-09-21 21:16:55 +03:00
9b0b152109 Fix debug assertion on readq prepend
If data was prepended to the readq while it was empty, the debug assertion
in gwbuf_append that checks the tail pointer would be hit.
2019-09-21 21:16:55 +03:00
9ce788ff0b MXS-2690: Fix duplicate database detection
Empty duplicate databases are now correctly detected since the results
will always return the database name combined with a trailing period.
2019-09-21 21:16:55 +03:00
8ac11a97c2 Extend pipe buffer size error message
The message now logs the instructions on how to increase the per-process
page limit for pipe buffers. This can happen if fs.pipe-max-size
multiplied by the number of workers exceeds the value of
fs.pipe-user-pages-soft multiplied by 4096.
2019-09-21 10:30:00 +03:00
6830f517b4 Improve message queue logging
Logging the pipe buffer size on startup will tell how large it was at the
time when MaxScale read it. If there are some abnormalities in it, this
will make it visible.

Logging the worker ID when the posting of a message fails will tell which
particular worker it was. For example, if the worker in question is the
main worker (i.e. ID 0), we know there's something that's blocking the
processing.
2019-09-21 09:43:12 +03:00
19487d2bfb Merge branch '2.3' into 2.4 2019-09-20 09:36:23 +03:00
aa7be1447d MXS-2688 Handle SET [ROLE|NAMES|PASSWORD|CHARACTER] explicitly
It's not correct to claim that they would modify a system variable,
so they are purely classified as QUERY_TYPE_SESSION_WRITE.
2019-09-20 09:27:38 +03:00
f587ec191d MXS-2688 Add QC operator QUERY_OP_SET
Allows RWS to unconditionally send all SET-statements to
all servers.
2019-09-20 09:27:38 +03:00
bd3107e7ca Merge branch '2.3' into 2.4 2019-09-19 15:37:43 +03:00
f46f873dc1 Add verbose backend status helper
This allows the same verbose information to be logged in the cases where
it is of use. Mostly this information can be used to figure out why a
certain session was closed.
2019-09-19 13:41:49 +03:00