From 0f639021d0ad354e322695e7a005a5ccf1e857a4 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 29 Nov 2011 17:07:37 +0100 Subject: [PATCH] Add an index to speed up the /project/ pages --- src/sql/hydra.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sql/hydra.sql b/src/sql/hydra.sql index 7982f73e..3feece9e 100644 --- a/src/sql/hydra.sql +++ b/src/sql/hydra.sql @@ -517,7 +517,6 @@ create index IndexBuildInputsOnBuild on BuildInputs(build); create index IndexBuildInputsOnDependency on BuildInputs(dependency); create index IndexBuildProducstOnBuildAndType on BuildProducts(build, type); create index IndexBuildProductsOnBuild on BuildProducts(build); -create index IndexBuildResultInfo on BuildResultInfo(id); -- primary key index, not created automatically by PostgreSQL create index IndexBuildSchedulingInfoOnBuild on BuildSchedulingInfo(id); -- idem create index IndexBuildStepsOnBuild on BuildSteps(build); create index IndexBuildStepsOnDrvpathTypeBusyStatus on BuildSteps(drvpath, type, busy, status); @@ -525,6 +524,7 @@ create index IndexBuildStepsOnOutpath on BuildSteps(outpath); create index IndexBuildStepsOnOutpathBuild on BuildSteps (outpath, build); create index IndexBuildsOnFinished on Builds(finished); create index IndexBuildsOnIsCurrent on Builds(isCurrent); +create index IndexBuildsOnJobsetIsCurrent on Builds(project, jobset, isCurrent); --create index IndexBuildsOnJob on Builds(project, jobset, job); --create index IndexBuildsOnJobAndIsCurrent on Builds(project, jobset, job, isCurrent); create index IndexBuildsOnJobAndSystem on Builds(project, jobset, job, system);