hydra/src/sql
Antoine Eiche 8a0a5ec3a3 Create extension pg_trgm in the NixOS module
The creation of the `pg_trgm` extension needs superuser power. So,
this patch makes the extension creation in the Hydra NixOS module when
a local database is used.

If it is not possible to create this extension (remote database for
instance with nosuperuser), the creation of the `pg_trgm` index is
skipped (this index speedup queries on builds.drvpath) and warnings
are emitted:

    initialising the Hydra database schema...
    WARNING:  Can not create extension pg_trgm: permission denied to create extension "pg_trgm"
    WARNING:  HINT: Temporary provide superuser role to your Hydra Postgresql user and run the script src/sql/upgrade-57.sql
    WARNING:  The pg_trgm index on builds.drvpath has been skipped (slower complex queries on builds.drvpath)

This allows to keep smooth migrations: the migration process doesn't
require a manual step (but this manual step is recommended on big
remote databases).
2019-07-25 16:19:33 +02:00
..
hydra.sql Create extension pg_trgm in the NixOS module 2019-07-25 16:19:33 +02:00
Makefile.am Use latest DBIx::Class::Schema::Loader 2015-07-30 16:55:11 +02:00
test.sql * Move everything up one directory. 2009-03-05 13:41:57 +00:00
update-dbix.pl Use latest DBIx::Class::Schema::Loader 2015-07-30 16:55:11 +02:00
upgrade-2.sql Remove trailing whitespace 2013-01-22 14:41:02 +01:00
upgrade-3.sql Speed up hydra-update-gc-roots 2012-03-12 20:47:29 +01:00
upgrade-4.sql Evaluator cleanups 2012-03-12 20:47:29 +01:00
upgrade-5.sql Drop unused "tag" column 2012-04-15 12:42:46 +00:00
upgrade-6.sql Remove trailing whitespace 2013-01-22 14:41:02 +01:00
upgrade-7.sql Speed up the listing of jobset evals by caching some info in the DB 2012-04-16 00:46:19 +02:00
upgrade-8.sql Add missing file 2013-01-23 12:49:44 +01:00
upgrade-9.sql Add missing files 2013-02-14 11:53:09 +01:00
upgrade-10.sql Support push notification of repository changes 2013-02-25 21:10:32 +01:00
upgrade-11.sql Remove the BuildMachines and BuildMachinesSystemTypes tables 2013-03-04 16:32:16 -05:00
upgrade-12.sql Allow a per-jobset check interval 2013-05-02 17:55:47 +02:00
upgrade-13.sql Allow a per-jobset check interval 2013-05-02 17:55:47 +02:00
upgrade-14.sql Drop unused "disabled" columns 2013-05-03 16:39:17 +02:00
upgrade-15.sql Ensure that stoptime and starttime are set for finished builds 2013-05-23 12:05:12 -04:00
upgrade-16.sql Remove unused Jobs columns 2013-05-23 12:12:19 -04:00
upgrade-17.sql Materialize the number of finished builds 2013-08-12 20:19:10 +02:00
upgrade-18.sql Index builds on stop time 2013-08-12 20:19:10 +02:00
upgrade-19.sql Rename aggregate members to constituents 2013-08-15 02:33:10 +02:00
upgrade-20.sql Fix the Darcs schema upgrade 2013-09-19 12:00:29 +00:00
upgrade-21.sql hydra-queue-runner: Improved scheduling 2013-09-21 14:57:01 +00:00
upgrade-22.sql Distinguish between permanent evaluation errors and transient input errors 2013-09-25 16:21:16 +02:00
upgrade-23.sql Add a dashboard 2013-10-14 20:07:26 +02:00
upgrade-24.sql Merge remote-tracking branch 'upstream/who-broke-builds' into upstream-master 2013-10-15 09:49:20 -04:00
upgrade-25.sql Store the account type ("hydra" or "persona") explicitly in the database 2013-11-05 11:46:05 +01:00
upgrade-26.sql When renaming a jobset, add a redirect from the old name 2014-04-23 23:15:22 +02:00
upgrade-27.sql Remove support for views 2014-04-23 23:22:44 +02:00
upgrade-28.sql Drop the errorMsg column in the Jobs table 2014-09-29 19:46:11 +02:00
upgrade-29.sql Get rid of some obsolete indexes 2014-09-30 15:44:08 +02:00
upgrade-30.sql Use partial indexes 2014-09-30 15:44:08 +02:00
upgrade-31.sql Remove the longDescription field 2014-09-30 15:44:09 +02:00
upgrade-32.sql Record which build a failed build step was propagated from 2015-02-25 16:42:32 +01:00
upgrade-33.sql Add forgotten file 2015-06-17 21:39:28 +02:00
upgrade-34.sql Add command ‘hydra-queue-runner --status’ to show current status 2015-06-22 14:06:44 +02:00
upgrade-35.sql Use triggers for all notifications on Builds table changes 2015-07-08 12:05:32 +02:00
upgrade-36.sql Index BuildSteps on propagatedFrom 2015-07-08 12:12:44 +02:00
upgrade-37.sql Add page showing latest build steps 2015-07-10 15:41:57 +02:00
upgrade-38.sql IndexJobsetEvalsOnJobsetId: Only index jobsets with new builds 2015-07-10 15:41:57 +02:00
upgrade-39.sql Add support for tracking custom metrics 2015-07-31 00:57:30 +02:00
upgrade-40.sql Allow build to be bumped to the front of the queue via the web interface 2015-08-10 16:19:47 +02:00
upgrade-41.sql Tweak 2015-10-16 16:59:07 +02:00
upgrade-42.sql Add isChannel column and meta attribute. 2015-09-10 17:36:38 +02:00
upgrade-43.sql Ignore non-existence of IndexBuildsOnFinishedBusy 2015-10-28 14:09:45 +01:00
upgrade-44.sql Remove the errorMsg column from the Builds table 2016-02-12 17:21:55 +01:00
upgrade-45.sql Keep track of the time we spend copying to/from build machines 2016-02-17 10:30:23 +01:00
upgrade-46.sql Unify build and step status codes 2016-03-09 15:30:43 +01:00
upgrade-47.sql Drop unused BuildProducts.description column 2016-04-13 16:30:52 +02:00
upgrade-48.sql Enable declarative projects. 2016-05-09 08:54:27 -04:00
upgrade-49.sql Allow public dashboards 2016-05-27 14:35:32 +02:00
upgrade-50.sql Fix SQL syntax for migration 50. It failed with PostgreSQL 9.4. (#416) 2016-12-09 18:18:17 +01:00
upgrade-51.sql When manually scheduling an eval, force re-instantiation of store derivations 2016-10-24 20:20:20 +02:00
upgrade-52.sql Allow determinism checking for entire jobsets 2016-12-07 15:57:13 +01:00
upgrade-53.sql hydra-evaluator improvements 2017-03-15 16:59:57 +01:00
upgrade-54.sql Fix a race that can cause hydra-queue-runner to ignore newly added builds 2017-07-21 14:34:48 +02:00
upgrade-55.sql hydra-queue-runner: Make build notification more reliable 2017-07-26 15:17:51 +02:00
upgrade-56.sql Distinguish build step states 2017-12-07 15:35:31 +01:00
upgrade-57.sql Create extension pg_trgm in the NixOS module 2019-07-25 16:19:33 +02:00