Add forked Maatkit tools in bin/ and their tests in t/.

This commit is contained in:
Daniel Nichter
2011-06-24 16:02:05 -06:00
parent 6c501128e6
commit b4b6376be1
679 changed files with 177876 additions and 3 deletions

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s03
Process 0 plays s08
Process 0 plays s06
Process 0 plays s11
Process 0 plays s02
Process 0 plays s15
Process 0 plays s07
Process 0 plays s13
Process 0 plays s04
Process 0 plays s05
Process 0 plays s12
Process 0 plays s09
Process 0 plays s14
Process 0 plays s01
Process 0 plays s16

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s05
Process 1 plays s03
Process 1 plays s12
Process 2 plays s08
Process 2 plays s09
Process 3 plays s06
Process 3 plays s14
Process 4 plays s11
Process 4 plays s01
Process 5 plays s02
Process 5 plays s16
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s12
Process 1 plays s03
Process 1 plays s09
Process 2 plays s08
Process 2 plays s14
Process 3 plays s06
Process 3 plays s01
Process 4 plays s11
Process 4 plays s16
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s09
Process 1 plays s03
Process 1 plays s14
Process 2 plays s08
Process 2 plays s01
Process 3 plays s06
Process 3 plays s16
Process 4 plays s11
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05
Process 11 plays s12

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s14
Process 1 plays s03
Process 1 plays s01
Process 2 plays s08
Process 2 plays s16
Process 3 plays s06
Process 4 plays s11
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05
Process 11 plays s12
Process 12 plays s09

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s01
Process 1 plays s03
Process 1 plays s16
Process 2 plays s08
Process 3 plays s06
Process 4 plays s11
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05
Process 11 plays s12
Process 12 plays s09
Process 13 plays s14

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s16
Process 1 plays s03
Process 2 plays s08
Process 3 plays s06
Process 4 plays s11
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05
Process 11 plays s12
Process 12 plays s09
Process 13 plays s14
Process 14 plays s01

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 1 plays s03
Process 2 plays s08
Process 3 plays s06
Process 4 plays s11
Process 5 plays s02
Process 6 plays s15
Process 7 plays s07
Process 8 plays s13
Process 9 plays s04
Process 10 plays s05
Process 11 plays s12
Process 12 plays s09
Process 13 plays s14
Process 14 plays s01
Process 15 plays s16

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s08
Process 0 plays s11
Process 0 plays s15
Process 0 plays s13
Process 0 plays s05
Process 0 plays s09
Process 0 plays s01
Process 1 plays s03
Process 1 plays s06
Process 1 plays s02
Process 1 plays s07
Process 1 plays s04
Process 1 plays s12
Process 1 plays s14
Process 1 plays s16

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s06
Process 0 plays s15
Process 0 plays s04
Process 0 plays s09
Process 0 plays s16
Process 1 plays s03
Process 1 plays s11
Process 1 plays s07
Process 1 plays s05
Process 1 plays s14
Process 2 plays s08
Process 2 plays s02
Process 2 plays s13
Process 2 plays s12
Process 2 plays s01

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s11
Process 0 plays s13
Process 0 plays s09
Process 1 plays s03
Process 1 plays s02
Process 1 plays s04
Process 1 plays s14
Process 2 plays s08
Process 2 plays s15
Process 2 plays s05
Process 2 plays s01
Process 3 plays s06
Process 3 plays s07
Process 3 plays s12
Process 3 plays s16

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s02
Process 0 plays s05
Process 0 plays s16
Process 1 plays s03
Process 1 plays s15
Process 1 plays s12
Process 2 plays s08
Process 2 plays s07
Process 2 plays s09
Process 3 plays s06
Process 3 plays s13
Process 3 plays s14
Process 4 plays s11
Process 4 plays s04
Process 4 plays s01

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s15
Process 0 plays s09
Process 1 plays s03
Process 1 plays s07
Process 1 plays s14
Process 2 plays s08
Process 2 plays s13
Process 2 plays s01
Process 3 plays s06
Process 3 plays s04
Process 3 plays s16
Process 4 plays s11
Process 4 plays s05
Process 5 plays s02
Process 5 plays s12

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s07
Process 0 plays s01
Process 1 plays s03
Process 1 plays s13
Process 1 plays s16
Process 2 plays s08
Process 2 plays s04
Process 3 plays s06
Process 3 plays s05
Process 4 plays s11
Process 4 plays s12
Process 5 plays s02
Process 5 plays s09
Process 6 plays s15
Process 6 plays s14

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s13
Process 1 plays s03
Process 1 plays s04
Process 2 plays s08
Process 2 plays s05
Process 3 plays s06
Process 3 plays s12
Process 4 plays s11
Process 4 plays s09
Process 5 plays s02
Process 5 plays s14
Process 6 plays s15
Process 6 plays s01
Process 7 plays s07
Process 7 plays s16

