[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
05/06: Add an index for derivation_sources.derivation_source_file_id
From: |
Christopher Baines |
Subject: |
05/06: Add an index for derivation_sources.derivation_source_file_id |
Date: |
Fri, 2 Oct 2020 15:15:40 -0400 (EDT) |
cbaines pushed a commit to branch master
in repository data-service.
commit e2a7705d3d01c992c0dfed6363388246b5bd69dc
Author: Christopher Baines <mail@cbaines.net>
AuthorDate: Fri Oct 2 20:13:28 2020 +0100
Add an index for derivation_sources.derivation_source_file_id
As this speeds up deleting derivation_source_files.
---
.../add_derivation_sources_derivation_source_file_id_index.sql | 8 ++++++++
.../add_derivation_sources_derivation_source_file_id_index.sql | 7 +++++++
sqitch/sqitch.plan | 1 +
.../add_derivation_sources_derivation_source_file_id_index.sql | 7 +++++++
4 files changed, 23 insertions(+)
diff --git
a/sqitch/deploy/add_derivation_sources_derivation_source_file_id_index.sql
b/sqitch/deploy/add_derivation_sources_derivation_source_file_id_index.sql
new file mode 100644
index 0000000..2665f02
--- /dev/null
+++ b/sqitch/deploy/add_derivation_sources_derivation_source_file_id_index.sql
@@ -0,0 +1,8 @@
+-- Deploy
guix-data-service:add_derivation_sources_derivation_source_file_id_index to pg
+
+BEGIN;
+
+CREATE INDEX derivation_sources_derivation_source_file_id_idx
+ON derivation_sources (derivation_source_file_id);
+
+COMMIT;
diff --git
a/sqitch/revert/add_derivation_sources_derivation_source_file_id_index.sql
b/sqitch/revert/add_derivation_sources_derivation_source_file_id_index.sql
new file mode 100644
index 0000000..2d7b84f
--- /dev/null
+++ b/sqitch/revert/add_derivation_sources_derivation_source_file_id_index.sql
@@ -0,0 +1,7 @@
+-- Revert
guix-data-service:add_derivation_sources_derivation_source_file_id_index from pg
+
+BEGIN;
+
+-- XXX Add DDLs here.
+
+COMMIT;
diff --git a/sqitch/sqitch.plan b/sqitch/sqitch.plan
index 09df4bb..abb27fd 100644
--- a/sqitch/sqitch.plan
+++ b/sqitch/sqitch.plan
@@ -71,3 +71,4 @@ change_package_descriptions_index 2020-08-23T11:56:00Z
Christopher Baines <mail@
change_locale_values 2020-09-26T10:20:22Z Christopher Baines
<mail@cbaines.net> # Change locale values
change_autovacuum_config 2020-10-01T21:24:46Z Christopher Baines
<mail@cbaines.net> # Change autovacuum config
change_derivation_source_file_nars_constraint 2020-10-02T17:12:58Z Christopher
Baines <mail@cbaines.net> # Change derivation source file nars constraint
+add_derivation_sources_derivation_source_file_id_index 2020-10-02T19:11:59Z
Christopher Baines <mail@cbaines.net> # Add
derivation_sources.derivation_source_file_id index
diff --git
a/sqitch/verify/add_derivation_sources_derivation_source_file_id_index.sql
b/sqitch/verify/add_derivation_sources_derivation_source_file_id_index.sql
new file mode 100644
index 0000000..ab099e8
--- /dev/null
+++ b/sqitch/verify/add_derivation_sources_derivation_source_file_id_index.sql
@@ -0,0 +1,7 @@
+-- Verify
guix-data-service:add_derivation_sources_derivation_source_file_id_index on pg
+
+BEGIN;
+
+-- XXX Add verifications here.
+
+ROLLBACK;
- branch master updated (6e0e33a -> 470573b), Christopher Baines, 2020/10/02
- 02/06: Reformat lint warning related query, Christopher Baines, 2020/10/02
- 01/06: Speed up a query for derivation builds, Christopher Baines, 2020/10/02
- 05/06: Add an index for derivation_sources.derivation_source_file_id,
Christopher Baines <=
- 04/06: Make with-postgresql-connection work with multiple values, Christopher Baines, 2020/10/02
- 06/06: Delete derivation_source_files that are unreferenced, Christopher Baines, 2020/10/02
- 03/06: Change a constraint to add ON DELETE CASCADE, Christopher Baines, 2020/10/02