aboutsummaryrefslogtreecommitdiff
path: root/sqitch/sqlite/deploy
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2020-05-10 18:27:56 +0100
committerChristopher Baines <mail@cbaines.net>2020-05-10 18:27:56 +0100
commitbd7e7e76803a6c9d85a392c321839f83160d20f8 (patch)
treeed460474992fb177da67520b4d154bbeb5e238fb /sqitch/sqlite/deploy
parent78ed59c7292d57906f0539d7e2df5962dcb45d38 (diff)
downloadbuild-coordinator-bd7e7e76803a6c9d85a392c321839f83160d20f8.tar
build-coordinator-bd7e7e76803a6c9d85a392c321839f83160d20f8.tar.gz
Replace datastore-fetch-input-builds-for-unprocessed-builds
It worked under some database conditions, but was very slow under others. Move more of the logic in to SQL in an attempt to make the allocator faster. This sort of works, but there were some advantages to the approach before the approach being replaced in this commit.
Diffstat (limited to 'sqitch/sqlite/deploy')
-rw-r--r--sqitch/sqlite/deploy/build_results_result_index.sql7
1 files changed, 7 insertions, 0 deletions
diff --git a/sqitch/sqlite/deploy/build_results_result_index.sql b/sqitch/sqlite/deploy/build_results_result_index.sql
new file mode 100644
index 0000000..00dfe33
--- /dev/null
+++ b/sqitch/sqlite/deploy/build_results_result_index.sql
@@ -0,0 +1,7 @@
+-- Deploy guix-build-coordinator:build_results_result_index to sqlite
+
+BEGIN;
+
+CREATE INDEX build_results_result_idx ON build_results (result);
+
+COMMIT;