889 Commits

Author SHA1 Message Date
MassimilianoPinto
933025b017 Update
Update
2014-05-26 16:49:10 +02:00
MassimilianoPinto
b54ca8e87f Default values for MONITOR_INTERVAL
Default values for MONITOR_INTERVAL
2014-05-26 14:16:56 +02:00
MassimilianoPinto
330c0f6bf7 MONITOR_INTERVAL default added
MONITOR_INTERVAL default added
2014-05-26 14:13:01 +02:00
MassimilianoPinto
b17744fd46 Monitor Version Update
Monitor Version Update
2014-05-26 14:07:04 +02:00
MassimilianoPinto
2f4dbc63aa Merge branch 'develop' into feature-MX-58 2014-05-26 10:35:08 +02:00
MassimilianoPinto
6358634bee Documentation update
Documentation update
2014-05-26 10:33:09 +02:00
MassimilianoPinto
bf00ca8aba GaleraHA support - R/W Splitting with Galera
GaleraHA support - R/W Splitting with Galera
2014-05-26 10:29:34 +02:00
VilhoRaatikka
a819887b07 Added logging to place where authentication with backend fails and the reason is unknown. 2014-05-24 00:07:40 +03:00
VilhoRaatikka
eb8c6cc297 Added SESSION_STATE_ROUTER_READY to server/core/session.c:session_state so that state will be printed correctly as well instead of "Invalid state". 2014-05-23 22:10:21 +03:00
VilhoRaatikka
698e63eaf4 Changed bash-related comparison equality operator '==' to generic '=' 2014-05-23 22:08:57 +03:00
VilhoRaatikka
a6eb7bd743 Added space character between '--' and comment text in sql scripts. 2014-05-23 22:07:32 +03:00
VilhoRaatikka
c28052d5a4 Manual merge from master to develop. Incliding fix for bug #425 http://bugs.skysql.com/show_bug.cgi?id=425 2014-05-21 15:41:39 +03:00
VilhoRaatikka
c5ec3cbc57 Added new criteria for slave selection: LEAST_ROUTER_CONNECTIONS which causes the servers having least connections from same router to become chosen.
Added function pointer array which is indexed by enumerated selection criterias.
Selection criteria can now be switched by modifying config file and reloading it.
2014-05-12 17:03:22 +03:00
VilhoRaatikka
25cb08cc29 Return value of service_alloc wasn't read and caused MaxScale to fail if module load failed. 2014-05-12 16:59:19 +03:00
VilhoRaatikka
b7ae1c1784 Added router_option slave_selection_criteria=[LEAST_GLOBAL_CONNECTIONS(default)|LEAST_BEHIND_MASTER] to readwritesplit section.
The option is reloadable in the same way as max_slave_connections parameter. Option value determines which sort function is called before to sort backend server pointers before selecting them and establishing connections to backends.
2014-05-11 23:59:16 +03:00
VilhoRaatikka
b8618ee7cf Backend, and server connection counters were updated erroneously. As a consequent, backend selection worked wrong and negative connection count values were possible. 2014-05-11 17:25:56 +03:00
VilhoRaatikka
9d1aa06376 Added default value for max_slave_connections=1. It is set when router instance is created. Default value is overwritten if configuration parameter is found.
Added missing makefile to server/modules/routing/test . It is needed for system testing. Prior this fix, 'make testall' failed because the makefile was missing.
2014-05-10 23:27:28 +03:00
VilhoRaatikka
ffce479780 backend connection counter was decreased in freeSession even for those backends which weren't connected. This resulted negative counts and affected on selection algorithm. 2014-05-10 22:21:30 +03:00
MassimilianoPinto
faa7b8de76 temp file removed
temp file removed
2014-05-09 20:15:47 +02:00
MassimilianoPinto
e228baf256 version_string is a new service parameter
version_string is a new service parameter.

