MXS-2521: Detect COM_STMT_EXECUTE without metadata

If a COM_STMT_EXECUTE has no metadata in it and it has more than one
parameter, it must be routed to the same backend where the previous
COM_STMT_EXECUTE with the same ID was routed to. This prevents MDEV-19811
that is triggered by MaxScale routing the queries to different backends.
This commit is contained in:
Markus Mäkelä
2019-06-26 12:33:46 +03:00
parent a6617f52fc
commit 5eba688c1b
4 changed files with 105 additions and 12 deletions

View File

@ -126,7 +126,7 @@ void RWSplitSession::process_sescmd_response(SRWBackend& backend, GWBUF** ppPack
{
/** Map the returned response to the internal ID */
MXS_INFO("PS ID %u maps to internal ID %lu", resp.id, id);
m_qc.ps_id_internal_put(resp.id, id);
m_qc.ps_store_response(id, *ppPacket);
}
// Discard any slave connections that did not return the same result