View File

@@ -0,0 +1,17 @@
Found 16 session files.
Process 0 plays s10
Process 0 plays s04
Process 1 plays s03
Process 1 plays s05
Process 2 plays s08
Process 2 plays s12
Process 3 plays s06
Process 3 plays s09
Process 4 plays s11
Process 4 plays s14
Process 5 plays s02
Process 5 plays s01
Process 6 plays s15
Process 6 plays s16
Process 7 plays s07
Process 8 plays s13

View File

@@ -0,0 +1,4 @@
drop database if exists issue_799;
create database issue_799;
use issue_799;
create table t (i int auto_increment unique key);

View File

@@ -0,0 +1,4 @@
-- START SESSION 1
insert into issue_799.t values (0)

View File

@@ -0,0 +1 @@
/* I'm a comment! */ SELECT a FROM tbl1;

View File

@@ -0,0 +1,28 @@
-- These test tables and rows are meant to be used
-- with the mk-log-player sample logs. The sample
-- logs can (should be able to be) played against
-- these dbs and tbls.
--
-- !!! Please Remember !!!
-- If you change even the smallest thing in this file,
-- you must verfiy that the tests still pass. The tests
-- rely closely on these values.
-- Thank you. :-)
DROP DATABASE IF EXISTS mk_log_player_1;
CREATE DATABASE mk_log_player_1;
USE mk_log_player_1;
DROP TABLE IF EXISTS tbl1;
CREATE TABLE tbl1 (
a INT
);
INSERT INTO tbl1 VALUES (1),(3),(5),(7),(9),(11),(13),(15),(17),(19),(21),(NULL),(0),(-10),(492),(4),(-20);
DROP DATABASE IF EXISTS mk_log_player_2;
CREATE DATABASE mk_log_player_2;
USE mk_log_player_2;
DROP TABLE IF EXISTS tbl2;
CREATE TABLE tbl2 (
a INT
);
INSERT INTO tbl2 VALUES (2),(4),(6),(8),(10),(12),(14),(16),(18),(20),(22),(NULL);

View File

@@ -0,0 +1,58 @@
# Time: 071218 11:48:27 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 1 Schema: mk_log_player_1
# Query_time: 0.000012 Lock_time: 0.000000 Rows_sent: 10 Rows_examined: 10
# QC_Hit: No Full_scan: Yes Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
SELECT a FROM tbl1;
# Time: 071218 11:48:57 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 1 Schema: mk_log_player_1
# Query_time: 0.000002 Lock_time: 0.000000 Rows_sent: 0 Rows_examined: 0
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
# administrator command: ping;
# Time: 071218 11:48:57 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 2
# Query_time: 0.010012 Lock_time: 0.000022 Rows_sent: 3 Rows_examined: 3
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
use mk_log_player_2;
SELECT a FROM tbl2;
# Time: 071218 11:49:05 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 1 Schema: mk_log_player_2
# Query_time: 0.000012 Lock_time: 0.000000 Rows_sent: 0 Rows_examined: 0
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
SELECT a FROM mk_log_player_2.tbl2;
# Time: 071218 11:49:07 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 2
# Query_time: 0.000112 Lock_time: 0.000230 Rows_sent: 0 Rows_examined: 0
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
DELETE FROM mk_log_player_2.tbl2 WHERE a IS NULL;
# Time: 071218 11:49:30 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 3 Schema: mk_log_player_1
# Query_time: 0.000012 Lock_time: 0.000000 Rows_sent: 1 Rows_examined: 10
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
use mk_log_player_1;
SELECT a FROM tbl1 WHERE a = 3;
# Time: 071218 11:48:27 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 1 Schema: mk_log_player_1
# Query_time: 0.000012 Lock_time: 0.021000 Rows_sent: 0 Rows_examined: 0
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
UPDATE mk_log_player_1.tbl1 SET a = 100 WHERE a = 1;
# Time: 071218 11:48:27 # User@Host: [SQL_SLAVE] @ []
# Thread_id: 4 Schema: mk_log_player_1
# Query_time: 0.000012 Lock_time: 0.500000 Rows_sent: 0 Rows_examined: 0
# QC_Hit: No Full_scan: No Full_join: No Tmp_table: No Disk_tmp_table: No
# Filesort: No Disk_filesort: No Merge_passes: 0
# No InnoDB statistics available for this query
INSERT INTO mk_log_player_1.tbl1 VALUES (555);

