cc0299aee6
Update change date of 2.3
2018-06-25 10:07:52 +03:00
8bd9e1d473
Check monitor permissions when reconnecting to server
...
Previously, the permissions would only be checked at monitor start.
Now, the permissions are checked if [Auth Error] is on or server
was reconnected.
2018-06-20 17:54:46 +03:00
58207ec414
MXS-1775 Check disk space warning bit when selecting a new master for failover
...
This also applies to autoselect switchover. The disk space warning has the least
priority, as the other criteria could lead to replication failures. Also, print
the reason the new master was selected over the second best candidate.
2018-06-18 17:59:19 +03:00
019d62bbb8
MXS-1886 Better auto-rejoin error description and tolerance
...
Contains changes from commit 09df01752812444c6e7c409a8957d292f7de63cf
adapted to the 2.3 branch.
2018-06-18 16:35:28 +03:00
d3e9cc9a4f
MXS-1886 Auto-failover error tolerance
...
Contains changes from commit 9e68d8ec3ddf1621f533067021c4b3042f695e80
adapted to the 2.3 branch.
2018-06-18 16:35:28 +03:00
9d961ece3a
Clear galeramon server info in pre_tick
...
The server information in galeramon is gathered every monitoring
interval. To prevent stale information from being used, the server
information needs to be cleared at the start of each monitoring interval.
2018-06-18 14:25:05 +03:00
2f987d0b10
MXS-1845 Only select a master if current master is no longer usable
...
The purpose is to make the selected master server sticky. The master is reselected only
if the current master is no longer a valid master.
2018-06-18 11:06:58 +03:00
de37f1a5c4
Fix cycle find test
2018-06-14 10:28:10 +03:00
5324a1bdaa
MXS-1845 Assign server roles
...
Assign server roles (master, slave, relay master, slave of external master)
for a graph with possibly multiple paths to a slave server.
2018-06-13 17:38:53 +03:00
3f82c25c62
MXS-1845 New algorithm for finding the master server
...
Not yet used, as more is needed to replace the old code. The
algorithm is based on counting the total number of slave nodes
a server has, possibly in multiple layers and/or cycles.
2018-06-13 17:38:33 +03:00
c798a4ae36
Remove use of HASHTABLE in galeramon
...
Replaced the HASHTABLE in galeramon with an std::unordered_map. This
simplifies the code by a great amount and makes it more readable. Removed
the extraneous functions that mostly logged debug information and
simplified the logic by removing redundant checks.
2018-06-11 10:22:23 +03:00
9263a06b15
Fix galera master selection
...
The master selection still used the current status instead of the pending
status. This caused the master selection to lag behind by one monitor
loop.
2018-06-11 10:22:23 +03:00
dd49d4faea
Check pending Synced status in Galeramon
...
The pending status must be used, not the current.
2018-06-08 14:41:11 +03:00
9f5358eac0
Remove server_get_parameter_nolock
...
The function is no longer needed as there is no recursive access to the
server.
2018-06-08 14:41:11 +03:00
8afa8c2c5a
MXS-1775 Add MonitorInstanceSimple class
...
MonitorInstanceSimple is intended for simple monitors that
probe servers in a straightforward fashion. More complex monitors
can be derived directly from MonitorInstance.
2018-06-07 15:13:26 +03:00
2481de260f
Move monitor-dependent code in MariaDBServer to MariaDBMonitor
...
Removes Monitor-dependency from the MariaDBServer-class.
2018-06-06 22:28:38 +03:00
b2a190c2b8
MXS-1775 Add switchover_on_low_disk_space parameter
2018-06-06 15:25:57 +03:00
dc47835ef6
MXS-1775 Add documentation for new monitor parameter
2018-06-06 15:25:57 +03:00
af717426d5
MXS-1775 Load server journal unconditionally
...
The server journal is unconditionally loaded and need not be
done in @c pre_loop.
2018-06-06 15:25:57 +03:00
f600b3a769
MXS-1775 Check disk space in MariaDBMonitor
2018-06-06 15:25:57 +03:00
18ece193bb
MXS-1775 MariaDBMonitor::main() removed
...
Now uses MonitorInstance::main() as all other monitors.
2018-06-06 15:25:57 +03:00
44b1e805a3
MXS-1775 Move MariaDBMonitor functionality to tick
...
Now all is set for moving MariaDBMonitor on top of
MonitorInstance::main.
2018-06-06 15:25:57 +03:00
329a6df662
MXS-1775 Factor out post-processing
...
Further adjustments for being able to move MariaDBMonitor on
top of MonitorInstance::main().
2018-06-06 15:25:57 +03:00
71194d83d3
MXS-1775 Rearrange for moving main loop to MonitorInstance
...
This is another step in the process for moving the main loop
from MariaDBMonitor to MonitorInstance.
2018-06-06 15:25:57 +03:00
70fdd0fc17
Merge branch '2.2' into develop
2018-06-06 08:56:31 +03:00
f2b2951c99
Track the number of performed monitoring intervals
...
Tracking how many times the monitor has performed its monitoring allows
the test framework to consistently wait for an event instead of waiting
for a hard-coded time period. The MaxCtrl `api get` command can be used to
easily extract the numeric value.
2018-06-06 08:46:46 +03:00
17c9ac95bd
MXS-1845 Add unit test for the cycle find algorithm (Tarjan SCC)
...
Only a few test cases for now.
2018-06-05 16:33:51 +03:00
9a0445cd4e
MXS-1845 Save cycle members
...
The saved data may be useful later on. Also includes some cleanup.
2018-06-05 16:25:04 +03:00
7cd19a12a2
MXS-1883 Remove locking during monitor loop
...
Since the admin cannot modify server states any more, the locks are not
required.
2018-06-01 15:03:07 +03:00
37841183b3
Cleanup server.h
...
Renamed, rearranged and clarified status bits. Removed unused macros.
2018-06-01 14:29:51 +03:00
4d7aff4ab9
MXS-1845 Find strongly connected components with multiple slave connections
...
Rewrote the algorithm for clarity.
2018-06-01 14:04:50 +03:00
32c7ae2f9f
MXS-1775 Inherit MariaDBMonitor from mxs::MonitorInstance
...
Start/stop now provided by MonitorInstance. The thread main
function is now virtual and overriden by MariaDBMonitor. Some
additional refactoring is necessary in order to be able to allow
MonitorInstance to handle the main loop.
2018-06-01 13:48:15 +03:00
5219245a04
MXS-1775 Reset server info in MariaDBMonitor::configure()
...
That way, MariaDBMonitor no longer needs a custome start() function.
2018-06-01 13:48:15 +03:00
be3bdc7bc9
MXS-1775 Rename MariaDBMonitor::main_loop() to main()
...
To make it compatible with mxs::MonitorInstance.
2018-06-01 13:48:15 +03:00
a82c5911e5
MXS-1775 Rename m_monitor_base to m_monitor
...
To make it compatible with how the variable is named
in maxscale::MonitorInstance.
2018-06-01 13:48:15 +03:00
f862939dd7
MXS-1775 Make MariaDBMon non-dependent on stop() return value
...
To align it with the behavour or MonitorInstance::stop()
2018-06-01 13:48:15 +03:00
62f3e89ae7
MXS-1775 Tilt MariaDbMon towards maxscale::MonitorInstance
...
- m_status -> m_state
- m_keep_running -> m_shutdown
- load_config_params() -> configure()
2018-06-01 13:48:15 +03:00
ebcb807438
MXS-1775 Add default implementations
2018-06-01 13:48:15 +03:00
9b7e37e112
MXS-1775 Change MonitorInstance::configure() prototype
...
Now return boolean, to allow derived class to signal a failure
to configure.
2018-06-01 13:48:15 +03:00
0783af88ed
MXS-1775 Make general cleanup
...
Document and rearrrange so that things look nice and tidy.
2018-06-01 13:48:15 +03:00
76cfe7291d
MXS-1775 Move module entry point to the end of the file
...
Now the same way in all monitors.
2018-06-01 13:48:15 +03:00
b439857a84
MXS-1775 Remove destroy()
...
Now the instance is deleted simply by deleting it.
2018-06-01 13:48:15 +03:00
0833db8a48
MXS-1775 Flush pending status to servers using common code
2018-06-01 13:48:15 +03:00
15b1c270a3
MXS-1775 Check connection in MonitorInstance::tick()
...
Since the connection checking is done in an identical fashion in
all monitors, it can be moved to the base-class.
2018-06-01 13:48:15 +03:00
a8205824f8
MXS-1775 Update statuses the usual way in MMMon
...
As all other monitors MMMon now only manipulates the pending_status
of the monitor object during analysis and only in the end touches
the server status.
2018-06-01 13:48:15 +03:00
4a5ed6ce7f
MXS-1775 Fix GaleraMonitor to update pending_status
2018-06-01 13:48:15 +03:00
c0ace6a694
MXS-1775 Rename server_clear_set_status
...
Renamed to server_clear_set_status_nolock, like all other non-locking
functions are called. Rename arguments to be self-explanatory.
2018-06-01 13:48:15 +03:00
f50ebfce2a
MXS-1775 Set/clear initial bits similarly in all monitors
2018-06-01 13:48:15 +03:00
8fed6752bd
MXS-1775 Fix NDPCMonitor to update pending_status
...
Instead of continuously updating the status of the server object,
the monitor should update the pending_status of the monitor object
and then only at the end update the status of the server object.
2018-06-01 13:48:15 +03:00
ced063b1a0
MXS-1775 Fix GRMon to update pending_status
...
Instead of continuously updating the status of the server object,
the monitor should update the pending_status of the monitor object
and then only at the end update the status of the server object.
2018-06-01 13:48:15 +03:00