Fix readwritesplit hang when query is queued
Readwritesplit would hang when the query execution is postponed due to the fact that the target server is executing a session command. The number of expected responses was incremented when no response was expected.
This commit is contained in:
@ -226,7 +226,6 @@ bool RWSplitSession::route_single_stmt(GWBUF *querybuf)
|
|||||||
else if (target->has_session_commands())
|
else if (target->has_session_commands())
|
||||||
{
|
{
|
||||||
// We need to wait until the session commands are executed
|
// We need to wait until the session commands are executed
|
||||||
m_expected_responses++;
|
|
||||||
m_query_queue = gwbuf_append(m_query_queue, gwbuf_clone(querybuf));
|
m_query_queue = gwbuf_append(m_query_queue, gwbuf_clone(querybuf));
|
||||||
MXS_INFO("Queuing query until '%s' completes session command", target->name());
|
MXS_INFO("Queuing query until '%s' completes session command", target->name());
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user