[MXS-584] binlog_router disconnects client after wrong sql Created: 2016-02-16  Updated: 2017-12-01  Resolved: 2016-06-03

Status: Closed
Project: MariaDB MaxScale
Component/s: binlogrouter
Affects Version/s: 1.3.0
Fix Version/s: 1.4.4, 2.0.0

Type: New Feature Priority: Major
Reporter: Michael Froehlich Assignee: Massimiliano Pinto (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Environment:

Centos 7


Issue Links:
Relates
relates to MXS-448 Better handling of queries in the bin... Closed
Sprint: 2016-11

 Description   

Hi,

i use two different Python MySQL connectors, which both run sql commands right after the inital connection, like:

set autocommit=0
or
SET @@session.autocommit = OFF

MaxScale does not support the sql from above and prints an error:

error  : Unexpected query from 'nagios'@'1.2.3.4': set autocommit=0
notice : my_binlog: Slave 1.2.3.4, server id 0, disconnected after 0 seconds. 1 SQL commands

This prevents me from getting the slave status via python scripts from maxscale binlog router.

Couldn't this just be a warning instead of disconnecting a slave with wrong sql? Maybe the problem is related to the python connector rather than maxscale.

Regards, Michael



 Comments   
Comment by markus makela [ 2016-02-16 ]

The problem is with the binlogrouter and not the connector. The current implementation expects only valid queries and unexpected queries cause a disconnection. This could be changed to allow various automated tools to do checks on the binlogrouter without disconnecting the client.

Comment by Massimiliano Pinto (Inactive) [ 2016-06-01 ]

SET autocommit =
and
SET @@session.autocommit

are now handled.

Generated at Thu Feb 08 04:00:25 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.