summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2015-03-10 02:13:40 +0100
committerHolger Levsen <holger@layer-acht.org>2015-03-10 02:13:40 +0100
commitf981271026761bb30fa05a2c754085b8e448f702 (patch)
treecde5ca1e9dc50480e7a895da25b270fd4c647ed1 /bin
parentfbfcc79c517c899bedb3eb96a1fc130351921eb5 (diff)
downloadjenkins.debian.net-f981271026761bb30fa05a2c754085b8e448f702.tar.xz
reproducible: db schema 8: add default value to stats_bugs to get a full 'done vs open bugs' graph
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_db_maintenance.py36
1 files changed, 36 insertions, 0 deletions
diff --git a/bin/reproducible_db_maintenance.py b/bin/reproducible_db_maintenance.py
index 74fd8e91..a2fc1149 100755
--- a/bin/reproducible_db_maintenance.py
+++ b/bin/reproducible_db_maintenance.py
@@ -293,6 +293,42 @@ schema_updates = {
'DROP TABLE results',
'ALTER TABLE results_tmp RENAME TO results',
'INSERT INTO rb_schema VALUES ("7", "' + now + '")'],
+ 8: [ # add default value to stats_bugs to get a full 'done vs open bugs' graph
+ '''CREATE TABLE stats_bugs_tmp
+ (datum TEXT NOT NULL,
+ open_toolchain INTEGER DEFAULT '0',
+ done_toolchain INTEGER DEFAULT '0',
+ open_infrastructure INTEGER DEFAULT '0',
+ done_infrastructure INTEGER DEFAULT '0',
+ open_timestamps INTEGER DEFAULT '0',
+ done_timestamps INTEGER DEFAULT '0',
+ open_fileordering INTEGER DEFAULT '0',
+ done_fileordering INTEGER DEFAULT '0',
+ open_buildpath INTEGER DEFAULT '0',
+ done_buildpath INTEGER DEFAULT '0',
+ open_username INTEGER DEFAULT '0',
+ done_username INTEGER DEFAULT '0',
+ open_hostname INTEGER DEFAULT '0',
+ done_hostname INTEGER DEFAULT '0',
+ open_uname INTEGER DEFAULT '0',
+ done_uname INTEGER DEFAULT '0',
+ open_randomness INTEGER DEFAULT '0',
+ done_randomness INTEGER DEFAULT '0',
+ open_buildinfo INTEGER DEFAULT '0',
+ done_buildinfo INTEGER DEFAULT '0',
+ open_cpu INTEGER DEFAULT '0',
+ done_cpu INTEGER DEFAULT '0',
+ open_signatures INTEGER DEFAULT '0',
+ done_signatures INTEGER DEFAULT '0',
+ open_environment INTEGER DEFAULT '0',
+ one_environment INTEGER DEFAULT '0',
+ open_umask INTEGER DEFAULT '0',
+ done_umask INTEGER DEFAULT '0',
+ PRIMARY KEY (datum))''',
+ 'INSERT INTO stats_bugs_tmp SELECT * FROM stats_bugs',
+ 'DROP TABLE stats_bugs',
+ 'ALTER TABLE stats_bugs_tmp RENAME TO stats_bugs',
+ 'INSERT INTO rb_schema VALUES ("8", "' + now + '")'],
}