ca9c52944b
MXS-2220 Use std::string for protocol and authenticator fields
2019-01-03 12:13:15 +02:00
40485d746c
MXS-2220 Change server name to constant string
2019-01-03 12:13:15 +02:00
5fc2c1f49c
MXS-2220 Store server ports as integers and modify them in methods
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
d1b098d3b0
MXS-2200 Store server version string and type in internal class
2019-01-02 12:53:52 +02:00
6206abde3e
Update Server version in server_set_version
...
The new method was not called by the old function.
2018-12-27 14:44:13 +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
c8fc956b7b
MXS-2220 Combine anonymous namespaces
...
Also clean up file local variables.
2018-12-18 12:34:51 +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
31ceee6d22
MXS-2220 Move persistent DCB settings and handling to the private Server-class
2018-12-18 12:14:44 +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
3f81a37e70
MXS-2220 Move rest of dcb printing functions to private class
2018-12-14 10:18:14 +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
63e334d6c0
MXS-2220 mxs::server_status() accepts status flags
...
The overload is required to get rid of dummy SERVER objects.
2018-12-13 10:20:06 +02:00
84e8efceca
MXS-2220 Use private server class in runtime alter commands
...
This only affects commands started from MaxAdmin.
2018-12-12 16:06:08 +02:00
86574c16fb
Return std::string in server_status()
2018-12-10 15:55:07 +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
1b5b789342
MXS-2208 Move trim-functions from maxscale to maxbase
...
log.h now includes string.hh, which is conceptually wrong, but
log.h will shortly disappear and be superceded by log.hh.
2018-12-10 12:50:07 +02:00
7ca421fe5f
MXS-2196: Fix persistent connections
...
The connections now use the correct parameter.
2018-12-05 15:30:44 +02:00
d96a7dedc5
MXS-2205 Convert maxscale/poll.h to .hh
2018-12-04 14:51:02 +02:00
43c33e9f4a
MXS-2196: Allocate a session before allocating DCBs
...
Allocating the session before a DCB guarantees that at no point will a DCB
have a null session. This further clarifies the concept of the session and
also allows the listener reference to be moved there.
Ideally, the session itself would allocate and assign the client DCB but
since the Listener is the only one who does it, it's acceptable for now.
2018-12-04 11:50:43 +02:00
7a87ff9ce1
MXS-2196: Remove redundant DCB member variables
...
The variables held duplicate information already present in other parts of
the system.
2018-12-04 11:50:43 +02:00
ad12ff6d06
MXS-2196: Rename dcb.h to dcb.hh
2018-12-04 11:50:43 +02:00
3b5e45ceee
MXS-2196: Combine session.h and session.hh
...
Combined the public session headers into one.
2018-12-04 11:43:38 +02:00
36792607d8
MXS-2205 Combine internal/modules.h with internal/modules.hh
2018-12-03 13:36:25 +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
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
01628dd0de
Cleanup server version updating
2018-11-21 17:36:52 +02:00
cbe1483028
MXS-2167: Add support for extra_port
...
This allows MaxScale to connect to the server even when max_connections
has been reached.
2018-11-15 14:24:41 +02:00
f8c132903b
Fix query average measurment and average text output.
...
The query_ended() call was not in the right spot. Tests did not
detect it. Changed textual output to reflect the fact that they
are for RWSplit reads.
2018-11-04 17:18:09 +02:00
e0c46a9c9a
Initialize server version string
...
Could read uninitialized data.
2018-10-16 16:09:38 +03:00
9c52ba5c07
Update release notes and documentation for the Throttle Filter
...
and Adaptive Routing
2018-10-05 13:52:42 +03:00
75ea1b6ea1
Fix formatting of new(std::nothrow)
...
The code previously formatted everything as `new( std::nothrow)`.
2018-10-04 21:50:44 +03:00
e56492c23f
MXS-1777 Make "Sample Max" of the server EMAverage adaptive
...
A rather simple but very effective method as testing shows.
2018-10-04 17:53:57 +03:00
19f8e1697b
Make the Server's EMAverage a member
...
The combined effort of all workers of updating EMAverage is needed for precision,
statistics and making parts of it adaptive (rather than hardcoded or configured).
2018-10-04 17:53:57 +03:00
c95adf1f2e
Add prefix to Server member variables
...
Added the m_ prefix to Server member variables.
2018-09-28 12:18:24 +03:00
3ee5d9a8ea
MXS-2067: Move server lock into Server class
...
The lock for the server is now only visible to the MaxScale core. Changing
the type to std::mutex also allows the use of RAII lock guards.
2018-09-28 12:18:23 +03:00
fc1e36429c
MXS-2067: Replace SPINLOCK with pthread_mutex_t
...
Replaced the SPINLOCK implementation with pthread_mutex_t. The SPINLOCK
interface is still used and will be removed later on.
2018-09-28 12:18:23 +03:00
71ffef5708
Partially revert 4ba011266843857bbd3201e5b925a47e88e1808f
...
Add back leading operator enforcement.
2018-09-20 15:57:30 +03:00
2e069fa892
MXS-1632: Take mxb::atomic::add into use
...
The function now mostly replaces the use of atomic_add_ functions declared
in atomic.h.
2018-09-18 15:21:54 +03:00
62788f39e1
Make response time statistics worker-local
...
Given that the response times across threads are extremely likely to be
nearly identical, the data can be partitioned by worker thread.
2018-09-18 15:21:53 +03:00
d11c78ad80
Format all sources with Uncrustify
...
Formatted all sources and manually tuned some files to make the code look
neater.
2018-09-10 13:22:49 +03:00
c81173e320
Move C++ code out of C headers
...
The additions into the server.h header used C++ language which caused C
programs to fail to compile. Moved the implementation of the EMAverage
class into the private Server class in the server.hh header and exposed it
via functions in the server.h header. Also temporarily moved
almost_equal_server_scores into the public server.hh as there is no
service.hh header.
2018-09-10 11:21:06 +03:00
c447e5cf15
Uncrustify maxscale
...
See script directory for method. The script to run in the top level
MaxScale directory is called maxscale-uncrustify.sh, which uses
another script, list-src, from the same directory (so you need to set
your PATH). The uncrustify version was 0.66.
2018-09-09 22:26:19 +03:00
6351ab9c73
MXS-1777: Initial version of routing based on query response time.
...
The main piece of code, slave selection (backend_cmp_response_time), uses the available
method of pair-wise comparison of slaves. This will be changed to selection using all
available slaves, along with removal of hard coded values.
2018-09-05 17:05:06 +03:00
1e6509423a
MXS-1777: Add an EMAverage to the server struct, and a new slave selection criteria.
...
This is to support calculating the average from a session, and the slave selection criteria to be able to route based on averages. This commit, like the next one, have TODOs which you should feel free to comment on. Undecided things.
2018-09-05 17:05:06 +03:00
26dfb19ea4
Make routingworker.hh public
...
Given that worker.hh was public, it made sense to make routingworker.hh
public as well. This removes the need to include private headers in
modules and allows C++ constructs to be used in C++ code when previously
only the C API was available.
2018-09-04 13:04:08 +03:00
a593d00c65
Simplify failed master detection
...
No longer depends on monitor events as the other operations do not
either. The active_event/new_event detection was removed, as these
only protect against a rare situation. A similar feature which
protects all the cluster modifications will be implemented later.
2018-08-29 17:04:05 +03:00
54dca0963a
Only serialize active server parameters
2018-08-29 11:23:00 +03:00
e260d493fd
Disallow duplicate server parameters
...
By replacing server_add_parameter and server_update_parameter with a
single server_set_parameter function, duplication of parameters is
prevented.
2018-08-29 11:23:00 +03:00