The amount of transactions committed is an important information, but how could you return an accurate value?
This is a question I got from my colleague Ivan, he was challenging with global status values
like COM_COMMIT
or HANDLER_COMMIT
, then
checking in innodb_metrics
… but this was not
accurate.
In fact depending which storage engine you are using, if binary
logs are enabled, if you rollback transactions, if you are using
auto_commit
, etc… all those parameters influence
those values.
So the first question was “What metrics or else should we use ?”. In my opinion, the most accurate “counter” for transactions are the GTIDs.
And this is why I created yet another MySQL Shell plugin that does that calculation:
This plugin is available on my GitHub repository …
[Read more]