Commit Graph

8824 Commits

Author SHA1 Message Date
6fdb7ed089 Merge remote-tracking branch 'origin/2.3' into 2.4 2020-03-30 10:23:35 +03:00
7b00d2c01b MXS-2942: Only DELETE monitors with no servers
The behavior is now according to the documentation and is consistent with
how services behave.
2020-03-30 08:53:54 +03:00
e6ee3aaff4 MXS-2943: Use correct variable 2020-03-26 06:08:56 +02:00
557a108940 MXS-2943: Add ColumnStore-as-a-plugin support
The version of the ColumnStore that is distributed as a plugin with
MariaDB is now correctly detected.
2020-03-25 15:33:15 +02:00
b98b8f9d4a MXS-2939: Fix reconnection with session commands
Session commands did not trigger a reconnection process which caused
sessions to be closed in cases where recovery was possible.

Added a test case that verifies the patch fixes the problem.
2020-03-19 15:12:31 +02:00
552fdcb88a MXS-2938: Log session command info on routing failure
If the session command could not be routed, the log message should contain
the actual command that was routed. This makes failure analysis much
easier.
2020-03-19 15:12:31 +02:00
5984af468c Process EPOLL[RD]HUP after EPOLLIN
This allows COM_QUIT packets to be processed first in case a EPOLLIN and a
EPOLLRDHUP event arrive at the same time. This fixes the pers_01 test.
2020-03-17 15:20:07 +02:00
9609f5d180 Revert "MXS-2920: Allow max_slave_replication_lag=0"
This reverts commit ca69da49911074a9d218f05936282fd72a674af5 and removes
the bug from the release notes.
2020-03-17 06:58:26 +02:00
f5b61e169b Update npm packages
Updated packages due to npm audit warnings.
2020-03-16 11:32:43 +02:00
5217836e83 Update 2.4.8 Change Date
Same as that of 2.3.17. Consequently, only the 2.4 specific files
are updated.
2020-03-16 11:25:59 +02:00
ca69da4991 MXS-2920: Allow max_slave_replication_lag=0
A requirement of no lag should be allowed. The reason why it wasn't was
simply due to the selection of the default value.
2020-03-13 13:23:47 +02:00
76e855dc1d MXS-2919: Don't use slaves with unknown lag
If a limit on the replication lag is configured, servers with unmeasured
replication lag should not be used. The code in question did use them even
when a limit was set as the value used for undefined lag was -1 which
always measured lower than the limit.
2020-03-13 13:23:47 +02:00
2eeb583245 MXS-2921: Fix memory leak in alter maxscale
The alteration of core parameters leaked the JSON object.
2020-03-13 11:44:02 +02:00
291d2e987f Improve charset selection
The charset sent in the handshake is now done with the following
priorities:

* First Master server
* Last Slave server
* First Running server or Down server whose charset is known

