mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-01 18:25:59 +00:00
PT-2151 fix tests for pt-query-digest (#631)
* PT-2151 - Fix tests for pt-query-digest
Put fix for PT-1908 into the proper place
* PT-2151 - Fix tests for pt-query-digest
Put fix for PT-1554 into the proper place
* PT-2151 - Fix tests for pt-query-digest
Adjusted expected results for the default test t/pt-table-checksum/basics.t, so they do not depend on number of rows in the help tables
* PT-2151 - Fix tests for pt-query-digest
Added additional check for both replicas into t/pt-online-schema-change/preserve_triggers.t to avoid deadlock when ->ok() is doing CHECKSUM
* PT-2151 - Fix tests for pt-query-digest
Added delay to t/pt-table-sync/wait.t, so it waits for the child process to start lagging
* PT-2151 - Fix tests for pt-query-digest
Updated t/pt-query-digest/samples/issue_1196-output-8.0.txt, so it reflects changes in the latest 8.0
* PT-2151 - Fix tests for pt-query-digest
Updated queries against query history table, so they don't fail after e2cf183762
* PT-2151 - Fix tests for pt-query-digest
Fixed PT-813 by comparing query text. Since order itself does not matter, it is not essential to compare by the fingerprint or use any other function that changes the query.
* PT-2151 - Fix tests for pt-query-digest
Adjusted samples files which now should have consistent order after fix for PT-813
* PT-2151 - Fix tests for pt-query-digest
Fixed typo in the SELECT query in the QueryReview package
* PT-2151 - Fix tests for pt-query-digest
Fix for PT-981
* PT-2151 - Fix tests for pt-query-digest
Updated modules for pt-index-usage and fixed tests, because checksum is calculated differently after fix for PT-1554
* PT-2151 - Fix tests for pt-query-digest
Updated modules for pt-diskstats, pt-fk-error-logger, pt-heartbeat, pt-online-schema-change, pt-slave-delay, pt-slave-find, pt-table-checksum, pt-table-sync, pt-upgrade
* PT-2151 - Fix tests for pt-query-digest
Updated lib/IndexUsage.pm, so fix for pt-index-usage is in the correct place
This commit is contained in:
@@ -262,7 +262,7 @@ sub save_results {
|
||||
PTDEBUG && _d("Save query data");
|
||||
my $insert_query_sth = $dbh->prepare(
|
||||
"INSERT IGNORE INTO `$db`.`queries` (query_id, fingerprint, sample) "
|
||||
. " VALUES (CONV(?, 16, 10), ?, ?)");
|
||||
. " VALUES (?, ?, ?)");
|
||||
foreach my $query_id ( keys %{$self->{queries}} ) {
|
||||
my $query = $self->{queries}->{$query_id};
|
||||
$insert_query_sth->execute(
|
||||
@@ -272,7 +272,7 @@ sub save_results {
|
||||
PTDEBUG && _d("Saving index usage data");
|
||||
my $insert_index_usage_sth = $dbh->prepare(
|
||||
"INSERT INTO `$db`.`index_usage` (query_id, db, tbl, idx, cnt) "
|
||||
. "VALUES (CONV(?, 16, 10), ?, ?, ?, ?) "
|
||||
. "VALUES (?, ?, ?, ?, ?) "
|
||||
. "ON DUPLICATE KEY UPDATE cnt = cnt + ?");
|
||||
foreach my $query_id ( keys %{$self->{index_usage}} ) {
|
||||
foreach my $db ( keys %{$self->{index_usage}->{$query_id}} ) {
|
||||
@@ -291,7 +291,7 @@ sub save_results {
|
||||
my $insert_index_alt_sth = $dbh->prepare(
|
||||
"INSERT INTO `$db`.`index_alternatives` "
|
||||
. "(query_id, db, tbl, idx, alt_idx, cnt) "
|
||||
. "VALUES (CONV(?, 16, 10), ?, ?, ?, ?, ?) "
|
||||
. "VALUES (?, ?, ?, ?, ?, ?) "
|
||||
. "ON DUPLICATE KEY UPDATE cnt = cnt + ?");
|
||||
foreach my $query_id ( keys %{$self->{alt_index_usage}} ) {
|
||||
foreach my $db ( keys %{$self->{alt_index_usage}->{$query_id}} ) {
|
||||
|
Reference in New Issue
Block a user