MXS-2938: Log session command info on routing failure

If the session command could not be routed, the log message should contain
the actual command that was routed. This makes failure analysis much
easier.
This commit is contained in:
Markus Mäkelä 2020-03-18 16:28:02 +02:00
parent ae67d88fef
commit 552fdcb88a
No known key found for this signature in database
GPG Key ID: 5CE746D557ACC499

View File

@ -620,7 +620,8 @@ bool RWSplitSession::route_session_write(GWBUF* querybuf, uint8_t command, uint3
}
else
{
MXS_ERROR("Could not route session command: %s. Connection status: %s",
MXS_ERROR("Could not route session command `%s`: %s. Connection status: %s",
sescmd->to_string().c_str(),
attempted_write ? "Write to all backends failed" : "All connections have failed",
get_verbose_status().c_str());
}