← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] lp:~wgrant/launchpad/bug-899776-index into lp:launchpad

 

William Grant has proposed merging lp:~wgrant/launchpad/bug-899776-index into lp:launchpad.

Requested reviews:
  Stuart Bishop (stub)
Related bugs:
  Bug #899776 in Launchpad itself: "Distribution:+bugs timeout searching by component universe"
  https://bugs.launchpad.net/launchpad/+bug/899776

For more details, see:
https://code.launchpad.net/~wgrant/launchpad/bug-899776-index/+merge/103821

The changes in https://code.launchpad.net/~wgrant/launchpad/bug-899776/+merge/103806 rely on a new index in order to be really fast. https://pastebin.canonical.com/65104/ is the query and plan from dogfood, with this index as temp_spph.
-- 
https://code.launchpad.net/~wgrant/launchpad/bug-899776-index/+merge/103821
Your team Launchpad code reviewers is subscribed to branch lp:launchpad.
=== added file 'database/schema/patch-2209-16-2.sql'
--- database/schema/patch-2209-16-2.sql	1970-01-01 00:00:00 +0000
+++ database/schema/patch-2209-16-2.sql	2012-04-27 07:39:46 +0000
@@ -0,0 +1,12 @@
+-- Copyright 2012 Canonical Ltd.  This software is licensed under the
+-- GNU Affero General Public License version 3 (see the file LICENSE).
+
+SET client_min_messages=ERROR;
+
+CREATE INDEX
+    sourcepackagepublishinghistory__archive__distroseries__component__spn__idx
+    ON sourcepackagepublishinghistory
+    USING btree (archive, distroseries, component, sourcepackagename)
+    WHERE status IN (1, 2);
+
+INSERT INTO LaunchpadDatabaseRevision VALUES (2209, 16, 2);


Follow ups