From d44e5ac935ec50ec48dd3f1599e5fbba39b3278a Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Mon, 29 Mar 2010 12:57:16 -0700 Subject: Add $config['db']['annotate_queries'] option to include caller ID comments into queries. Comment can then be seen in process list, slow query logs on the server, aiding in tracking down unexpected slow queries. SELECT /* queuedaemon.php Ostatus_profile->processPost */ * FROM notice WHERE ( notice.uri = 'http://stormcloud.local/mublog2/notice/479' ) INSERT /* POST Notice::saveNew */ INTO notice (profile_id , content .... --- lib/default.php | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/default.php b/lib/default.php index 10f3f1a97..7b0d08e4c 100644 --- a/lib/default.php +++ b/lib/default.php @@ -72,6 +72,7 @@ $default = 'quote_identifiers' => false, 'type' => 'mysql', 'schemacheck' => 'runtime', // 'runtime' or 'script' + 'annotate_queries' => false, // true to add caller comments to queries, eg /* POST Notice::saveNew */ 'log_queries' => false, // true to log all DB queries 'log_slow_queries' => 0), // if set, log queries taking over N seconds 'syslog' => -- cgit v1.2.3-54-g00ecf