Upgrading from 1.9 to 15.04 in mysql can timeout on big sites

Bug #1479543 reported by Robert Lyon on 2015-07-29
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
High
Robert Lyon
1.10
High
Robert Lyon
15.04
High
Robert Lyon
15.10
Undecided
Unassigned

Bug Description

If there are lots of artefact and elasticsearch is running then the adding of the 'path' column and updating all the artefacts to have new path value can cause very long upgrade, or even upgrade timing out/locking up the database.

The problem is that there is a trigger on the artefact table - but as the path value is not stored by elasticsearch we don't need to get elasticsearch to reindex all the artefact rows.

So we will drop the trigger for this bit and re-add the trigger after the artefact table has add it's path column added.

Robert Lyon (robertl-9) on 2015-07-29
tags: added: upgrade
Jinelle Foley-Barnes (jinelleb) wrote :

Hey,

What could I do to test this that the Behat's aren't testing?

Cheers,
Jinelle

Robert Lyon (robertl-9) wrote :

This one doesn't need a behat test as all the action is upgrading a site and behat only runs on fresh site

Reviewed: https://reviews.mahara.org/5022
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/c614cf4fdc538c708145a9077664687a52fd4bfe
Submitter: Son Nguyen (<email address hidden>)
Branch: master

commit c614cf4fdc538c708145a9077664687a52fd4bfe
Author: Robert Lyon <email address hidden>
Date: Thu Jul 30 10:38:00 2015 +1200

Bug 1479543: Allowing updating artefact table to run smoother

Mostly for Mysql's benefit but won't hurt postgres to do it this way
as well

Change-Id: Icada6c3945db15279d93c30973eaad7bc2507b13
Signed-off-by: Robert Lyon <email address hidden>

Robert Lyon (robertl-9) on 2015-08-13
Changed in mahara:
status: In Progress → Fix Committed
Mahara Bot (dev-mahara) wrote :

Patch for "1.10_STABLE" branch: https://reviews.mahara.org/5100

Mahara Bot (dev-mahara) wrote :

Patch for "master" branch: https://reviews.mahara.org/5108

Reviewed: https://reviews.mahara.org/5108
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/47728fe119c678aa684887373984a91d2d26842f
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit 47728fe119c678aa684887373984a91d2d26842f
Author: Robert Lyon <email address hidden>
Date: Sat Aug 15 09:16:59 2015 +1200

Bug 1479543: Making sure the last run shows correct total

When updating the artefact table with new 'path' option

Change-Id: I6f236f53e907cb4f686c8973c9a98502fc0186ed
Signed-off-by: Robert Lyon <email address hidden>

Mahara Bot (dev-mahara) wrote :

Patch for "15.04_STABLE" branch: https://reviews.mahara.org/5110

Reviewed: https://reviews.mahara.org/5100
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/f1dbbaa734c77d6ca7d96ad87f052d674c7ca5e0
Submitter: Robert Lyon (<email address hidden>)
Branch: 1.10_STABLE

commit f1dbbaa734c77d6ca7d96ad87f052d674c7ca5e0
Author: Robert Lyon <email address hidden>
Date: Thu Jul 30 10:38:00 2015 +1200

Bug 1479543: Allowing updating artefact table to run smoother

Mostly for Mysql's benefit but won't hurt postgres to do it this way
as well

Change-Id: Icada6c3945db15279d93c30973eaad7bc2507b13
Signed-off-by: Robert Lyon <email address hidden>

Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/5109
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/fee762dd06cba3e7932b0cd6ac66c39c547490ef
Submitter: Robert Lyon (<email address hidden>)
Branch: 1.10_STABLE

commit fee762dd06cba3e7932b0cd6ac66c39c547490ef
Author: Robert Lyon <email address hidden>
Date: Sat Aug 15 09:16:59 2015 +1200

Bug 1479543: Making sure the last run shows correct total

When updating the artefact table with new 'path' option

Change-Id: I6f236f53e907cb4f686c8973c9a98502fc0186ed
Signed-off-by: Robert Lyon <email address hidden>

Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/5098
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/5a712a368d544593323563fa5ee02048ac977a2a
Submitter: Robert Lyon (<email address hidden>)
Branch: 15.04_STABLE

commit 5a712a368d544593323563fa5ee02048ac977a2a
Author: Robert Lyon <email address hidden>
Date: Thu Jul 30 10:38:00 2015 +1200

Bug 1479543: Allowing updating artefact table to run smoother

Mostly for Mysql's benefit but won't hurt postgres to do it this way
as well

Change-Id: Icada6c3945db15279d93c30973eaad7bc2507b13
Signed-off-by: Robert Lyon <email address hidden>

Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/5110
Committed: https://git.nzoss.org.nz/mahara/mahara/commit/f12e1a8ef96b42ed2dfe611c240c39e85c7b278a
Submitter: Robert Lyon (<email address hidden>)
Branch: 15.04_STABLE

commit f12e1a8ef96b42ed2dfe611c240c39e85c7b278a
Author: Robert Lyon <email address hidden>
Date: Sat Aug 15 09:16:59 2015 +1200

Bug 1479543: Making sure the last run shows correct total

When updating the artefact table with new 'path' option

Change-Id: I6f236f53e907cb4f686c8973c9a98502fc0186ed
Signed-off-by: Robert Lyon <email address hidden>

Robert Lyon (robertl-9) on 2016-11-06
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers