ac61e205d8
MXS-2219 Dynamically create Clustrix servers
...
MaxScale server objects are now created for all Clustrix nodes.
Currently the name is "Clustrix-Server-N" where N is the number
of the node.
The server is created using runtime_create_server() that has been
modified so that it optionally will not persist the created server.
That is probably just a temporary solution as a monitor should not
need to include .../core/internal-stuff.
2019-01-17 11:11:21 +02:00
bd2eb3d5dc
MXS-2219 Allow starting Clx monitor with no servers
2019-01-17 11:11:21 +02:00
89c059411d
MXS-2219 Add health check threshold
...
Make it configurable how many times a node may fail to respond
on the health check port before it is considered to be down.
2019-01-17 11:11:21 +02:00
880842e55d
MXS-2219 Perform cluster monitoring as well
...
Now the monitor
- will frequently ping the health port of each server
- less frequently check from system.membership the actual
number of available nodes
and act accordingly.
Currently, the updated servers are the ones listed in the conf
file. Subsequently this will be changed so that the servers listed
in the configuration file are only used for bootstrapping the monitor
and server objects are then created dynamically according to what is
found in the cluster.
2019-01-17 11:11:21 +02:00
dae99b2acd
Merge branch '2.3' into develop
2019-01-15 15:57:06 +02:00
8cef8b9472
Compile MariaDBMonitor unit tests only if flag is set
2019-01-15 15:44:21 +02:00
b4d91d4b9a
Move query result helper class to maxsql
...
Added some asserts to ensure the class is used correctly.
2019-01-14 10:43:17 +02:00
8b53e30678
MXS-2220 Move server status functions inside class
2019-01-08 15:12:47 +02:00
f8545a0b7f
MXS-2219 Address review comments
2019-01-07 12:59:57 +02:00
4512295e40
MXS-2219 Implement rudimentary Clustrix monitoring
...
The monitor now pings the health check ports of the Clustrix nodes.
A response translates to RUNNING and a non-response to DOWN.
2019-01-07 12:59:27 +02:00
f0f9c21d1c
Merge branch '2.3' into develop
2019-01-07 10:54:42 +02:00
8c437c6440
Fix crash in galeramon
...
An std::string was assigned a null value which will cause a crash.
2019-01-04 12:00:48 +02:00
cf9ac9004e
Fix compilation error
...
A variable had the same name as a type, which confused some compilers.
2019-01-04 10:40:11 +02:00
40485d746c
MXS-2220 Change server name to constant string
2019-01-03 12:13:15 +02:00
09aa54720d
MXS-2220 Read server version using public methods
...
Version related fields have been removed from the public class.
2019-01-03 11:23:14 +02:00
eacf88f6a5
MXS-2220 Add server version and type information struct
...
The old fields are still used.
2018-12-19 13:18:16 +02:00
115feab946
MXS-2164 Add skeleton Clustrix monitor
2018-12-18 15:17:09 +02:00
569c66fa28
MXS-2220 Store server parameters in stl containers
...
The custom parameters are now protected from concurrent access.
2018-12-18 12:34:06 +02:00
6209d737e9
MXS-2220 server_alloc returns internal type
...
Also adds default initializers to SERVER fields.
2018-12-14 10:31:57 +02:00
2b0eac2cd0
Move server disk space threshold setting to private Server-class
...
The setting can be read and written simultaneously and is protected with
a mutex.
The public SERVER-class is now abstract.
2018-12-14 10:18:14 +02:00
8a8ac26e32
Cleanup monitor.hh
...
Also removes an unused field from several monitors.
2018-12-11 10:41:56 +02:00
c0c9a9858d
MXS-2197 Rename maxscale/log.h to maxscale/log.hh
...
In files either include maxscale/log.hh or remove include entirelly
as maxscale/ccdefs.hh includes it.
2018-12-10 12:58:17 +02:00
bec9455a74
MXS-2205 Combine routingworker.h with routingworker.hh
2018-12-05 11:12:20 +02:00
9f721f725e
MXS-2205 Convert maxscale/protocol/mysql.h to .hh
2018-12-05 11:12:20 +02:00
ad12ff6d06
MXS-2196: Rename dcb.h to dcb.hh
2018-12-04 11:50:43 +02:00
8a570eb6a1
MXS-2205 Combine maxscale/monitor.h with maxscale/monitor.hh
2018-12-03 15:28:06 +02:00
97bb7e7e1a
MXS-2205 Combine maxscale/modutil.h with maxscale/modutil.hh
2018-12-03 15:28:06 +02:00
35cdbc7220
MXS-2205 Convert modulecmd.h to .hh
2018-12-03 14:06:02 +02:00
3e5818fcb6
MXS-2205 Convert mysql_utils.h to .hh
2018-12-03 14:05:21 +02:00
344c7dde4a
MXS-2205 Combine internal monitor headers
...
Contents of monitor.h moved to monitor.hh
2018-12-03 13:32:09 +02:00
0c7e737eb7
Move some mysql/mariadb utilities to maxutils
...
Can be used in system tests later on.
2018-11-30 13:03:37 +02:00
77585bdb8c
MXS-2197: Make config.h and service.h C++ headers
...
This is the first step into converting the other headers into C++.
2018-11-30 12:15:57 +02:00
a1e1ac0012
Move string_printf to maxbase
...
Can be used in tests.
2018-11-29 12:21:40 +02:00
55a39268c6
MXS-2163 Make MariaDBMon recognize Clustrix
...
To allow MariaDBMon to be used with Clustrix we need to handle
Clustrix separately as its apparent version is 5.0.45, which is
lower than what MariaDBMon supports. Further, we must ensure that
Clustrix does not query the slave status as there are no slaves
in the M/S sense in a Clustrix cluster.
NOTE: Once there is a specific Clustrix monitor, this code should
be removed.
2018-11-28 15:27:23 +02:00
f87ff431c1
Merge branch '2.2' into 2.3
2018-11-27 11:46:47 +02:00
f41caae5c7
MXS-2175: Fix available_when_donor
...
If a Galera cluster drops down to a single node, the last node would not
be considered valid. During the failure of the second to last node, the
master would also temporarily lose the master status.
The behavior was changed to always keep the cluster UUID until the cluster
size drops down to zero. This guarantees that the same cluster is used as
long as possible.
2018-11-27 09:22:39 +02:00
b47d4a4105
Use max_statement_time
...
Used only with supporting server versions. Using the time limit ensures that
the server interrupts the query at the same point Connector-C would cut the
connection. This prevents lingering queries.
Also, cleans up some associated error messages.
2018-11-23 15:15:44 +02:00
0a5a3309e0
Add missing quotes when printing server names
...
Some of the log messages didn't have the quotes.
2018-11-23 14:02:09 +02:00
fb52e565fe
Store capabilities of monitored server
...
Checking the version number in various places in the code gets confusing.
It's better to check the version in one place and record the relevant data.
2018-11-21 17:36:52 +02:00
01628dd0de
Cleanup server version updating
2018-11-21 17:36:52 +02:00
5d4775cac1
MXS-2168 Update test_cycle_find
...
The test now uses both server id:s and hostname:port combinations.
2018-11-21 10:40:21 +02:00
90da3a4d90
Remove MXS_MONITORED_SERVER mapping from MariaDBMon
...
The mapping was rarely used.
2018-11-21 10:30:11 +02:00
1a046bd453
MXS-2168 Add 'assume_unique_hostnames'-setting to MariaDBMonitor
...
Adds the setting and takes it into use during replication graph creation
and the most important checks.
2018-11-21 10:30:11 +02:00
bba0bc0f31
MXS-2158 Relax requirements for manual rejoin
...
The operation is now allowed even if the rejoining server has empty gtid:s.
Auto-rejoin keeps the safeties on.
2018-11-16 13:03:30 +02:00
6a1cfddb43
MXS-2158 Clean up gtid updating during rejoin
...
Error messages from update_gtids() are now printed. can_replicate_from()
no longer updates gtid:s.
2018-11-16 12:56:24 +02:00
a377a9fc5a
Add gtid event in reset-replication
...
Adds a "FLUSH TABLES" command at the end so that the new master has a non-empty
gtid_binlog_pos after the operation.
2018-11-14 11:01:48 +02:00
14e38e4e08
MXS-2158 Return true if update_gtids() succeeds, even if no data is returned
...
Previously, if the server had no gtid:s, the method would fail leading to
a confusing error message. This could even totally stop the monitor from working
if a recent server version (10.X) did not have any gtid events.
2018-11-14 10:56:42 +02:00
ecc7442358
Detect manual commands faster
...
Previous, MariaDBMonitor would wait until the next monitor interval before detecting
a new manual command. The commands are now checked every 100 ms.
2018-11-08 19:12:00 +02:00
fb3ccc94d6
MXS-1944 Cleanup function parameters
...
The naming and ordering is now a bit more consistent between promote() and demote().
2018-11-07 12:55:59 +02:00
e4e2235297
MXS-1944 Use time limited methods in rejoin
...
Uses switchover time limit, since the typical rejoin of a standalone server
is somewhat similar to a switchover.
2018-11-07 12:55:59 +02:00