[MXS-1113] support of prepared statement (stmt) for schemarouter Created: 2017-01-31  Updated: 2018-07-31  Resolved: 2018-07-31

Status: Closed
Project: MariaDB MaxScale
Component/s: schemarouter
Affects Version/s: 1.4.0, 2.0.0
Fix Version/s: 2.3.0

Type: Task Priority: Major
Reporter: imad el kholti Assignee: Marko Rajala (Inactive)
Resolution: Fixed Votes: 2
Labels: schemarouter, stmt
Environment:

linux


Attachments: File maxscale.cnf     File maxscale_test.php    
Sprint: MXS-SPRINT-62

 Description   

here is a comment from Mr. Markus Mäkelä, Software Engineer , from MariaDB Corporation.

https://groups.google.com/forum/#!topic/maxscale/4TxBg0ukA00

issue :
schemarouter doesn't support prepared statement (stmt) queries, it will route the query to all servers .

maxscale execute every query on both servers (serv_A & serv_B) , it should redirect the query to one where selected database is .
i use schemarouter, it should work as proxy (high availability) .
i see this error only if i used $mysqli->prepare() . it work fine if when i use mysqli_query();
this is what i see on every query (with $mysqli->prepare() ) :
---------------------
2017-01-31 09:35:37 error : Failed to execute select listid,eml from max_test_A.table_1 where userid in serv_B:3306. 42S02 Table 'max_test_A.table_1' doesn't exist
---------------------------

maxscale.cnf & script of stmt of test are in attachments .



 Comments   
Comment by Alex Boag-Munroe [ 2017-06-28 ]

SchemaRouter is almost perfect for our need to shard over 2000 schemas, but lack of prepared statement support is an absolute show stopper, for hopefully obvious reasons.

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