Dump statements on unexpected internal state

If a server responds when no response was expected, dump stored
statements. This should help deduce root causes of problems relating to
unexpected responses.
This commit is contained in:
Markus Mäkelä 2018-06-06 21:39:53 +03:00
parent d0feff5eb3
commit 6ba423cf94
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19

View File

@ -1158,6 +1158,7 @@ static void log_unexpected_response(SRWBackend& backend, GWBUF* buffer)
"Query: %s", mxs_mysql_get_command(buffer), backend->name(),
backend->current_command(), sql ? sql : "<not available>");
MXS_FREE(sql);
session_dump_statements(backend->dcb()->session);
ss_dassert(false);
}