This is part of PT-1554. While I was testing pt-table-checksum
ignore_columns.t was failing and it was because the original method in
pt-table-checksum to wait for the slaves to catch up, wasn't enough.
I added a new method who calls MySQL's SELECT MASTER_POS_WAIT from the
MasterSlave package.
Now, the checksum field is a CHAR(32) instead of a BIGINT.
Previously it was failing on some MySQL versions since the truncated int
it was storing is not consistent. Now, by having an MD5 stored as a
CHAR(32) the checksum is consistent across MySQL and OS versions.
This is a breaking change and pt-query-digest history and review tables
are not backwards compatible.
In different OSes, using BIGINT to store the checksum for a query, will
produce collisions and/or unstable values.
Because of this, I changed the type for the checksum field in the history
table from BIGINT to CHAR(32) and the checksum function is no longer
truncating the MD5_HEX result to 16 chars.
In some OSes/Perl versions, the 'filtered' row is being printed with or
without decimals.
For example, in Ubuntu 16.04/Perl 5.22 it is 100.00 while in Ubuntu
18.04/Perl 5.26 it is 100.
To make it consistent for tests, add a default formating string for the
filtered row.
The use of QRT plugin to monitor the health of production worloads cause the QRT data
to show massive spikes in latency, even thought the workload is relatively unaffected.
Tags: pt-table-checksum
See also: PS-235
This fix adds these improvements:
- Only used roles are being dumped.
- Do no treat roles as regular users so, using --drop won't affect roles.
- If --only=user is specified, only roles for that user will be dumped.
- Specifying --only=role,user will ignore role (as per item #2) so the
role will be dumped ONLY if it was granted to 'user'
- Added new parameter --[no]include-unused-roles
Tags: pt-show-grants
Resolves: PT-1525
See also: PT-1488