All internal code is now inside an anonymous namespace to prevent their
use outside of the compilation unit.
Also fixed the wrong return type of ResourceWatcher::etag.
Executing the commands inside a worker thread allows further improvements
to job queuing but mainly it fixes the problem of loading users when
listeners are allocated at runtime.
When a runtime listener was being created, it was allocated in the admin
thread whereas the listeners created at startup were allocated in the
"main" thread. This caused a minor difference in how administrative
functions were handled by the REST API and MaxAdmin. The only real problem
is that listener allocation depends on being done inside a worker thread
as it lazily initializes some resources.
The memory for the rate limit struct was allocated but it was not assigned
for the service. Also corrected a false debug assertion in
service_refresh_users.
The thread-local user cache removes most of the cross-thread communication
from the user authentication at the cost of increased memory use and extra
network usage when users are loaded.
When enabled, the monitor will redirect servers to replicate from the
current master. Standalone servers and servers replicating from a slave
are redirected.
MXS-1545: handling of slave file EOF refactoring.
Some slave/router state are now checked before any WARN/ERROR messages
about slave file EOF.
The missing “next_file” is always logged with warn.
MXS-1530: check ANNOTATE_ROWS flag in connecting slave.
In MariaDB 10.2.4 replicate_annotate_row_events and
binlog_annotate_row_events have default to ON: this change checks
whether the connecting slave is not has ANNOTATE_ROWS in
blr_slave_binlog_dump(), those ANNOTATE_ROWS events can be sent or not
to the slave.
If the gtid_domain_pos of the master is ever modified,
gtid-variables will have multiple domains. Generally, we are
only interested in the most recent domain. This is tracked in
gtid_domain_id:s and the value of the master is used for
filtering the correct domain from all gtid-values.
Also, use gtid_current_pos instead of gtid_slave_pos. The
advantage of current_pos is that the same variable works also
for master servers. The gtid-handling is now more thorough and
detects some weird situations.
Break lines at 80 characters. Add a Table of Contents and reorder sections
to have the actual tutorial part first.
Things that still need doing:
* Move limitations and other documentation to the actual router
documentation
* Review and simplify examples
Updated all examples to use parameters instead of router_options. Added a
more clear note about router_options being deprecated. Removed unnecessary
parameters from all examples.
The usage of the router_options has become optional in 2.1. This means
that the binlogrouter should not fail to start if no router_options are
defined.
Also lowered the error about master.ini to a warning as it is expected to
happen on a fresh installation.
MXS-1530: check ANNOTATE_ROWS flag in connecting slave.
In MariaDB 10.2.4 replicate_annotate_row_events and
binlog_annotate_row_events have default to ON: this change checks
whether the connecting slave is not has ANNOTATE_ROWS in
blr_slave_binlog_dump(), those ANNOTATE_ROWS events can be sent or not
to the slave.
If given a readily selected master server, Switchover will use it
as the new master. If the given server is invalid, nothing will
happen and an error is returned.
The internal header directory conflicted with in-source builds causing a
build failure. This is fixed by renaming the internal header directory to
something other than maxscale.
The renaming pointed out a few problems in a couple of source files that
appeared to include internal headers when the headers were in fact public
headers.
Fixed maxctrl in-source builds by making the copying of the sources
optional.
The utility and mock classes created for the testing of dbfwfilter
will be used for testing certain aspects of the cache filter.
Consequently better to move them somewhere outside dbfwfilter.
Sofar they will be built separately for each filter.