mirror of
https://github.com/percona/percona-toolkit.git
synced 2026-04-17 01:01:39 +08:00
Fix and test parser_error_packet() for non-SQL errors.
This commit is contained in:
@@ -9,7 +9,7 @@ BEGIN {
|
||||
use strict;
|
||||
use warnings FATAL => 'all';
|
||||
use English qw(-no_match_vars);
|
||||
use Test::More tests => 6;
|
||||
use Test::More;
|
||||
|
||||
use PerconaTest;
|
||||
|
||||
@@ -76,7 +76,21 @@ ok(
|
||||
'Analysis for tcpdump017 with microsecond timestamps (issue 398)'
|
||||
);
|
||||
|
||||
# #############################################################################
|
||||
# Bug 1103045: pt-query-digest fails to parse non-SQL errors
|
||||
# https://bugs.launchpad.net/percona-toolkit/+bug/1103045
|
||||
# #############################################################################
|
||||
ok(
|
||||
no_diff(
|
||||
sub { pt_query_digest::main(@args, $sample.'tcpdump043.txt',
|
||||
'--report-format', 'header,query_report,profile',
|
||||
qw(--watch-server 127.0.0.1:12345)) },
|
||||
"t/pt-query-digest/samples/tcpdump043_report.txt"
|
||||
),
|
||||
'Analysis for tcpdump043 with connection error (bug 1103045)'
|
||||
);
|
||||
|
||||
# #############################################################################
|
||||
# Done.
|
||||
# #############################################################################
|
||||
exit;
|
||||
done_testing;
|
||||
|
||||
41
t/pt-query-digest/samples/tcpdump043_report.txt
Normal file
41
t/pt-query-digest/samples/tcpdump043_report.txt
Normal file
@@ -0,0 +1,41 @@
|
||||
|
||||
# Overall: 1 total, 1 unique, 0 QPS, 0x concurrency ______________________
|
||||
# Time range: all events occurred at 2013-01-24 13:03:28.672987
|
||||
# Attribute total min max avg 95% stddev median
|
||||
# ============ ======= ======= ======= ======= ======= ======= =======
|
||||
# Exec time 4s 4s 4s 4s 4s 0 4s
|
||||
# Rows affecte 0 0 0 0 0 0 0
|
||||
# Query size 30 30 30 30 30 0 30
|
||||
# Warning coun 0 0 0 0 0 0 0
|
||||
|
||||
# Query 1: 0 QPS, 0x concurrency, ID 0x5D51E5F01B88B79E at byte 0 ________
|
||||
# This item is included in the report because it matches --limit.
|
||||
# Scores: Apdex = 0.50 [1.0]*, V/M = 0.00
|
||||
# Query_time sparkline: | ^ |
|
||||
# Time range: all events occurred at 2013-01-24 13:03:28.672987
|
||||
# Attribute pct total min max avg 95% stddev median
|
||||
# ============ === ======= ======= ======= ======= ======= ======= =======
|
||||
# Count 100 1
|
||||
# Exec time 100 4s 4s 4s 4s 4s 0 4s
|
||||
# Rows affecte 0 0 0 0 0 0 0 0
|
||||
# Query size 100 30 30 30 30 30 0 30
|
||||
# Warning coun 0 0 0 0 0 0 0 0
|
||||
# String:
|
||||
# Error msg Got packets out of order
|
||||
# Errors 1156
|
||||
# Hosts 127.0.0.1
|
||||
# Query_time distribution
|
||||
# 1us
|
||||
# 10us
|
||||
# 100us
|
||||
# 1ms
|
||||
# 10ms
|
||||
# 100ms
|
||||
# 1s ################################################################
|
||||
# 10s+
|
||||
administrator command: Connect\G
|
||||
|
||||
# Profile
|
||||
# Rank Query ID Response time Calls R/Call Apdx V/M Item
|
||||
# ==== ================== ============= ===== ====== ==== ===== ==========
|
||||
# 1 0x5D51E5F01B88B79E 3.5363 100.0% 1 3.5363 0.50 0.00 ADMIN CONNECT
|
||||
Reference in New Issue
Block a user