Fix handling of collected results
The result collection did not reset properly when a non-resultset was returned for a request. As collected result need to be distinguishable from single packet responses, a new buffer type was added. The new buffer type is used by readwritesplit which uses result collection for preparation of prepared statements. Moved the current command tracking to the RWBackend class as the command tracked by the protocol is can change before a response to the executed command is received. Removed a false debug assertion in the mxs_mysql_extract_ps_response function that was triggered when a very large prepared statement response was processed in multiple parts.
This commit is contained in:
committed by
Johan Wikman
parent
948f66f918
commit
a6eeed98fe
@ -69,12 +69,18 @@ public:
|
||||
return m_large_packet;
|
||||
}
|
||||
|
||||
inline uint8_t current_command() const
|
||||
{
|
||||
return m_command;
|
||||
}
|
||||
|
||||
private:
|
||||
reply_state_t m_reply_state;
|
||||
BackendHandleMap m_ps_handles; /**< Internal ID to backend PS handle mapping */
|
||||
bool m_large_packet; /**< Used to store the state of the EOF packet
|
||||
*calculation for result sets when the result
|
||||
* contains very large rows */
|
||||
uint8_t m_command;
|
||||
};
|
||||
|
||||
typedef std::tr1::shared_ptr<RWBackend> SRWBackend;
|
||||
|
||||
Reference in New Issue
Block a user