Documentation updated and current release is now 0.6.0
2014-05-09 20:13:45 +02:00
VilhoRaatikka
8be4aba223 Added new state to SESSION: SESSION_STATE_STOPPING, which is set in protocol module before calling closeSession (router). THe new state tells that session is closing and DCBs included may not be polling anymore.
Fixed some crash scenarios.
2014-05-08 23:17:35 +03:00
VilhoRaatikka
a1361d9c9e Related to MAX-95, added code which makes it possible to change max_slave_connections parameter value during run time of MaxScale. The change will be effective in rwsplit sessions created after the configuration modification and reload. Note that in order to config modification to be effective, the user must connect the debug interface of MaxScale (telnet) and execute 'reload config'.
In practice, 'reload config' reads config file and updates config parameters of rwsplit router service. In addition to that there is a version number indicating what generation of configuration service holds. When router instance is created (when MaxScale is started) service's config version is copied to router intance. Whenever new client connection (rwsplit session) is started, router instance's config version is checked against that of service's. If versions differ, service's config data is copied to router instance. New session will be started with router instance's config values.
2014-05-02 16:35:40 +03:00
VilhoRaatikka
bb7d583155 Multiple slave connections for read/write split router.
Merge branch 'MAX-95' into develop
2014-04-29 18:23:08 +03:00
VilhoRaatikka
b5e9428ff7 log_manager.cc fixed memory leak, block buffer mutex names weren't freed.
query_classifier.cc use of uninitialized value in skygw_stmt_causes_implicit_commit
config.c crashed if module load failed, use of unitialized value
load_utils.c pretty-printed error
service.c use of uninitialized value in service_add_qualified_param
modules.h function prototype
readwritesplit.c memory leaks
2014-04-29 14:50:09 +03:00
VilhoRaatikka
8a40a44823 Removed this because it is deprecated. 2014-04-29 10:10:09 +03:00
VilhoRaatikka
c927057b5c Fixed two bugs of which one was older.
1. in query_classifier.cc autocommit_enabled, and transaction_active variables maintained their values across different sessions. Now those values are stored in each router_client_ses object.
2. As a part of implementation of MAX-95 session variables were added to BACKEND struct which is shared with all sessions using the SERVICE which the particular BACKEND serves. Now each router_client_ses object has a backend reference struct which includes pointer to BACKEND, DCB and to session command cursor.

Added test - set_autocommit_disabled.sql, test_after_autocommit_disabled.sql - to check that session variable is discarded when session where it belongs terminates.
2014-04-28 23:33:49 +03:00
VilhoRaatikka
391157d460 Ineffective write in is_commit_stmt 2014-04-28 23:17:38 +03:00
VilhoRaatikka
bdefa5c3c8 These are the values that are required for MaxScale build process. If you change them, do not push unless you know what you're doing. Thanks! 2014-04-25 15:41:18 +03:00
VilhoRaatikka
28bc3509cc Added new parameter RW Split Router.max_slave_connections=[<int>|<int>%] which specifies the maximum number of slaves which read/write split router connects in each routing session.
Parameter it read from config file to CONFIG_CONTEXT's parameter list. It is qualified in service.c:service_set_slave_conn_limit and if qualified, the qualified integer value and the value type are copied to the CONFIG_PARAMETER structure.

This CONFIG_PARAMETER struct is cloned (=copied to different memory area) and linked to RW Split SERVICE struct.

When RW Split router_instance is created in readwritesplit.c:createInstance, the value is copied to (new) rwsplit_config_t structure from SERVICE's parameter list.

When new routing session is created in readwritesplit.c:newSession, the rwsplit_config_t structure is copied to ROUTER_CLIENT_SES struct and the actual max_nslaves value is calculated from the config value (if percentage is used).

