launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #23726
[Merge] lp:~cjwatson/launchpad/db-livefs-keep-binary-files-interval into lp:launchpad/db-devel
Colin Watson has proposed merging lp:~cjwatson/launchpad/db-livefs-keep-binary-files-interval into lp:launchpad/db-devel.
Commit message:
Add LiveFS.keep_binary_files_interval column.
Requested reviews:
Stuart Bishop (stub): db
Launchpad code reviewers (launchpad-reviewers): db
Related bugs:
Bug #1832477 in Launchpad itself: "Allow configuring binary file retention period for live filesystems"
https://bugs.launchpad.net/launchpad/+bug/1832477
For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/db-livefs-keep-binary-files-interval/+merge/368702
I just set the default for the new column directly here, since there are only around 400 LiveFS rows on production.
https://code.launchpad.net/~cjwatson/launchpad/livefs-keep-binary-files-interval/+merge/368703 is the corresponding code change.
--
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~cjwatson/launchpad/db-livefs-keep-binary-files-interval into lp:launchpad/db-devel.
=== added file 'database/schema/patch-2210-04-0.sql'
--- database/schema/patch-2210-04-0.sql 1970-01-01 00:00:00 +0000
+++ database/schema/patch-2210-04-0.sql 2019-06-12 10:00:38 +0000
@@ -0,0 +1,10 @@
+-- Copyright 2019 Canonical Ltd. This software is licensed under the
+-- GNU Affero General Public License version 3 (see the file LICENSE).
+
+SET client_min_messages=ERROR;
+
+ALTER TABLE LiveFS ADD COLUMN keep_binary_files_interval interval DEFAULT interval '1 day';
+
+COMMENT ON COLUMN LiveFS.keep_binary_files_interval IS 'Keep binary files attached to builds of this live filesystem for at least this long.';
+
+INSERT INTO LaunchpadDatabaseRevision VALUES (2210, 04, 0);