View File

@@ -0,0 +1,61 @@
-- ONE SESSION
USE `mk_log_player_1`
SELECT a FROM tbl1
USE `mk_log_player_2`
SELECT a FROM mk_log_player_2.tbl2
USE `mk_log_player_1`
UPDATE mk_log_player_1.tbl1 SET a = 100 WHERE a = 1
SELECT a FROM tbl1 WHERE a < 10
SELECT * FROM tbl1 WHERE a IS NOT NULL
USE `mk_log_player_2`
SELECT * FROM tbl2 WHERE a > 2
SELECT * FROM tbl2 WHERE a < 1 AND a > 10
SELECT * FROM mk_log_player_1.tbl1 AS t1 LEFT JOIN mk_log_player_2.tbl2 AS t2 ON t1.a = t2.a
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2
USE `mk_log_player_1`
UPDATE mk_log_player_1.tbl1 SET a = 100 WHERE a = 1
SELECT a FROM tbl1 WHERE a < 10
SELECT * FROM tbl1 WHERE a IS NOT NULL
USE `mk_log_player_2`
SELECT * FROM tbl2 WHERE a > 2
SELECT * FROM tbl2 WHERE a < 1 AND a > 10
SELECT * FROM mk_log_player_1.tbl1 AS t1 LEFT JOIN mk_log_player_2.tbl2 AS t2 ON t1.a = t2.a
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2
SELECT a FROM tbl2

View File

@@ -0,0 +1,5 @@
Found 1 session files.
Running processes...
All processes are running; waiting for them to finish...
Process 1 finished with exit status 0.
All processes have finished.

View File

@@ -0,0 +1,18 @@
-- START SESSION 103374
insert into test1.tbl6 (day, tbl5, misccol9type, misccol9, metric11, metric12, secs) values (convert_tz(current_timestamp,'EST5EDT','PST8PDT'), '239', 'foo', 'bar', 1, '1', '16.3574378490448') on duplicate key update metric11 = metric11 + 1, metric12 = metric12 + values(metric12), secs = secs + values(secs)
update test2.tbl8 set last2metric1 = last1metric1, last2time = last1time, last1metric1 = last0metric1, last1time = last0time, last0metric1 = ondeckmetric1, last0time = now() where tbl8 in (10800712)
-- START SESSION 104168
BEGIN
use test1
update test3.tblo as o inner join test3.tbl2 as e on o.animal = e.animal and o.oid = e.oid set e.tblo = o.tblo, e.col3 = o.col3 where e.tblo is null
replace into test4.tbl9(tbl5, day, todo, comment) select distinct o.tbl5, date(o.col3), 'misc', right('foo', 50) from test3.tblo as o inner join test3.tbl2 as e on o.animal = e.animal and o.oid = e.oid where e.tblo is not null and o.col1 > 0 and o.tbl2 is null and o.col3 >= date_sub(current_date, interval 30 day)
update test3.tblo as o inner join test3.tbl2 as e on o.animal = e.animal and o.oid = e.oid set o.tbl2 = e.tbl2, e.col9 = now() where o.tbl2 is null

View File

@@ -0,0 +1,12 @@
-- START SESSION 42
use db1
SELECT foo FROM tbl WHERE col=12345 ORDER BY col
-- START SESSION 11
use my_webstats
SELECT DISTINCT col FROM tbl WHERE foo=20061219