MXS-1778: Add support for MariaDB GTID tracking

The MariaDB implementation allows the last GTID to be tracked with the
`last_gtid` variable. To do this, the configuration option
`session_track_system_variables=last_gtid` must be used or it must be
enabled at runtime.
This commit is contained in:
Markus Mäkelä
2018-05-20 22:35:03 +03:00
parent 6d1c0e5ba6
commit 4ba0ac434b
5 changed files with 41 additions and 16 deletions

View File

@ -314,6 +314,12 @@ typedef enum
static const mxs_mysql_cmd_t MXS_COM_UNDEFINED = (mxs_mysql_cmd_t) - 1;
/**
* A GWBUF property with this name will contain the latest GTID in string form.
* This information is only available in OK packets.
*/
static const char* const MXS_LAST_GTID = "last_gtid";
/**
* List of server commands, and number of response packets are stored here.
* server_command_t is used in MySQLProtocol structure, so for each DCB there is