10361 Commits

Author SHA1 Message Date
Markus Mäkelä
bfc8cb4803
MXS-2151: Always log fatal master connection errors
When the connection to the master is broken, the session is not configured
to use the read-only modes and the monitor can still connect to the
server, the connection will be closed and and error is sent to the
client. To leave some trace of this problem in the MaxScale logs, a
message should always be logged when a network error occurs.
2018-11-09 00:39:32 +02:00
Markus Mäkelä
6a8ba999bd
MXS-2095: Fix crash on GRANT CREATE TEMPORARY TABLE
The avrorouter classified the GRANT statement as a CREATE TABLE statement.
2018-11-08 08:31:48 +02:00
Markus Mäkelä
a9041a74f1
MXS-2106: Update schema generation scripts
Updated the schemas generated by the scripts. Also added a
requirements.txt for installing all of the python dependencies.
2018-11-05 13:37:29 +02:00
Markus Mäkelä
2fa37aa18a
MXS-2106: Add test case
Added a test case that reproduces the problem and verifies that it is
solved.
2018-11-05 13:37:29 +02:00
Markus Mäkelä
451e75eb6a
MXS-2106: Add null value support to cdc_connector
The cdc_connector had no explicit null value detection which is required
now that the null value handling is fixed.
2018-11-05 13:37:29 +02:00
Markus Mäkelä
562c7be8fe
MXS-2106: Fix NULL value handling
The NULL values were not stored as NULL Avro values due to the fact that
the file format has no native NULL-ness for the basic types. To solve
this, all values must be stored as a union that contains the actual type
as well as the null type.

