Commit Graph

13567 Commits

Author SHA1 Message Date
d2e49c9591 MXS-2448: Assert that connection counts never go negative
The connections should never go below zero. It seems that at least pers_01
test suffers from this.
2019-05-09 13:06:27 +03:00
567ad9b8b8 Fix galeramon regression
The comparisons were wrong: strcasecmp returns 0 for equal strings.
2019-05-09 12:30:29 +03:00
59f2145c00 Allocate blr heartbeat buffer on correct worker
The buffer was allocated on one worker and written on another.
2019-05-09 12:30:29 +03:00
788dc429f8 Do client callback on owning worker
The callback should've been done on the worker that owns the DCB instead
of the main worker.
2019-05-09 12:30:26 +03:00
b313c6d0e7 MXS-2474 Ignore attempts to re-register a housekeeper task
It is an error to register the same task multiple times, but
for a maintenance release it is simpler and less risky to simply
ignore an attempt (that BLR does) to do that.

Allowing a task to be registered anew causes behaviour akin
to a leak.
2019-05-09 10:58:35 +03:00
0423c5528e Merge branch '2.3' into develop 2019-05-08 15:56:35 +03:00
5ea2bab88c Merge branch '2.2' into 2.3 2019-05-08 15:56:08 +03:00
ff1959fda7 Merge branch '2.2.21' into 2.2 2019-05-08 15:55:42 +03:00
73f8bf1f6f Update 2.2.21 release date 2019-05-08 15:49:11 +03:00
1df6495d9a Update release notes on MariaDB-Monitor change 2019-05-08 15:32:08 +03:00
e3b5ba9620 MXS-1973 Support reverse DNS for client hostnames in MaxCtrl
May slow maxscale down when used. Only supported for "list sessions",
"show sessions" and "show session <id>".
2019-05-08 15:04:44 +03:00
0e0342e657 Merge branch '2.3' into develop 2019-05-08 10:38:39 +03:00
a652b6bd5b Add advance(int) to mxs::Buffer iterators
This makes iterating over packets in buffers faster while still
maintaining the requirements for forward iterators. Not using operator+=
makes it clear that this is not a random access iterator.
2019-05-08 10:33:27 +03:00
bad96e411a Merge branch '2.3' into develop 2019-05-08 10:30:58 +03:00
c818b1208a MXS-2455 Recognize transaction rollbacks
All transaction rollback errors have an sql_state like "40XXX".
So, when an error reply is received we check for that and act
accordingly.
2019-05-08 10:00:50 +03:00
0638ea736e Write slave heartbeat in correct thread
The writing should be done on the worker that owns the DCB.
2019-05-08 09:44:55 +03:00
446788f2ed MXS-1799 Add timestamps to retain_last_statements messages 2019-05-07 22:54:31 +03:00
3d66e68e95 MXS-2170 Start MaxScale normally if it gets the same PID as previous
MaxScale

Check is made to see if the found MaxScale PID is owned by the process
itself.
2019-05-07 22:23:46 +03:00
56c27afd0a MXS-2458: add template for Clustrix monitor tests
First implementation of Clustrix setup creation
TODO: move Clustrix installation to MDBCI
2019-05-07 17:17:57 +03:00
4e6ffc0381 Clean up server config parameter handling
Removes helper classes which are no longer required.
2019-05-07 15:39:34 +03:00
9ae25e67a8 Update maintenance number in 2.2 minor branch 2019-05-07 15:27:48 +03:00
a7a2215681 Update release notes and change log 2019-05-07 15:22:37 +03:00
d3a1f5c51f MXS-2463 Prefer range loops
Also consistently use 'kv' as in key-value as the element name
when the collection looped over is a map.
2019-05-07 10:36:21 +03:00
4cf29bea36 MXS-2463 Rename m_nodes to m_nodes_by_id
Makes it obvious it is a map.
2019-05-07 10:36:21 +03:00
3c9ad0e452 MXS-2463 Ignore persisted data if bootstraps have changed
If there have been any changes in the bootstrap servers specified
for the Clustrix monitor, then the persistent connection information
is not used.

