Fix handling of transactions with large results

If transaction replaying was enabled and a result was returned in more
than one call to clientReply, a NULL value would be added to the statement
which in turn would trigger a debug assertion.

Similarly any following statements in the transaction would be executed
regardless of whether the result was complete.

Renamed the statement execution function to better describe what it does.

Extended the basic functional test case to cover this.
This commit is contained in:
Markus Mäkelä
2018-07-07 01:42:11 +03:00
parent 77a1417479
commit 0614ff4c9d
3 changed files with 32 additions and 4 deletions

View File

@ -202,7 +202,7 @@ private:
void handle_error_reply_client(DCB *backend_dcb, GWBUF *errmsg);
bool handle_error_new_connection(DCB *backend_dcb, GWBUF *errmsg);
void handle_trx_replay();
void trx_replay_next_stmt();
// Do we have at least one open slave connection
bool have_connected_slaves() const;