Commit Graph

504 Commits

Author SHA1 Message Date
07536611d3 Add ability to extract values from the result set
Extract and action the @master_binlog_checksum value

Store master's uuid for use in show slave status

Support for MariaDB 5.5 masters
2015-02-04 15:59:28 +00:00
6bd8d1b507 Updated options procesign to allow either password= or passwd= for
compatibility with the way we set passwords in other places
2015-02-04 13:12:19 +00:00
8ddb2fa732 Update to support servers that do not support GTID 2015-02-04 13:10:46 +00:00
85c752d15c Updated error handlign in lien with new requirements of the core 2015-02-04 12:15:34 +00:00
add315d795 Updated to reflect the shange to the way servers are stored within services 2015-02-04 11:17:29 +00:00
ea7260b27b Merge branch 'blr' into develop 2015-02-04 10:28:12 +00:00
85a38c9600 Add fix for crash if no router options are supplied 2015-02-04 10:26:55 +00:00
23d920c1a9 Addition of support for show slave status 2015-02-04 10:05:35 +00:00
0083e62c41 Merge branch 'blr' into develop 2015-02-03 17:19:06 +00:00
e9af90e4b6 Add support for:
select @@maxscale_version;
	show variables like "maxscale%"
	show master status
	show slave hosts
2015-02-03 17:14:37 +00:00
048467b447 Fixed issue with simple parser for queries from slaves. 2015-02-03 14:35:22 +00:00
15b2cb64ce Add a default value of uuid 2015-01-30 15:20:59 +00:00
5ac736a14e Fix for CRC in fake rotate events 2015-01-30 14:55:14 +00:00
a786d76852 Fixed typo 2015-01-29 16:04:06 +00:00
00d9787d20 Fixed typo in error log message 2015-01-29 16:01:19 +00:00
a016fdd0b7 Complementary fix to #507, http://bugs.skysql.com/show_bug.cgi?id=507.
Missing braces in get_route_target made the previous fix ineffective.
2015-01-28 12:20:30 +02:00
0a9509168b Addition of cache for server responses. This allows cached responses to be sent
if there is no master avaiable when MaxScale starts
2015-01-28 08:44:13 +00:00
21bb341c7d Fix to bug #507, http://bugs.mariadb.com/show_bug.cgi?id=507
readwritesplit.c:get_route_target routed query to slave although query type was combined QUERY_TYPE_READ | QUERY_TYPE_MASTER_READ, where the latter is supposed to be routed to master.
2015-01-27 15:21:31 +02:00
270c0ebf8a Clean up, added comments, removed some dead code. 2015-01-27 10:24:37 +02:00
b758dc1a4a Clear residual buffered data when reconnecting to the master in all cases 2015-01-26 11:23:46 +00:00
272cd73cad Fix to bug #701, http://bugs.mariadb.com/show_bug.cgi?id=701
debugcmd.c:execute_cmd:added skip counter which adjusts the starting position of next argument correctly thus avoiding cropping the latter quoted argument.
2015-01-19 18:38:46 +02:00
5d1f029260 New fix candidate to bug #698, http://bugs.mariadb.com/show_bug.cgi?id=698
client/test/maxadmin_test.sh: added new cases for testing maxadmin
service.c:dListListeners:fixed NULL-pointer reference
debugcli.h: replaced magic number 80 with constant integer.
cli.c:execute:fixed command buffer overflow
debugcmd.c:convert_arg:restored return value to 0 in case of error
2015-01-19 17:55:02 +02:00
f5d8e2366a modutil.c:modutil_reply_routing_error: Removed GWBUF type flag setting and added flags argument to function prototype so that the caller can set necessary flags and they are then copied to GWBUF which is first created in modutil_reply_rounting_error. 2015-01-17 23:07:06 +02:00
6d2b38d4b6 Complementary fix to #694,http://bugs.mariadb.com/show_bug.cgi?id=694
RWSplit router handles query processing errors that happened in router by sending parse error reply to client. routeQuery fails only when backend has failed.
2015-01-17 22:40:52 +02:00
d362ed227f Merge branch 'develop' of https://github.com/mariadb-corporation/MaxScale into develop 2015-01-17 01:29:50 +02:00
1a76d2d06f Fix to bug #698, http://bugs.mariadb.com/show_bug.cgi?id=698
debugcmd.c:convert_arg returned zero if argument is invalid. That zero was cast to pointer. Using it caused NULL-pointer references. Changed the return value indicating about error to 0x1 which is then handled properly.
2015-01-17 01:24:56 +02:00
885dfb0242 Merge branch 'remove_makefiles' into develop 2015-01-16 18:04:16 +02:00
113ea8381b Complamentary fix to #694, added error flag reset to readconnrouter as well. 2015-01-16 11:56:20 +02:00
da77da803b Complementory fix to bug #694, http://bugs.mariadb.com/show_bug.cgi?id=694
Added new error action to router.h, added functionality to reset error flag from DCB in handleError. Error is reset before every new routing call.
2015-01-16 11:13:42 +02:00
39e4253c81 Fix to bug #694, http://bugs.mariadb.com/show_bug.cgi?id=694
query_classifier.cc: set_query_type lost previous query type if the new was more restrictive. Problem was that if query is both READ and SESSION_WRITE and configuration parameter use_sql_variables_in=all was set, routing target became ambiguous. Replaced call to set_query_type with simply adding new type to type (=bit field) and checking unsupported combinations in readwritesplit.c:get_route_target. If such a case is met, a detailed error is written to error log in readwritesplit.c. mysql_client.c sees the error code and sends an error to client. Then mysql_client.c calls router's handleError which ensures that there are enough backend servers so that the session can continue.
2015-01-15 15:16:22 +02:00
06c2d201e0 remove makefiles and other garbage 2015-01-14 19:08:24 +02:00
b3824a1eaf Clean up bits and pieces, removed some unnecessary checks. 2015-01-14 14:11:19 +02:00
af415f58c3 Add support for select @@max_allowed_packet 2015-01-07 17:38:41 +00:00
c4006d43c2 Fix to Coverity defect 85262 2015-01-06 05:28:58 +02:00
91a3109f4d Fix to bug 638: http://bugs.mariadb.com/show_bug.cgi?id=638
readwritesplit.c:Added missing backend type when using max_slave_replication_lag hint.
2015-01-05 14:28:16 +02:00
468ce72c18 Fix to bug 681: http://bugs.mariadb.com/show_bug.cgi?id=681
Added casts to floating point versions of values when doing divisions.
2015-01-05 13:54:27 +02:00
185e5b82d6 Merge branch 'release-1.0GA' of https://github.com/mariadb-corporation/MaxScale into release-1.0GA 2015-01-05 06:09:39 +02:00
ba009e5fd3 Fixes to Coverity defects 85010 84878 72752 72742 72719 and 73418.
skygw_utils.cc: Added function is_valid_posix_path that checks if a path is POSIX-compliant.
2015-01-05 06:05:56 +02:00
2d3491e123 Additional fix to bug #676
readwritesplit.c:route_session_write: added check that at least one backend is being used.
2015-01-03 01:47:11 +02:00
9be2212d96 Fix to bug #676, http://bugs.mariadb.com/show_bug.cgi?id=676
readwritesplit.c:route_session_write failed if the last backend on all backends list was not in use. THe situation where not all backends are used by routing session is normal especially if max_slave_connections is not set to 100%. Thus session commands may have failed if user was bit unlucky.
Changed the logic so that the function fails (and session is closed) if routing fails to any such backend which is in use in the session.
2015-01-03 01:21:30 +02:00
b3d79f7273 Merge branch 'release-1.0GA' into bug_679_fix 2015-01-02 20:57:28 +02:00
95cd0b93cb Fix to bug 679: http://bugs.mariadb.com/show_bug.cgi?id=679
Added server references to services instead of using a raw pointers to server instances.
Changed all references to service->database to service->dbref.
2015-01-02 20:55:38 +02:00
6228be4284 Fix to bug #678, http://bugs.skysql.com/show_bug.cgi?id=678
tee.c:routeQuery cloned partial MySQL packets to be routed to child router. Problems were due to the use of gwbuf_clone and modutil_MySQL_query which clone/examine only the first buffer from the buffer list which composes GWBUF.
modutil.c: Added function modutil_MySQL_query_len which calculates MySQL packet length and the missing bytecount
2015-01-02 18:32:57 +02:00
f4f537a3e2 Fix to bug #673, http://bugs.skysql.com/show_bug.cgi?id=673
dcb.c:dcb_hashtable_stats:division by zero
hashtable.c:hashtable_get_stats: NULL-pointer reference
service.c:serviceStartPort:set service->users NULL to avoid referring to freed memory
users.c:dcb_usersPrintf: NULL-pointer reference
debugcmd.c:convert_arg: changed return value to 1 in case of error, 0 (==NULL) is valid but it indicates that there are no users loaded.
	execute_cmd: fixed command handling
