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

@ -1637,7 +1637,7 @@ bool mxs_mysql_extract_ps_response(GWBUF* buffer, MXS_PS_RESPONSE* out)
return rval;
}
uint32_t mxs_mysql_extract_execute(GWBUF* buffer)
uint32_t mxs_mysql_extract_ps_id(GWBUF* buffer)
{
uint32_t rval = 0;
uint8_t id[MYSQL_PS_ID_SIZE];