The change is that server in the Down state to which we've successfully
connected to can also be used as the charset source. This, in addition
with an "empty" default charset, helps avoid the use of the default latin1
charset unless absolutely necessary.
2020-03-12 11:03:04 +02:00
caf3b4cf75 Remove redundant call
The function was already called by mxs_mysql_real_connect.
2020-03-12 11:03:04 +02:00
d0ab797938 Merge branch '2.3' into 2.4 2020-03-12 10:33:57 +02:00
6f018e752b Process error events first
This prevents EPOLLOUT/EPOLLIN events from triggering confusing errors if
an EPOLLERR event happens at the same time.
2020-03-10 14:25:57 +02:00
e0cd6adb26 Update change date for 2.3.18 2020-03-10 10:45:47 +02:00
f7d502d1e1 Use json_object_set_new
The non-set case should only be used when a copy of an existing object is
needed. This fixes a memory leak in Cache::do_get_info.
2020-03-09 07:51:08 +02:00
6f45545e09 Fix call command memory leak
The module command arguments were never freed.
2020-03-09 07:38:53 +02:00
3da2580f09 Fix list modules memory leak
The wrong JSON function was used: the one without the _new suffix will
copy the memory.
2020-03-09 07:31:49 +02:00
2bb914b21e Fix param_type_to_str
Duration wasn't in the switch. Removing the default case allows this to be
detected at compile time.
2020-03-09 07:23:52 +02:00
eb0432b7b2 MXS-2860: Extract socket error only when needed
As the process of extracting the socket error also resets it, it should be
done only when necessary.
2020-03-06 13:56:42 +02:00
9eceeffc04 MXS-2811: Set TLS version with MARIADB_OPT_TLS_VERSION
The ssl_version values now also affect the TLS version used by the
connector.
2020-03-05 21:13:38 +02:00
1bf46fadf6 MXS-2891: Log password hash on mismatch
By logging the password hash when user authentication fails due to a
password mismatch, we can be certain what the client sent and what is the
currently stored value in MaxScale. This should not be on by default which
is why a new parameter is required.
2020-03-04 17:11:34 +02:00
4a5293ebba Merge branch '2.3' into 2.4 2020-03-02 18:05:11 +02:00
67fee60f80 Fix Auth Error server status
The mon_ping_or_connect_to_db resets the MYSQL handle which caused the
loss of the error message. Returning a new enumeration value for
authentication errors solves this problem.
2020-03-02 16:32:35 +02:00
4e5d9099ed Merge commit 'e180c200555576cc1f9bfc77342abba422934e4a' into 2.4 2020-03-02 12:51:57 +02:00
e180c20055 MXS-2899: Update charset only when successful
By updating the server charset only when we successfully query it, the
charset will not change due to network connectivity problems.
2020-02-27 14:18:51 +02:00
9ca2c7f777 Merge branch '2.3' into 2.4 2020-02-24 14:10:19 +02:00
b241f7ed2a MXS-2896: Fix monitor connection creation
The connection is now correctly null after a failed attempt to connect.
2020-02-24 12:02:50 +02:00
405b10ad50 Fix server TLS regression
The code in 2.3 was changed to allow "empty" SSL definitions now that the
system CA is used. The code in 2.4 did not allow this which caused non-TLS
connections to be created when only ssl=true was defined.
2020-02-17 20:03:35 +02:00
5842242e94 Fix debug assert on SSL with system CA
The debug assertion was not updated in the merge.
2020-02-17 20:03:35 +02:00
912cb711e3 MXS-2844: Fix binlogrouter destruction
Binlogrouter services can now be destroyed at runtime.
2020-02-14 08:55:48 +02:00
f576680ed9 Update 2.4.7 change date
Only the files that were not already updated as part of the
2.3.17 release.
2020-02-12 15:21:44 +02:00
fec1698db5 MXS-2889: Fix Replicator hang on shutdown
If a connection to the servers cannot be made, the replicator thread would
never exit.
2020-02-12 13:33:27 +02:00
3fc20d4345 MXS-2822: Use both last_write and last_read
The code relied on last_read for the idle time calculation which caused
the pings that were written to not reset the idle time. This increased the
chance of multiple COM_PING packets being sent to a backend before a reply
was received.
2020-02-12 13:33:27 +02:00
8b763fb88b Merge branch '2.3' into 2.4 2020-02-12 08:27:48 +02:00
919686f7ad Merge branch '2.3.17' into 2.3 2020-02-12 08:22:59 +02:00
d63bd7ca80 Merge branch '2.3' into 2.4 2020-02-11 22:43:49 +02:00
fd875cbf6d Remove faulty debug assertion
The use of the server state is not transactional across multiple uses of
the function. This means that any assertions on the target state can fail
if the monitor updates the state between target selection and the
assertion.
2020-02-11 22:34:39 +02:00
d700fc32ed Merge branch '2.3' into 2.4 2020-02-10 15:58:01 +02:00
c18f9c6bd7 MXS-2883: Handle AuthSwitchRequest packets
The backend didn't expect AuthSwitchRequest packets in response to the
handshake response packets. This is allowed by the protocol and appears to
happen with at least MySQL 8.0.
2020-02-10 15:35:47 +02:00
cfb3f79b54 Update 2.3.17 Change Date 2020-02-10 15:28:38 +02:00
75ba527b1c Merge branch '2.3' into 2.4 2020-02-10 13:59:30 +02:00
ef769573e4 MXS-2880 Fix typo in json output
"seconds_behing_master" -> "seconds_behind_master"
2020-02-10 12:59:30 +02:00
cb016fb90a Merge branch '2.3' into 2.4 2020-02-10 10:47:47 +02:00
39cf6a8000 MXS-2860: Update last_read only on successful reads
This prevents empty or failed reads from updating the last_read flag which
in turn gives us the correct connection idle time when network errors
occur.
2020-02-10 10:46:32 +02:00
98e6bdcd90 MXS-2878: Enforce TLS for Connector-C connections
Connector-C connections now require TLS if the servers are configured with
it.
2020-02-10 10:46:32 +02:00
791d2ade99 Log latest error on broken master connection
When the master goes down, log the latest error if one is present.
2020-02-10 10:46:11 +02:00