12770 Commits

Author SHA1 Message Date
Markus Mäkelä
5f3ff7d1be
MXS-2521: Add test case
The test case doesn't reproduce the problem due to MDEV-19811 getting in
the way but it is likely to reproduce it once that bug has been avoided.
2019-06-24 12:33:49 +03:00
Markus Mäkelä
f9eef8f44c
Fix configuration guide documentation
Fixed limitations section, the heading depths and the document name,
corrected localhost_match_wildcard_host, added deprecation notes where
required.
2019-06-24 12:32:58 +03:00
Markus Mäkelä
dbc321cbbe
Merge branch '2.2' into 2.3 2019-06-24 12:20:19 +03:00
Markus Mäkelä
1cb13582ff
Fix worker state debug assertion
Stopped workers will receive messages.
2019-06-24 11:03:50 +03:00
Markus Mäkelä
be429c2c57
MXS-2490: Always restore original statement ID
By always restoring the ID, we are guaranteed to only store the query in
the form that it was originally sent in. This should be changed so that
the ID that the client sends can be used as-is in the backends.
2019-06-20 14:27:04 +03:00
Markus Mäkelä
805be70a78
Add more information to rwsplit info messages
The statement ID for all binary protocol statements and the error given to
handleError are now logged.
2019-06-20 14:27:03 +03:00
Markus Mäkelä
301b1b63ab
MXS-2569: Always terminate schemas with newlines
If the stored file didn't have a newline in the schema, the schema and the
first row would be on the same line.
2019-06-20 12:32:30 +03:00
Markus Mäkelä
7673ee685d
Distinguish stopped and finished workers
By having a separate FINISHED state and a STOPPED state, it is possible to
know at which point in the worker's lifetime an event is done. Posting of
messages before a worker is started is allowed but posting them after the
worker has stopped is not.

This fixes avrorouter related failures and all other failures that stem
from worker messages being ignored at startup.
2019-06-20 12:32:30 +03:00
Markus Mäkelä
dd944c7302
MXS-2568: Always enable LOCAL INFILE for testing
The automatic detection of LOCAL INFILE added in connector-c 3.0.9
requires that the option is enabled explicitly.
2019-06-20 12:32:30 +03:00
Esa Korhonen
39df829384 Don't kick out super-users when performing rejoin
When rejoining a server, preventing writes is not as essential as in switchover.
2019-06-19 17:14:39 +03:00
Markus Mäkelä
3d8475f8ed
Merge branch '2.2' into 2.3 2019-06-19 12:37:23 +03:00
Markus Mäkelä
35b5f2099b
Regenerate MaxCtrl documentation 2019-06-19 10:44:16 +03:00
Markus Mäkelä
96d5c575f8
Document required create service parameters
When a service is created via MaxCtrl, the `user` and `password`
parameters must be defined. This was not documented in the command help
output.
2019-06-19 10:44:16 +03:00
Markus Mäkelä
27fb397041
MXS-2547: Do shutdown on main worker
By stopping the REST API before the workers and moving the shutdown to the
same worker that handles REST API requests, we prevent the hang on
shutdown. This also makes the signal handler signal-safe.
2019-06-19 10:31:47 +03:00
Markus Mäkelä
69b3879357
MXS-2547: Don't post messages to stopped workers
If a worker has been stopped, tasks must not be executed on it. To prevent
this, the calling code should check whether the worker has been
stopped. This does not prevent the case where a message is successfully
posted to a worker but the worker is stopped before it processes it.
2019-06-19 10:31:47 +03:00
Markus Mäkelä
b7294a28af
MXS-2547: Assert that workers aren't stopped
If a worker is stopped, none of the Worker::execute or post_message
methods should be called.
2019-06-19 10:31:47 +03:00
Esa Korhonen
a60bd37610 MXS-2367 Print slave connection errors when replication fails
The slave connection I/O-tread stays running if replication credentials are
wrong when connecting to master. This causes a switchover/failover timeout.
When this happens, print the error in the slave connection status as this
clarifies the problem to the user.
2019-06-18 15:02:21 +03:00
Markus Mäkelä
6cbe9d1258
MXS-2550: Fix default module parameters
The parameters weren't processed when they were added from the module
defaults.
2019-06-18 07:06:51 +03:00
Markus Mäkelä
372c9a8350
Fix configuration guide documentation
Fixed limitations section, the heading depths and the document name,
corrected localhost_match_wildcard_host, added deprecation notes where
required.
2019-06-17 14:07:52 +03:00
Markus Mäkelä
002281599e
MXS-2563: Add test case
Added a test case that reproduces the debug assertion with the old code
and verifies that it is fixed with the new one.
2019-06-17 14:07:52 +03:00
Markus Mäkelä
f6a5b59067
MXS-2563: Fix query retrying on slave failure
If one slave is executing a query while another one is executing a session
command and the one that is executing the session command fails, the
ongoing query would get retried even though the server that failed was not
executing it. If the server was executing a session command, nothing needs
to be done.
2019-06-17 14:07:52 +03:00
Esa Korhonen
cf866a6a57 Merge branch '2.2' into 2.3 2019-06-14 10:49:51 +03:00
Markus Mäkelä
2accfad329
Handle trailing unexpected ERR packets
RWBackend did not expect that a resultset and an unexpected ERR packet
could be stored in the same buffer. This can happen for example if a
server shuts down immediately after the resultset is sent.
2019-06-14 08:12:02 +03:00
Esa Korhonen
acfaae9d46 MXS-2480 Use in-memory-database in PAM authenticator
This was already fixed in develop, but the fix is both small and useful
so should be backported.
2019-06-13 17:47:08 +03:00
Esa Korhonen
a5898f83f9 Fix mysqlmon_rejoin_manual
Added some extra connection refreshing and monitor waiting. Unclear why this
is needed now but it seems to work.
2019-06-13 10:28:14 +03:00
Markus Mäkelä
239c4a8615
MXS-2549: Install prelink config file
The prelink configuration file should prevent maxctrl from being corrupted
by it.
2019-06-12 17:49:41 +03:00
Johan Wikman
74ef8a9591 Update 2.3 maintenance version 2019-06-12 14:28:37 +03:00
Johan Wikman
493155127b Merge branch '2.3.8' into 2.3 2019-06-12 14:27:22 +03:00
Johan Wikman
208377b262 Update 2.3.8 release date 2019-06-12 14:26:15 +03:00
Markus Mäkelä
bb92d61a1b
Fix KILL command packet boundary detection
If a packet with a KILL query was followed with another packet in the same
network buffer, the code wouldn't work as it expected to receive only one
packet at a time.
2019-06-12 12:20:26 +03:00
Johan Wikman
b98ff222f0 Merge branch '2.3.8' into 2.3 2019-06-12 11:26:33 +03:00
Markus Mäkelä
6ca5143141
Make kill_query more robust
The test now uses an infinite loop in the SQL to make sure the execution
is interrupted.
2019-06-11 21:30:16 +03:00
Johan Wikman
814ae196e9 qc_sqlite: Replace strncpy with memcpy
On RHEL8 the former may give rise to incorrect

    error: 'char* strncpy(char*, const char*, size_t)' destination
    unchanged after copying no bytes [-Werror=stringop-truncation]
