From: Alexander Ebert Date: Sun, 2 Jun 2013 20:55:52 +0000 (+0200) Subject: More debugging X-Git-Tag: 2.0.0_Beta_3~26^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d4d2a5352e17435185ecbc1bc637e96f953ce3d6;p=GitHub%2FWoltLab%2FWCF.git More debugging --- diff --git a/wcfsetup/install/files/lib/system/WCFSetup.class.php b/wcfsetup/install/files/lib/system/WCFSetup.class.php index 64c9073f00..7d889ea878 100644 --- a/wcfsetup/install/files/lib/system/WCFSetup.class.php +++ b/wcfsetup/install/files/lib/system/WCFSetup.class.php @@ -730,7 +730,11 @@ class WCFSetup extends WCF { $GLOBALS['__db'] = array( 'parse' => 0, 'modify' => 0, - 'insert' => 0 + 'insert' => 0, + 'tableCount' => 0, + 'table' => 0, + 'default' => 0, + 'defaultCount' => 0 ); // execute sql queries diff --git a/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php b/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php index 48223d7949..0a7cd7e246 100644 --- a/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php +++ b/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php @@ -114,7 +114,10 @@ class SQLParser { } } + $s = microtime(true); $this->executeCreateTableStatement($tableName, $columns, $indices); + $GLOBALS['__db']['tableCount']++; + $GLOBALS['__db']['table'] += round(microtime(true) - $s, 3); } break; @@ -201,7 +204,10 @@ class SQLParser { case 'INSERT': case 'UPDATE': case 'DELETE': + $s = microtime(true); $this->executeStandardStatement($query); + $GLOBALS['__db']['defaultCount']++; + $GLOBALS['__db']['default'] += round(microtime(true) - $s, 3); break; } }