A large part of parse_query was parsing of the actual rule definitions. This made
the function very large and hard to understand. For this reason the definition parsing
was moved to its own function.
The earlier log file based approach for enabling and disabling
messages has now been completely replaced with the syslog priority
based approach.
Similarly as with log files before it is now possible to enable
and disable a log priority for a particular session, even though
it apparently has not been used much.
The local test-programs of the logging has got minimal attention
only to make them compile. They should get an overhaul as they did
not work before either.
Maxadmin earlier gave the impression that you could change whether
messages for different log files could be specifically enabled for
a session. In practice that was true only for trace messages as the
session id and the bitmask telling what logfiles are enabled, were
copied to thread local storage only as far as trace messages were
concered.
The code for setting that information in place is quit short and
efficient, so there is really no reason not to do that always.
This also means that it always will be possible to get your hands
on the session object if there is a need for that.
The code used in the query classifier was not compatible with 10.1 version
of MariaDB and needed to be fine tuned in order for it to work with all
supported versions of MariaDB.
In blr_slave.c under certain conditions, two locks were not released.
That was fixed in another change, and with this change a notice will be
logged if that branch is entered. That way it will be possible to find
out whether this may have been the cause of earlier lock-ups.
In blr_slave.c under certain conditions, two locks were not released.
That was fixed in another change, and with this change a notice will be
logged if that branch is entered. That way it will be possible to find
out whether this may have been the cause of earlier lock-ups.
The regular expression used when cleaning multiline configuration parameters
didn't match trailing backslash characters in pathnames. This caused them to be
added to the next line causing a possible error.
The combination of only one slave being used and the slave_selection_criteria
being LEAST_CURRENT_OPERATIONS can possibly cause a connection pileup on one
slave server. This would skew the query distribution heavily towards the first
available slave even if multiple slave were being used.
Having the maximum number of slave servers to be equal to the total amount of
available slaves allows for a more even and responsive distribution of the
query traffic.
The build files for monitors were referring to monitor_common.c which was
refactored out and combined with monitor.c. Due to this change, maxbinlogcheck
required maxscale_pcre2.c and externcmd.c.
Since localtime is not thread-safe it should not be used in multithreaded
contexts. For this reason all calls to localtime were changed to localtime_r
in code where concurrency issues were possible.
Internal tests were left unchanged because they aren't multithreaded.
Claiming that the loading of maxscale.cnf failed in case of any
error was misleading. Maxscale may not succeed in opening it,
reading it or processing it.
Use of skygw_log_write() in ss_dassert and ss_info_dassert replaced
with the use of MXS_ERROR(). In addition, ss_dassert and ss_info_dassert
are now expressions that require a trailing ;.
The log message was labeled as a warning instead of an error and finding out
the real reason why MaxScale didn't start when a filter wasn't found was difficult.
A buffer was allocated for strlen(event) characters leading to the
name always being truncated by one character. The use of a buffer was
unnecessary and was fixed by using the mon_get_event_name function directly.