2019-06-11 20:14:58 +03:00
Esa Korhonen
95606370c8 MXS-2551 Do not print deprecated parameters into serialized config files
In MaxScale, a "deprecated" parameter is not in use and can be ignored.
Leaving the parameters out of serialized configuration files avoids warning
messages.
2019-06-11 15:55:35 +03:00
Markus Mäkelä
5b14e28fc8
Fix maxavrocheck build failure on Ubuntu Trusty
The return value of realpath should be checked even if it is pointless.
2019-06-11 14:15:06 +03:00
Johan Wikman
acc5863fe2 MXS-2442 ':N' accepted as pos. parameter in Oracle mode 2019-06-11 13:53:09 +03:00
Johan Wikman
c68cb788cc MXS-2552 Update DISK plugin documentation 2019-06-11 13:21:17 +03:00
Markus Mäkelä
4716f5b48f
Fix buffer end pointer comparison in maxavro
The buffer pointer can point to the end pointer if it is the last value in
the buffer.
2019-06-11 09:44:27 +03:00
Markus Mäkelä
ce3d7acf2d
Fix maxavrocheck path processing
A null path could be given if realpath failed to resolve the name. This
hides the actual reason of the failure making it harder to resolve it.
2019-06-11 09:44:27 +03:00
Markus Mäkelä
5adc8fa5bd
Add missing HEAVY labels to big tests 2019-06-11 09:44:27 +03:00
Markus Mäkelä
5f5e402a32
Reconnect before find_field in mysqlmon_rejoin_manual
This appears to fix the test failure but the reason why it worked before
still remains a mystery.
2019-06-11 00:09:26 +03:00
Johan Wikman
b33cd85b4d Update release notes and change log for 2.3.8 2019-06-10 14:37:57 +03:00
Esa Korhonen
57029bb1a1 MXS-2445 Add logrotate config file 2019-06-10 12:51:03 +03:00
Esa Korhonen
1ba77b59e2 MXS-2548 Show correct monitor state in "maxadmin list monitors"
The code OR:d with 0.
2019-06-06 17:09:41 +03:00
Esa Korhonen
65975a38e2 Add test for MXS-2355
The test attempts to log in using mysql_clear_password.
2019-06-06 16:36:36 +03:00
Timofey Turenko
0469d57ede Merge branch '2.3' of github.com:mariadb-corporation/MaxScale into 2.3 2019-06-05 14:53:28 +03:00
Johan Wikman
f0c4fd5723 MXS-2250 Add test that reveals the problem
Before the MXS-2250 fix, the following ends with an error:

    CREATE TEMPORARY TABLE t (f INT);
    DESCRIBE t;

Reason is that the first is sent to the master (and the table will
not be replicated to slaves) and the latter to some slave.
2019-06-05 14:29:30 +03:00
Johan Wikman
b8d601aab2 MXS-2250 Reveal table information for 'DESCRIBE tbl'
When a statement like 'DESCRIBE tbl' is classified, the table
name will now be available so that a router can check whether the
table is a temporary one. In that case, the statement must be sent
to the master.
2019-06-05 14:28:45 +03:00
Timofey Turenko
16005c452e run create_user* under sudo 2019-06-05 13:42:39 +03:00
Timofey Turenko
de978be955 remove '-u root' from create_user*.sh
Call of MariaDB client from local machine with sudo with '-u root' parameter
does not work with 10.4
2019-06-05 12:57:46 +03:00