Otherwise, if the bootstrap server is changed and inaccessible, we
may connect to another cluster than the intended one.
2019-05-07 10:36:21 +03:00
ff33453e1a MXS-2463 Prepare for another set of queries
Persisted information about dynamic nodes must be used only if
the bootrap information has not been changed, as otherwise we risk
using information that is not valid.
2019-05-07 10:36:21 +03:00
a9c1a8d18a Don't build dependencies with newer compiler 2019-05-07 10:02:37 +03:00
8482337333 Merge branch '2.3' into develop 2019-05-06 20:16:02 +03:00
4e3a581c94 Merge branch '2.2' into 2.3 2019-05-06 20:09:37 +03:00
95fd61b8dc Fix listener search functions
The functions that searched for listeners compared both sockets and
addresses in the same function. This made its use error prone and caused
false positives in some cases.
2019-05-06 19:55:31 +03:00
956b7ee919 Disable unused return value warning 2019-05-06 16:05:50 +03:00
6b8ca35408 Format core source files
Formatted core .cc files according to current uncrustify configuration.
2019-05-06 16:05:50 +03:00
5ac24de6b0 Remove log_to_shm
The feature was removed in 2.3 and was ignored if configured.
2019-05-06 16:05:50 +03:00
20a7170024 Fix unit tests that use durations
The tests that used objects that expected a default value for a duration
failed due to missing parameters.
2019-05-06 15:38:43 +03:00
24df547ac8 Make QC unit test names consistent with other tests
All the other tests have their names in lowercase.
2019-05-06 15:38:42 +03:00
adde085b7d Fix incorrect closing bracket in strlen call
The bracketing was causing heap overflow when trying to run the system
tests.
2019-05-06 13:50:18 +03:00
6f607e13de MXS-2446 Do not assume created server exists
"Once you eliminate the impossible, whatever remains, no matter
 how improbable, must be the truth." Arthur Conan Doyle

Since server objects are never destroyed, currently the only
explanation for the crash described in MXS-2446 is that a server
created at runtime could not, immediately after the creation, be
found using its name.
2019-05-06 12:13:29 +03:00
bc2d877898 Merge branch '2.3' into develop 2019-05-06 10:57:30 +03:00
31a6668420 Add PAM authenticator test
Both a normal PAM user and anonymous user mapping are tested.
2019-05-06 10:44:18 +03:00
96b6acecff MXS-2427 Extend namedserverfilter test
Tests with two targets.
2019-05-06 10:31:51 +03:00
6baf970140 Fix test_dbfwfilter 2019-05-03 16:12:26 +03:00
9a10f64840 Fix test_cacheoptions 2019-05-03 16:09:14 +03:00
86b099b487 MXS-2468 When the URLs change, HTTP GET must be cancelled
If the nodes change while a multi HTTP GET is in process, the
corresponding delayed called must be cancelled. Otherwise we
eventually would end up attempting to update the state of the
nodes using the wrong result.
2019-05-03 15:00:00 +03:00
5ab0876a5f MXS-2468 Allow an http::Async object to be reset 2019-05-03 14:57:41 +03:00
d498f1042c MXS-2467 Allow 0-delay delayed calls
A 0-delay delayed call simply means that it will be invoked as
quickly as possible.
2019-05-03 13:54:42 +03:00
fb0745e3de Merge branch '2.3' into develop 2019-05-03 13:48:57 +03:00
e9144219f5 MXS-2457 Add database firewall test 2019-05-03 13:38:12 +03:00
a3cf1d22c0 MXS-2457 Streamline logging 2019-05-03 13:38:12 +03:00
279edce16e MXS-2457 Add treat_string_as_field to firewall
Necessary if the firewall should be able to block columns when
'ANSI_QUOTES' as enabled and " instead of backticks are used.

Without this, the following

    > set @@sql_mode='ANSI_QUOTES';
    > select "ssn" from person;

will not be blocked if the database firewall has been configured
to block the column ssn.
2019-05-03 13:38:12 +03:00
5833c39a8a MXS-2457 Disable query classifier cache in masking
As the canonicalization is also not aware of 'ANSI_QUOTES', the
cache must be disabled if the masking filter has
'treat_string_arg_as_field' enabled.
2019-05-03 13:38:12 +03:00