[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[OSSTEST PATCH v2 31/41] schema: Add index to help cs-bisection-step



cs-bisection step basis search involves looking for recent flights
that weren't broken.  A flight is broken if it has broken steps.
Make an index for this to save it scanning the steps table.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 schema/steps-broken-index.sql | 7 +++++++
 1 file changed, 7 insertions(+)
 create mode 100644 schema/steps-broken-index.sql

diff --git a/schema/steps-broken-index.sql b/schema/steps-broken-index.sql
new file mode 100644
index 00000000..770747cc
--- /dev/null
+++ b/schema/steps-broken-index.sql
@@ -0,0 +1,7 @@
+-- ##OSSTEST## 010 Harmless
+--
+-- This index helps cs-bisection-flight check if flighss are broken.
+
+CREATE INDEX steps_broken_idx
+    ON steps (flight)
+ WHERE status='broken';
-- 
2.20.1




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.