Tests and many error handling branches are missing but functionality seems to be working.
2014-04-24 22:05:26 +03:00
VilhoRaatikka
04313caf82 Initial implementation of the support for multiple slaves in read/write split router session. Omits configuration changes. 2014-04-23 14:55:04 +03:00
VilhoRaatikka
a6ea56a153 Merge branch 'develop' of https://github.com/skysql/MaxScale into develop 2014-04-16 10:26:00 +03:00
VilhoRaatikka
81af54730a Added missing test files for rwsplit router tests. 2014-04-16 10:25:32 +03:00
VilhoRaatikka
2fcc371606 Added back --skip-innodb to a call argument for libmysqld 2014-04-15 19:22:46 +03:00
VilhoRaatikka
b20ce05ee3 Merge branch 'develop'
Completion of fix to bug #418

http://bugs.skysql.com/show_bug.cgi?id=418
2014-04-15 14:36:43 +03:00
VilhoRaatikka
ac261a038c Merge branch 'master' of https://github.com/skysql/MaxScale 2014-04-15 14:35:32 +03:00
VilhoRaatikka
c994c81a0e Changed the way how autocommit is searched from parse tree. Switched to use typelib instead of explicitly converting and comparing user value. Added more tests for cases where user uses literal values in SET autocommit command. 2014-04-15 14:32:47 +03:00
MassimilianoPinto
e01cbd74ed Bug 409: dcb_final_free now frees dcb->delayq 2014-04-14 10:08:34 +02:00
MassimilianoPinto
a253da7b9c Bug 409: dcb_final_free now frees dcb->delayq
Bug 409: dcb_final_free now frees dcb->delayq
2014-04-14 10:06:00 +02:00
VilhoRaatikka
26c6c331fd Changed is_autocommit_stmt so that client character set can very and the value is compared to strings '0','1','off','on' which are converted to match with the cs of the client prior compare. 2014-04-11 20:02:43 +03:00
VilhoRaatikka
7b40c1ee70 Changed how MaxScale unit test works.
All tests are run by executing 'make testall' in root directory. As a result all directories which contain tests will be entered and tests executed.
After tests, each directory have a test log including the last run's logs only.
Created a global test log, which is specified in test.inc. Test logs from subdirectories are concatenated to this file.
2014-04-10 19:08:28 +03:00
VilhoRaatikka
b9a8f2ce65 Merge branch 'develop' of https://github.com/skysql/MaxScale into develop 2014-04-10 17:11:45 +03:00
VilhoRaatikka
bbf1bc2afa Fix for bug #418
Increased skygw_query_type_t to 16 bits, and corrected the way how those bit fields are checked.
Added tests for cases where autocommit is disabled and corrected old tests.
2014-04-10 17:09:42 +03:00
VilhoRaatikka
2c17dc3edf Bug #418, added functions to query classifier to detect if SET autocommit is called.
Note: this compiles but doesn't work yet properly.
2014-04-09 23:43:03 +03:00
VilhoRaatikka
c86e25eeb8 Added a test for implicitly started trasnaction. 2014-04-07 17:00:31 +03:00
VilhoRaatikka
ce5dc19ecc Added read/write split router tests to a part of makefile structure. 2014-04-01 14:11:48 -07:00
VilhoRaatikka
c7b7b17e0d Added INC_PATH to README according to latest change in build_gateway.inc 2014-03-29 12:41:59 +02:00
VilhoRaatikka
5e3ec5b3c8 Added "--no-defaults" to arguments that are passed to mysql_library_init. It tells to embedded server not to use any external my.cnf configuration file. 2014-03-29 12:27:02 +02:00
VilhoRaatikka
f1acbc6926 build_gateway.inc didn't point to all header directories. Added one base directory for pre-processor. 2014-03-29 10:42:30 +02:00
MassimilianoPinto
4408d7095a Merge branch 'release-0.5' into develop 2014-03-28 17:14:20 +01:00
MassimilianoPinto
1c448fe1c9 Documentation updated
Documentation updated
2014-03-28 17:13:39 +01:00