Unions were not implemented in the maxavro library but implementing means
simply recursing one level down.
2018-11-05 13:37:29 +02:00
Markus Mäkelä
7f36ec83da
MXS-2095: Add runtime detection of unknown SQL
If the query statement is wrongly treated as a table creation statement it
could cause a crash. To handle this, unknown SQL is now reported and the
processing is stopped early. This does not solve the root cause of the
problem but makes it possible to detect it in the future.
2018-11-05 13:37:28 +02:00
Markus Mäkelä
348c86d22b
Rewrite change_user test
Rewrote the test and expanded the test coverage. This unveiled a bug in
readconnroute where the connection isn't closed when a COM_CHANGE_USER
fails.
2018-11-05 13:37:21 +02:00
Johan Wikman
f34ca0d473 Fix peculiar wrapping 2018-11-01 12:39:18 +02:00
Johan Wikman
0b23ee78e5 Update maintenance version number 2018-11-01 10:45:00 +02:00
Johan Wikman
70f361744a Merge branch '2.2.16' into 2.2 2018-11-01 10:42:14 +02:00
Johan Wikman
0e718d1207 Update release date 2018-11-01 10:34:07 +02:00
Toni Zlomislic
e1dedfb678 Update galeramon.c (#183)
* Update galeramon.c

support wsrep_sst_method "xtrabackup-v2" for available_when_donor maxscale option

* reformat line to fit <=110 chars / support xtrabackup-v2 sst method
2018-10-31 16:00:26 +02:00
Markus Mäkelä
47e7595a08
MXS-2115: Fix regression
The 5.5.5 prefix in the version strings was not added.
2018-10-30 18:43:37 +02:00
Markus Mäkelä
ceb4a18f59
Enable query_retries for mxs1961_standalone_rejoin
This should help prevent network disconnections and make the test more
stable. If the connection is lost, the automatic failover is disabled and
the test will fail.
2018-10-30 18:43:37 +02:00
Markus Mäkelä
d972c1cd37
Fix replication before syncing slaves in mxs1743_rconn_bitmask
This might help solve the problem where the test hangs when the slaves are
synced.
2018-10-30 18:43:37 +02:00
Markus Mäkelä
471cd8f0ef
Increase timeouts for mxs431
The test appears to have timed out a few times when creating the
databases.
2018-10-30 18:43:37 +02:00
Markus Mäkelä
31859ee486
Remove ses_bigmem test
The test doesn't work when ASAN is used as it increases the memory use of
the process. With the addition of more caches in 2.3, the test is also
more likely to fail. Due to the test being quite useless with ASAN, it is
better to remove it.
2018-10-30 18:43:37 +02:00
Johan Wikman
ec69a52c1e Update 2.2 release notes and change log 2018-10-30 14:22:20 +02:00
Markus Mäkelä
91c5f8580c
MXS-2119: Fix file permissions
The admin files are now created with 640 permissions and automatically
created directories now properly set the permissions for the group as
well. All files and directories created by avrorouter and binlogrouter
also now correctly limit the read and write permissions only to the owner
and the group.
2018-10-30 12:45:36 +02:00
Markus Mäkelä
eb10b723dd
MXS-2117: Fall back to old style query with 10.2.11
If a 10.2.11 or older server without a grant on all mysql tables is found,
the authenticator now falls back to the 10.1 behavior that uses subqueries
instead of CTEs. This is a more user friendly way of working around
MDEV-13453 that causes the problem as all functionality except the support
for composite roles is retained.
2018-10-30 12:45:36 +02:00
Markus Mäkelä
93b9ed744f
MXS-2111: Use authentication_string when password is empty
If the password field in mysql.user is empty, it is possible that the
actual password is stored in the authentication_string field. Most of the
time this happens due to MDEV-16774 which causes the password to be stored
in the authentication_string field.

Also added a test case that verifies the problem and that it is fixed by
this commit.
2018-10-30 12:45:36 +02:00
Markus Mäkelä
2594a0d913
Improve detection of problems caused by MDEV-13453
Instead of looking at the server version, the actual error message should
be inspected. This guarantees that the correct error message is logged
even with custom builds.
2018-10-30 12:45:36 +02:00
Markus Mäkelä
7e21e3aedd
MXS-2115: Fix handshake version string
The intention was to send the lowest backend version string automatically
to the client instead of the default handshake version. This did not work
as the service version string was used instead of the server version.
2018-10-30 12:45:23 +02:00
Markus Mäkelä
262f1d7e47
Fix build failures
The freopen return value caused warnings.
2018-10-19 15:20:34 +03:00
Markus Mäkelä
192563a947
MXS-2108: Fix open connection calculation
When a connection to a server is lost and the session command history is
disabled, the session will continue as long as at least one connection is
open. Previously the open connection calculation used the same code that
was used when a new session was created which only inspected the
configured server count instead of the actual open connection count.
2018-10-19 15:20:34 +03:00
Markus Mäkelä
6d00dbfc92
Fix mxs2043_select_for_update
Explicitly define the host of the user being created and sync
replication after it.
2018-10-19 15:18:16 +03:00
Markus Mäkelä
f8cf5053bd
MXS-2103: Fix CREATE TEMPORARY TABLE detection
The table creation was not detected as the function used to extract the
table name did not return the fully qualified names. Even if it did return
a fully qualified name, it wouldn't have been correctly processed.
2018-10-18 20:26:58 +03:00
Markus Mäkelä
457d0c21dd
Document error code and SQL state for blocked queries
If the dbfwfilter blocks a query a specific error is returned. This was
not documented and is needed to detect errors sent by the filter.
2018-10-18 02:02:14 +03:00
Markus Mäkelä
230345c98c
Fix on_queries documentation
The combination of values was not documented.
2018-10-18 02:02:14 +03:00
Markus Mäkelä
c3cd119454
Speed up mm test
The test did not use the wait_for_monitor function to sync with the
monitor. This function speeds up the testing greatly by removing
unnecessary sleeps from it.

Also reduced the amount of data inserted into the cluster. There's no real
need to test with large amounts of data as it is only a functional test.
2018-10-16 11:06:06 +03:00
Markus Mäkelä
92057f6ff9
Add more logging to readwritesplit
When a read-only transaction fails due to a connection error, no message
would be logged. Also added an info level message for the case when a
backend connection would get closed before the session is in the correct
state and a debug assertion that the router session should never be closed
when the handleError method is called.
2018-10-16 11:04:57 +03:00
Markus Mäkelä
de653437b2
Document server priority behavior
If all of the candidate servers have the same priority, the server that is
first listed in the servers parameter is chosen.
2018-10-16 11:04:57 +03:00
Esa Korhonen
0a04cb2d48 Clarify namedserverfilter documentation
The example configuration had wrong server names.
2018-10-09 13:42:56 +03:00
Markus Mäkelä
74effa6e7f
MXS-2054: Add test case
Add test case that emulates a hybrid cluster of MariaDB and ColumnStore
instances.
2018-10-04 10:52:40 +03:00
Markus Mäkelä
321435b80e
Fix mysqlmon log copying
The backup file required superuser permissions.
2018-10-03 12:46:54 +03:00
Markus Mäkelä
dad4f55ee6
Save output of mysqlmon tests
Before the tests truncate the log, it can be copied to a backup file. This
allows the whole log to be inspected after the test is complete.
2018-10-02 09:44:02 +03:00
Markus Mäkelä
288fbc8c33
MXS-2075: Only enable stdout redirection for maxscale
The stdout redirection must not be enabled for the other programs as they
are not run as daemon processes.
2018-10-02 09:44:02 +03:00
Markus Mäkelä
048aee1fb7
Print output of failed Travis tests
If a unit test fails, print the output.
2018-10-02 09:44:02 +03:00
Markus Mäkelä
79d1eb19d7
Disable unit test leak checks for DEB packages
The unit tests themselves don't leak memory but some of the core
components of MaxScale do. To ignore this, ASAN_OPTIONS needs to be
defined.
2018-10-02 09:44:02 +03:00
Markus Mäkelä
62e5f988c5
MXS-2075: Redirect stdout and stderr to the log
If the log file is successfully opened, both stdout and stderr are
redirected to it. This helps catch ASAN reports without having to read the
system journal files.

As the output is redirected to a file, some of the output was made visible
only in non-daemon mode. This helps keep the log file clean and readable.
2018-10-02 09:44:02 +03:00
Markus Mäkelä
3fd0c2c407
Stop timeout during slave sync 2018-10-02 09:44:01 +03:00
Markus Mäkelä
7b5985d6be
Add missing connect to mxs682_cyrillic
The connections were used without connecting.
2018-10-02 09:44:01 +03:00
Markus Mäkelä
c7fc00b3d8
Shorten mxs812_1
Three iterations should be adequate for most cases.
2018-10-02 09:44:01 +03:00
Markus Mäkelä
d87d462c76
MXS-2049: Update GSSAPI documentation
Corrected the documentation and provided more details on how to configure
the authenticator.
2018-10-02 09:44:01 +03:00
Markus Mäkelä
f65c890287
MXS-2049: Forward client credentials to backend server
Instead of requesting another set of credentials, the client credentials
are simply forwarded to the backend MariaDB server.
2018-10-02 09:44:01 +03:00
Markus Mäkelä
93d866c6a7
MXS-2073: Add missing TCP_NODELAY for client sockets
The client connections had the Nagle algorithm enabled which could cause
bad performance with smaller workloads. The common network configuration
code in utils.cc, currently used by the backend connections, sets it
properly.
2018-10-02 09:44:00 +03:00
Markus Mäkelä
ee45900648
Remove network variable export file after use
Otherwise the file is left in the current working directory.
2018-10-02 09:44:00 +03:00
Johan Wikman
809ab487b2 Update version number for 2.2 2018-10-01 13:13:40 +03:00
Johan Wikman
c58a461f87 Merge branch '2.2.15' into 2.2 2018-10-01 13:10:05 +03:00