Merge lp:~percona-dev/percona-server/release-5.1.47-11-microseconds_in_slow_query_log into lp:percona-server/release-5.1.47-11

Proposed by Oleg Tsarev
Status: Merged
Merged at revision: 23
Proposed branch: lp:~percona-dev/percona-server/release-5.1.47-11-microseconds_in_slow_query_log
Merge into: lp:percona-server/release-5.1.47-11
Diff against target: 452 lines (+234/-21)
24 files modified
control-global-slow.patch (+2/-2)
microseconds_in_slow_query_log.patch (+182/-0)
mysql-test/percona_slow_query_log-control_global_slow-master.opt (+1/-1)
mysql-test/percona_slow_query_log-control_global_slow.result (+1/-1)
mysql-test/percona_slow_query_log-control_global_slow.test (+1/-1)
mysql-test/percona_slow_query_log-log_slow_filter-master.opt (+1/-1)
mysql-test/percona_slow_query_log-log_slow_filter.result (+1/-1)
mysql-test/percona_slow_query_log-log_slow_filter.test (+1/-1)
mysql-test/percona_slow_query_log-log_slow_verbosity-master.opt (+1/-1)
mysql-test/percona_slow_query_log-log_slow_verbosity.result (+1/-1)
mysql-test/percona_slow_query_log-log_slow_verbosity.test (+1/-1)
mysql-test/percona_slow_query_log-long_query_time-master.opt (+1/-1)
mysql-test/percona_slow_query_log-long_query_time.result (+1/-1)
mysql-test/percona_slow_query_log-long_query_time.test (+1/-1)
mysql-test/percona_slow_query_log-microseconds_in_slow_query_log-master.opt (+1/-0)
mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.result (+12/-0)
mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.test (+17/-0)
mysql-test/percona_slow_query_log-min_examined_row_limit-master.opt (+1/-1)
mysql-test/percona_slow_query_log-min_examined_row_limit.result (+1/-1)
mysql-test/percona_slow_query_log-min_examined_row_limit.test (+1/-1)
mysql-test/percona_slow_query_log-use_global_long_query_time-master.opt (+1/-1)
mysql-test/percona_slow_query_log-use_global_long_query_time.result (+1/-1)
mysql-test/percona_slow_query_log-use_global_long_query_time.test (+1/-1)
series (+2/-1)
To merge this branch: bzr merge lp:~percona-dev/percona-server/release-5.1.47-11-microseconds_in_slow_query_log
Reviewer Review Type Date Requested Status
Yasufumi Kinoshita (community) Approve
Review via email: mp+26443@code.launchpad.net

Description of the change

To post a comment you must log in.
Revision history for this message
Yasufumi Kinoshita (yasufumi-kinoshita) wrote :

Did you do most of mysql-test script already?

Or do you also request me to test your all changes? :-)

Revision history for this message
Oleg Tsarev (tsarev) wrote :

No, this feature is work, and test a run by me.
All out trouble from bug https://bugs.launchpad.net/percona-server/+bug/587832

Revision history for this message
Yasufumi Kinoshita (yasufumi-kinoshita) wrote :

Though it seems to have bugs. But the patch make bus smaller... Approve for now...

review: Approve
Revision history for this message
Yasufumi Kinoshita (yasufumi-kinoshita) wrote :

