← Back to team overview

mahara-contributors team mailing list archive

[Bug 1450680] A change has been merged

 

Reviewed:  https://reviews.mahara.org/4724
Committed: http://gitorious.org/mahara/mahara/commit/4757df6fcbbba4afbeada6be8c4b23c9fe98284b
Submitter: Son Nguyen (son.nguyen@xxxxxxxxxxxxxxx)
Branch:    master

commit 4757df6fcbbba4afbeada6be8c4b23c9fe98284b
Author: Robert Lyon <robertl@xxxxxxxxxxxxxxx>
Date:   Fri May 1 13:38:22 2015 +1200

Bug 1450680 - adding in more debugging info to upgrade.php

This will help us better identify problems when upgrading sites and
also allow the community to post more helpful info about their
problems.

Currently patch has only the info I used to help debug a site I was
trying to upgrade from 1.9 -> 15.04

Change-Id: I4918e2e76477028d1bef338d84e662d367378020
Signed-off-by: Robert Lyon <robertl@xxxxxxxxxxxxxxx>

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1450680

Title:
  Need better log_debug output from lib/db/upgrade.php

Status in Mahara ePortfolio:
  In Progress

Bug description:
  One of the most annoying things about db locking up during upgrade is
  you don't know where abouts in the upgrade you are - because it
  doesn't error out.

  It would be most useful if there was:

  1) At least a log_debug line at the start of every if version block -
  there are often comments there so just turn them into log_debug()
  comments.

  2) Every time we loop over a bunch of results we should have a loop counter, so upgrader knows things are still running eg:
    if ($results) {
      $count = 0;
      $limit = 1000;  // where limit is some appropriate number
      $total = count($results);
      foreach ($results as $result) {

         ... the purpose happens here ...

        $count++;
        if (($count % $limit) == 0 || $count == $total) {
            log_debug("$count/$total");
            set_time_limit(30);
        }
    }

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1450680/+subscriptions


References