summaryrefslogtreecommitdiff
path: root/FS/FS
diff options
context:
space:
mode:
authorivan <ivan>2009-02-22 21:08:00 +0000
committerivan <ivan>2009-02-22 21:08:00 +0000
commit078812ef1d27fc80e6bd4922bbe389e1e2048414 (patch)
tree2ca9a32c1d831345bddf37e612c90b97784e645f /FS/FS
parent23f501dcf377abba434465606530f296c9e64d3f (diff)
a better rough idea of where freeside-upgrade spends time
Diffstat (limited to 'FS/FS')
-rw-r--r--FS/FS/Upgrade.pm5
1 files changed, 5 insertions, 0 deletions
diff --git a/FS/FS/Upgrade.pm b/FS/FS/Upgrade.pm
index f10ff06ea..97f24d403 100644
--- a/FS/FS/Upgrade.pm
+++ b/FS/FS/Upgrade.pm
@@ -51,6 +51,8 @@ sub upgrade {
if ( $class->can('_upgrade_data') ) {
warn "Upgrading $table...\n";
+ my $start = time;
+
my $oldAutoCommit = $FS::UID::AutoCommit;
local $FS::UID::AutoCommit = 0;
$FS::UID::AutoCommit = 0;
@@ -60,6 +62,9 @@ sub upgrade {
if ( $oldAutoCommit ) {
dbh->commit or die dbh->errstr;
}
+
+ #warn "\e[1K\rUpgrading $table... done in ". (time-$start). " seconds\n";
+ warn " done in ". (time-$start). " seconds\n";
} else {
warn "WARNING: asked for upgrade of $table,".