2014-12-31 21:06:28 +02:00
b0c152b55c Fixed debug assertion and protected read of client DCB's state and consistency. 2014-12-30 10:55:53 +02:00
df0b04a5c0 Fix: accessed released memory in mysql_client.c where dcb->data was released in gw_mysql_do_authentication and accessed afterwards. 2014-12-30 10:36:06 +02:00
635fcf708f Fix to bugs #665, and #664. Potentially to #649.
http://bugs.skysql.com/show_bug.cgi?id=665
http://bugs.skysql.com/show_bug.cgi?id=664
http://bugs.skysql.com/show_bug.cgi?id=649

dcb.c:dcb_final_free: (665):set dcb->session->client pointer to NULL so that it won't be read anymore and other threads won't try to close it.
	dcb_final_free:(664):don't free dcb->data, it is either freed in session_alloc if session creation fails or in session_free only.
session.c:if session creation fails, free dcb->data and remove links between client DCB and session.
mysql_backend.c:(665):gw_backend_close:check that session->client isn't NULL and that client DCB's state is still polling before calling dcb_close for it.
mysql_client.c:gw_mysql_do_authentication:if anything fails, and session_alloc won't be called, free dcb->data.
mysql_common.c:gw_send_authentication_to_backend:if session is already closing then return with error.
2014-12-29 20:19:01 +02:00
8e1e72132b Fix to #645, http://bugs.mariadb.com/show_bug.cgi?id=654
NULL-terminated argument list in case where there are given more arguments than expected.
2014-12-23 18:12:23 +02:00
ff5fe23ce6 dcb.b:dcb_final_free:replaced ((dcb->flags & DCBF_CLONE)==0) with macro !DCB_IS_CLONE(dcb)
readwritesplit.h:Removed invalid macros which assumed that ROUTER_CLIENT_SES->rses_backend_ref always pointed to valid and used backend reference and thus included potential risk of NULL-pointer refernce.
mysql_backend.c and mysql_client.c:avoid executing CHK_PROTOCOL(p) after original DCB has been released the memory.
readwritesplit.c:Replaced RSES_CLEINT_DCB macro with a function which returns client DCB for a given router client session.
2014-12-23 16:10:27 +02:00
d2281d6391 Merge branch 'release-1.0GA' of https://github.com/mariadb-corporation/MaxScale into release-1.0GA 2014-12-23 13:37:12 +02:00