Again+

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'control-global-slow.patch'
2--- control-global-slow.patch 2010-05-27 23:11:03 +0000
3+++ control-global-slow.patch 2010-06-01 10:45:41 +0000
4@@ -137,8 +137,8 @@
5 }
6 -
7 +#define SLOG_UG_SETUP(session,value,flag,global) do { \
8-+ if(value & flag == flag) \
9-+ session = global; \
10++ if(value & flag) \
11++ session = global; \
12 + } while(false);
13
14 void log_slow_statement(THD *thd)
15
16=== added file 'microseconds_in_slow_query_log.patch'
17--- microseconds_in_slow_query_log.patch 1970-01-01 00:00:00 +0000
18+++ microseconds_in_slow_query_log.patch 2010-06-01 10:45:41 +0000
19@@ -0,0 +1,182 @@
20+diff -Nur a/sql/log.cc b/sql/log.cc
21+--- a/sql/log.cc 2010-05-31 20:12:17.000000000 +0400
22++++ b/sql/log.cc 2010-05-31 20:13:05.000000000 +0400
23+@@ -524,11 +524,13 @@
24+ */
25+
26+ bool Log_to_csv_event_handler::
27+- log_slow(THD *thd, time_t current_time, time_t query_start_arg,
28++ log_slow(THD *thd, ulonglong current_utime, time_t query_start_arg,
29+ const char *user_host, uint user_host_len,
30+ ulonglong query_utime, ulonglong lock_utime, bool is_command,
31+ const char *sql_text, uint sql_text_len)
32+ {
33++ time_t current_time= my_time_possible_from_micro(current_utime);
34++
35+ TABLE_LIST table_list;
36+ TABLE *table;
37+ bool result= TRUE;
38+@@ -754,14 +756,14 @@
39+ /** Wrapper around MYSQL_LOG::write() for slow log. */
40+
41+ bool Log_to_file_event_handler::
42+- log_slow(THD *thd, time_t current_time, time_t query_start_arg,
43++ log_slow(THD *thd, ulonglong current_utime, time_t query_start_arg,
44+ const char *user_host, uint user_host_len,
45+ ulonglong query_utime, ulonglong lock_utime, bool is_command,
46+ const char *sql_text, uint sql_text_len)
47+ {
48+ Silence_log_table_errors error_handler;
49+ thd->push_internal_handler(&error_handler);
50+- bool retval= mysql_slow_log.write(thd, current_time, query_start_arg,
51++ bool retval= mysql_slow_log.write(thd, current_utime, query_start_arg,
52+ user_host, user_host_len,
53+ query_utime, lock_utime, is_command,
54+ sql_text, sql_text_len);
55+@@ -1045,7 +1047,7 @@
56+ }
57+
58+ for (current_handler= slow_log_handler_list; *current_handler ;)
59+- error= (*current_handler++)->log_slow(thd, current_time, thd->start_time,
60++ error= (*current_handler++)->log_slow(thd, current_utime, thd->start_time,
61+ user_host_buff, user_host_len,
62+ query_utime, lock_utime, is_command,
63+ query, query_length) || error;
64+@@ -2314,12 +2316,13 @@
65+ TRUE - error occured
66+ */
67+
68+-bool MYSQL_QUERY_LOG::write(THD *thd, time_t current_time,
69++bool MYSQL_QUERY_LOG::write(THD *thd, ulonglong current_utime,
70+ time_t query_start_arg, const char *user_host,
71+ uint user_host_len, ulonglong query_utime,
72+ ulonglong lock_utime, bool is_command,
73+ const char *sql_text, uint sql_text_len)
74+ {
75++ time_t current_time= my_time_possible_from_micro(current_utime);
76+ bool error= 0;
77+ DBUG_ENTER("MYSQL_QUERY_LOG::write");
78+
79+@@ -2346,12 +2349,23 @@
80+ last_time= current_time;
81+ struct tm start;
82+ localtime_r(&current_time, &start);
83+-
84+- buff_len= my_snprintf(buff, sizeof buff,
85+- "# Time: %02d%02d%02d %2d:%02d:%02d\n",
86+- start.tm_year % 100, start.tm_mon + 1,
87+- start.tm_mday, start.tm_hour,
88+- start.tm_min, start.tm_sec);
89++ if(opt_microseconds_in_slow_query_log)
90++ {
91++ ulonglong microsecond = current_utime % (1000 * 1000);
92++ buff_len= snprintf(buff, sizeof buff,
93++ "# Time: %02d%02d%02d %2d:%02d:%02d.%010lld\n",
94++ start.tm_year % 100, start.tm_mon + 1,
95++ start.tm_mday, start.tm_hour,
96++ start.tm_min, start.tm_sec,microsecond);
97++ }
98++ else
99++ {
100++ buff_len= my_snprintf(buff, sizeof buff,
101++ "# Time: %02d%02d%02d %2d:%02d:%02d\n",
102++ start.tm_year % 100, start.tm_mon + 1,
103++ start.tm_mday, start.tm_hour,
104++ start.tm_min, start.tm_sec);
105++ }
106+
107+ /* Note that my_b_write() assumes it knows the length for this */
108+ if (my_b_write(&log_file, (uchar*) buff, buff_len))
109+diff -Nur a/sql/log.h b/sql/log.h
110+--- a/sql/log.h 2010-05-31 20:12:22.000000000 +0400
111++++ b/sql/log.h 2010-05-31 20:13:07.000000000 +0400
112+@@ -206,7 +206,7 @@
113+ uint user_host_len, int thread_id,
114+ const char *command_type, uint command_type_len,
115+ const char *sql_text, uint sql_text_len);
116+- bool write(THD *thd, time_t current_time, time_t query_start_arg,
117++ bool write(THD *thd, ulonglong current_utime, time_t query_start_arg,
118+ const char *user_host, uint user_host_len,
119+ ulonglong query_utime, ulonglong lock_utime, bool is_command,
120+ const char *sql_text, uint sql_text_len);
121+@@ -429,7 +429,7 @@
122+ virtual bool init()= 0;
123+ virtual void cleanup()= 0;
124+
125+- virtual bool log_slow(THD *thd, time_t current_time,
126++ virtual bool log_slow(THD *thd, ulonglong current_utime,
127+ time_t query_start_arg, const char *user_host,
128+ uint user_host_len, ulonglong query_utime,
129+ ulonglong lock_utime, bool is_command,
130+@@ -458,7 +458,7 @@
131+ virtual bool init();
132+ virtual void cleanup();
133+
134+- virtual bool log_slow(THD *thd, time_t current_time,
135++ virtual bool log_slow(THD *thd, ulonglong current_utime,
136+ time_t query_start_arg, const char *user_host,
137+ uint user_host_len, ulonglong query_utime,
138+ ulonglong lock_utime, bool is_command,
139+@@ -490,7 +490,7 @@
140+ virtual bool init();
141+ virtual void cleanup();
142+
143+- virtual bool log_slow(THD *thd, time_t current_time,
144++ virtual bool log_slow(THD *thd, ulonglong current_utime,
145+ time_t query_start_arg, const char *user_host,
146+ uint user_host_len, ulonglong query_utime,
147+ ulonglong lock_utime, bool is_command,
148+Двоичные файлы a/sql/log.o и b/sql/log.o различаются
149+diff -Nur a/sql/mysqld.cc b/sql/mysqld.cc
150+--- a/sql/mysqld.cc 2010-05-31 20:12:40.000000000 +0400
151++++ b/sql/mysqld.cc 2010-05-31 20:13:27.000000000 +0400
152+@@ -487,6 +487,7 @@
153+ my_bool opt_log_slow_sp_statements= 0;
154+ my_bool opt_log_slow_timestamp_every= 0;
155+ my_bool opt_use_global_long_query_time= 0;
156++my_bool opt_microseconds_in_slow_query_log= 0;
157+ my_bool lower_case_file_system= 0;
158+ my_bool opt_large_pages= 0;
159+ my_bool opt_myisam_use_mmap= 0;
160+@@ -5786,6 +5787,7 @@
161+ OPT_SUPPRESS_LOG_WARNING_1592,
162+ OPT_USE_GLOBAL_LONG_QUERY_TIME,
163+ OPT_USE_GLOBAL_LOG_SLOW_CONTROL,
164++ OPT_MICROSECONDS_IN_SLOW_QUERY_LOG,
165+ OPT_IGNORE_BUILTIN_INNODB,
166+ OPT_BINLOG_DIRECT_NON_TRANS_UPDATE,
167+ OPT_DEFAULT_CHARACTER_SET_OLD
168+@@ -6798,6 +6800,10 @@
169+ "Control always use global long_query_time or local long_query_time.",
170+ (uchar**) &opt_use_global_long_query_time, (uchar**) &opt_use_global_long_query_time,
171+ 0, GET_BOOL, NO_ARG, 0, 0, 1, 0, 1, 0},
172++ {"microseconds_in_slow_query_log", OPT_MICROSECONDS_IN_SLOW_QUERY_LOG,
173++ "Use microsecond time's precision in slow query log",
174++ (uchar**) &opt_microseconds_in_slow_query_log, (uchar**) &opt_microseconds_in_slow_query_log,
175++ 0, GET_BOOL, NO_ARG, 0, 0, 1, 0, 1, 0},
176+ {"lower_case_table_names", OPT_LOWER_CASE_TABLE_NAMES,
177+ "If set to 1, table names are stored in lowercase on disk and table names "
178+ "will be case-insensitive. Should be set to 2 if you are using a case-"
179+diff -Nur a/sql/mysql_priv.h b/sql/mysql_priv.h
180+--- a/sql/mysql_priv.h 2010-05-31 20:12:45.000000000 +0400
181++++ b/sql/mysql_priv.h 2010-05-31 20:13:19.000000000 +0400
182+@@ -2124,6 +2124,7 @@
183+ extern my_bool opt_log_slow_sp_statements;
184+ extern my_bool opt_log_slow_timestamp_every;
185+ extern my_bool opt_use_global_long_query_time;
186++extern my_bool opt_microseconds_in_slow_query_log;
187+ extern my_bool sp_automatic_privileges, opt_noacl;
188+ extern my_bool opt_old_style_user_limits, trust_function_creators;
189+ extern uint opt_crash_binlog_innodb;
190+diff -Nur a/sql/set_var.cc b/sql/set_var.cc
191+--- a/sql/set_var.cc 2010-05-31 20:12:27.000000000 +0400
192++++ b/sql/set_var.cc 2010-05-31 20:13:14.000000000 +0400
193+@@ -932,6 +932,8 @@
194+ &opt_log_slow_timestamp_every);
195+ static sys_var_bool_ptr sys_use_global_long_query_time(&vars, "use_global_long_query_time",
196+ &opt_use_global_long_query_time);
197++static sys_var_bool_ptr sys_microseconds_in_slow_query_log(&vars, "microseconds_in_slow_query_log",
198++ &opt_microseconds_in_slow_query_log);
199+ /* Synonym of "slow_query_log" for consistency with SHOW VARIABLES output */
200+ static sys_var_log_state sys_var_log_slow(&vars, "log_slow_queries",
201+ &opt_slow_log, QUERY_LOG_SLOW);
202
203=== modified file 'mysql-test/percona_slow_query_log-control_global_slow-master.opt'
204--- mysql-test/percona_slow_query_log-control_global_slow-master.opt 2010-05-27 23:14:07 +0000
205+++ mysql-test/percona_slow_query_log-control_global_slow-master.opt 2010-06-01 10:45:41 +0000
206@@ -1,1 +1,1 @@
207---slow-query-log-file=percona_slow_query_log.log --long-query-time=1
208\ No newline at end of file
209+--slow-query-log-file=percona_slow_query_log-control_global_slow.log --long-query-time=1
210\ No newline at end of file
211
212=== modified file 'mysql-test/percona_slow_query_log-control_global_slow.result'
213--- mysql-test/percona_slow_query_log-control_global_slow.result 2010-05-27 23:14:07 +0000
214+++ mysql-test/percona_slow_query_log-control_global_slow.result 2010-06-01 10:45:41 +0000
215@@ -8,5 +8,5 @@
216 0
217 set global use_global_log_slow_control=none;
218 set global log_slow_verbosity=microtime;
219-cat var/mysqld.1/data/percona_slow_query_log.log | grep "No InnoDB statistics available for this query" | wc -l
220+cat var/mysqld.1/data/percona_slow_query_log-control_global_slow.log | grep "No InnoDB statistics available for this query" | wc -l
221 1
222
223=== modified file 'mysql-test/percona_slow_query_log-control_global_slow.test'
224--- mysql-test/percona_slow_query_log-control_global_slow.test 2010-05-27 23:14:07 +0000
225+++ mysql-test/percona_slow_query_log-control_global_slow.test 2010-06-01 10:45:41 +0000
226@@ -5,6 +5,6 @@
227 SELECT sleep(2);
228 set global use_global_log_slow_control=none;
229 set global log_slow_verbosity=microtime;
230-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep "No InnoDB statistics available for this query" | wc -l;
231+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-control_global_slow.log | grep "No InnoDB statistics available for this query" | wc -l;
232 echo $cmd;
233 exec $cmd;
234
235=== modified file 'mysql-test/percona_slow_query_log-log_slow_filter-master.opt'
236--- mysql-test/percona_slow_query_log-log_slow_filter-master.opt 2010-05-28 14:19:13 +0000
237+++ mysql-test/percona_slow_query_log-log_slow_filter-master.opt 2010-06-01 10:45:41 +0000
238@@ -1,1 +1,1 @@
239---slow-query-log-file=percona_slow_query_log.log --long-query-time=1
240\ No newline at end of file
241+--slow-query-log-file=percona_slow_query_log-log_slow_filter.log --long-query-time=1
242\ No newline at end of file
243
244=== modified file 'mysql-test/percona_slow_query_log-log_slow_filter.result'
245--- mysql-test/percona_slow_query_log-log_slow_filter.result 2010-05-28 14:19:13 +0000
246+++ mysql-test/percona_slow_query_log-log_slow_filter.result 2010-06-01 10:45:41 +0000
247@@ -19,5 +19,5 @@
248 sleep(2)
249 0
250 drop table if exists t;
251-cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l
252+cat var/mysqld.1/data/percona_slow_query_log-log_slow_filter.log | grep Query_time | wc -l
253 2
254
255=== modified file 'mysql-test/percona_slow_query_log-log_slow_filter.test'
256--- mysql-test/percona_slow_query_log-log_slow_filter.test 2010-05-28 14:19:13 +0000
257+++ mysql-test/percona_slow_query_log-log_slow_filter.test 2010-06-01 10:45:41 +0000
258@@ -22,6 +22,6 @@
259 drop table if exists t;
260 --enable_warnings
261
262-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l;
263+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-log_slow_filter.log | grep Query_time | wc -l;
264 echo $cmd;
265 exec $cmd;
266
267=== modified file 'mysql-test/percona_slow_query_log-log_slow_verbosity-master.opt'
268--- mysql-test/percona_slow_query_log-log_slow_verbosity-master.opt 2010-05-28 14:19:13 +0000
269+++ mysql-test/percona_slow_query_log-log_slow_verbosity-master.opt 2010-06-01 10:45:41 +0000
270@@ -1,1 +1,1 @@
271---slow-query-log-file=percona_slow_query_log.log --long-query-time=1
272\ No newline at end of file
273+--slow-query-log-file=percona_slow_query_log-log_slow_verbosity.log --long-query-time=1
274\ No newline at end of file
275
276=== modified file 'mysql-test/percona_slow_query_log-log_slow_verbosity.result'
277--- mysql-test/percona_slow_query_log-log_slow_verbosity.result 2010-05-28 14:19:13 +0000
278+++ mysql-test/percona_slow_query_log-log_slow_verbosity.result 2010-06-01 10:45:41 +0000
279@@ -5,5 +5,5 @@
280 SELECT sleep(2);
281 sleep(2)
282 0
283-cat var/mysqld.1/data/percona_slow_query_log.log | grep InnoDB | wc -l
284+cat var/mysqld.1/data/percona_slow_query_log-log_slow_verbosity.log | grep InnoDB | wc -l
285 1
286
287=== modified file 'mysql-test/percona_slow_query_log-log_slow_verbosity.test'
288--- mysql-test/percona_slow_query_log-log_slow_verbosity.test 2010-05-28 14:19:13 +0000
289+++ mysql-test/percona_slow_query_log-log_slow_verbosity.test 2010-06-01 10:45:41 +0000
290@@ -6,6 +6,6 @@
291
292 SELECT sleep(2);
293
294-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep InnoDB | wc -l;
295+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-log_slow_verbosity.log | grep InnoDB | wc -l;
296 echo $cmd;
297 exec $cmd;
298
299=== modified file 'mysql-test/percona_slow_query_log-long_query_time-master.opt'
300--- mysql-test/percona_slow_query_log-long_query_time-master.opt 2010-05-26 14:18:37 +0000
301+++ mysql-test/percona_slow_query_log-long_query_time-master.opt 2010-06-01 10:45:41 +0000
302@@ -1,1 +1,1 @@
303---slow-query-log-file=percona_slow_query_log.log --long-query-time=2
304\ No newline at end of file
305+--slow-query-log-file=percona_slow_query_log-long_query_time.log --long-query-time=2
306\ No newline at end of file
307
308=== modified file 'mysql-test/percona_slow_query_log-long_query_time.result'
309--- mysql-test/percona_slow_query_log-long_query_time.result 2010-05-28 14:19:13 +0000
310+++ mysql-test/percona_slow_query_log-long_query_time.result 2010-06-01 10:45:41 +0000
311@@ -18,5 +18,5 @@
312 sleep(5)
313 0
314 set long_query_time=2;
315-cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l
316+cat var/mysqld.1/data/percona_slow_query_log-long_query_time.log | grep Query_time | wc -l
317 3
318
319=== modified file 'mysql-test/percona_slow_query_log-long_query_time.test'
320--- mysql-test/percona_slow_query_log-long_query_time.test 2010-05-28 14:19:13 +0000
321+++ mysql-test/percona_slow_query_log-long_query_time.test 2010-06-01 10:45:41 +0000
322@@ -12,6 +12,6 @@
323
324 set long_query_time=2;
325
326-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l;
327+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-long_query_time.log | grep Query_time | wc -l;
328 echo $cmd;
329 exec $cmd;
330
331=== added file 'mysql-test/percona_slow_query_log-microseconds_in_slow_query_log-master.opt'
332--- mysql-test/percona_slow_query_log-microseconds_in_slow_query_log-master.opt 1970-01-01 00:00:00 +0000
333+++ mysql-test/percona_slow_query_log-microseconds_in_slow_query_log-master.opt 2010-06-01 10:45:41 +0000
334@@ -0,0 +1,1 @@
335+--slow-query-log-file=percona_slow_query_log-microseconds_in_slow_query_log.log --long-query-time=1
336\ No newline at end of file
337
338=== added file 'mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.result'
339--- mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.result 1970-01-01 00:00:00 +0000
340+++ mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.result 2010-06-01 10:45:41 +0000
341@@ -0,0 +1,12 @@
342+SELECT sleep(2);
343+sleep(2)
344+0
345+set global microseconds_in_slow_query_log=1;
346+SELECT sleep(2);
347+sleep(2)
348+0
349+set global microseconds_in_slow_query_log=0;
350+cat var/mysqld.1/data/percona_slow_query_log-microseconds_in_slow_query_log.log | grep -E '# Time: [0-9]+ [0-9]+:[0-\9]+:[0-9]+.[0-9]+' | wc -l
351+1
352+cat var/mysqld.1/data/percona_slow_query_log-microseconds_in_slow_query_log.log | grep -E '# Time: [0-9]+ [0-9]+:[0-\9]+:[0-9]+' | wc -l
353+2
354
355=== added file 'mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.test'
356--- mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.test 1970-01-01 00:00:00 +0000
357+++ mysql-test/percona_slow_query_log-microseconds_in_slow_query_log.test 2010-06-01 10:45:41 +0000
358@@ -0,0 +1,17 @@
359+source include/have_innodb.inc;
360+
361+SELECT sleep(2);
362+
363+set global microseconds_in_slow_query_log=1;
364+
365+SELECT sleep(2);
366+
367+set global microseconds_in_slow_query_log=0;
368+
369+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-microseconds_in_slow_query_log.log | grep -E '# Time: [0-9]+ [0-9]+:[0-\9]+:[0-9]+.[0-9]+' | wc -l;
370+echo $cmd;
371+exec $cmd;
372+
373+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-microseconds_in_slow_query_log.log | grep -E '# Time: [0-9]+ [0-9]+:[0-\9]+:[0-9]+' | wc -l;
374+echo $cmd;
375+exec $cmd;
376
377=== modified file 'mysql-test/percona_slow_query_log-min_examined_row_limit-master.opt'
378--- mysql-test/percona_slow_query_log-min_examined_row_limit-master.opt 2010-05-28 14:19:13 +0000
379+++ mysql-test/percona_slow_query_log-min_examined_row_limit-master.opt 2010-06-01 10:45:41 +0000
380@@ -1,1 +1,1 @@
381---slow-query-log-file=percona_slow_query_log.log --long-query-time=1
382\ No newline at end of file
383+--slow-query-log-file=percona_slow_query_log-min_examined_row_limit.log --long-query-time=1
384\ No newline at end of file
385
386=== modified file 'mysql-test/percona_slow_query_log-min_examined_row_limit.result'
387--- mysql-test/percona_slow_query_log-min_examined_row_limit.result 2010-05-28 14:19:13 +0000
388+++ mysql-test/percona_slow_query_log-min_examined_row_limit.result 2010-06-01 10:45:41 +0000
389@@ -19,5 +19,5 @@
390 sleep(2)
391 0
392 drop table if exists t;
393-cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l
394+cat var/mysqld.1/data/percona_slow_query_log-min_examined_row_limit.log | grep Query_time | wc -l
395 2
396
397=== modified file 'mysql-test/percona_slow_query_log-min_examined_row_limit.test'
398--- mysql-test/percona_slow_query_log-min_examined_row_limit.test 2010-05-28 14:19:13 +0000
399+++ mysql-test/percona_slow_query_log-min_examined_row_limit.test 2010-06-01 10:45:41 +0000
400@@ -22,6 +22,6 @@
401 drop table if exists t;
402 --enable_warnings
403
404-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l;
405+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-min_examined_row_limit.log | grep Query_time | wc -l;
406 echo $cmd;
407 exec $cmd;
408
409=== modified file 'mysql-test/percona_slow_query_log-use_global_long_query_time-master.opt'
410--- mysql-test/percona_slow_query_log-use_global_long_query_time-master.opt 2010-05-28 14:19:13 +0000
411+++ mysql-test/percona_slow_query_log-use_global_long_query_time-master.opt 2010-06-01 10:45:41 +0000
412@@ -1,1 +1,1 @@
413---slow-query-log-file=percona_slow_query_log.log --long-query-time=2
414\ No newline at end of file
415+--slow-query-log-file=percona_slow_query_log-use_global_long_query_time.log --long-query-time=2
416\ No newline at end of file
417
418=== modified file 'mysql-test/percona_slow_query_log-use_global_long_query_time.result'
419--- mysql-test/percona_slow_query_log-use_global_long_query_time.result 2010-05-28 14:19:13 +0000
420+++ mysql-test/percona_slow_query_log-use_global_long_query_time.result 2010-06-01 10:45:41 +0000
421@@ -20,5 +20,5 @@
422 0
423 set global long_query_time=2;
424 set global use_global_long_query_time=0;
425-cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l
426+cat var/mysqld.1/data/percona_slow_query_log-use_global_long_query_time.log | grep Query_time | wc -l
427 3
428
429=== modified file 'mysql-test/percona_slow_query_log-use_global_long_query_time.test'
430--- mysql-test/percona_slow_query_log-use_global_long_query_time.test 2010-05-28 14:19:13 +0000
431+++ mysql-test/percona_slow_query_log-use_global_long_query_time.test 2010-06-01 10:45:41 +0000
432@@ -14,6 +14,6 @@
433 set global long_query_time=2;
434 set global use_global_long_query_time=0;
435
436-let $cmd = cat var/mysqld.1/data/percona_slow_query_log.log | grep Query_time | wc -l;
437+let $cmd = cat var/mysqld.1/data/percona_slow_query_log-use_global_long_query_time.log | grep Query_time | wc -l;
438 echo $cmd;
439 exec $cmd;
440
441=== modified file 'series'
442--- series 2010-05-27 23:11:03 +0000
443+++ series 2010-06-01 10:45:41 +0000
444@@ -38,4 +38,5 @@
445 percona-support.patch
446 innodb_deadlock_count.patch
447 bug580324.patch
448-control-global-slow.patch
449\ No newline at end of file
450+control-global-slow.patch
451+microseconds_in_slow_query_log.patch
452\ No newline at end of file

Subscribers

People subscribed via source and target branches

to all changes: