MXS-852: Use stored query type for COM_STMT_EXECUTE

When a COM_STMT_EXECUTE or a COM_STMT_SEND_LONG_DATA command is executed,
the query type of the prepared statement is used. This allows read-only
prepared statements to be load balanced across slaves.
This commit is contained in:
Markus Mäkelä
2017-06-21 16:27:31 +03:00
parent 77f78c4b20
commit 3c4e1e3b4b
6 changed files with 61 additions and 31 deletions

View File

@ -159,7 +159,7 @@ public:
*
* @return True if data was written successfully
*/
bool write(GWBUF* buffer, response_type type = EXPECT_RESPONSE);
virtual bool write(GWBUF* buffer, response_type type = EXPECT_RESPONSE);
/**
* @brief Write an authentication switch request to the backend server