Those scripts [1] [2] rework the revision to set correctly the default values on fields:
- date_neg_utc_offset
- committer_date_neg_utc_offset
- extra_headers
(same goes for release on other field but this is done as their volume is small
enough compared to revision)
The end goal is to enforce those default values with constraints.
Extra optimization work has been done so the migration passes smoothly (cache
reuse, no replication problem, one vacuum trigger and not 3) [3]
This is currently running on belvedere [4]
The workers are still running alongside.
[1] https://forge.softwareheritage.org/source/swh-storage/browse/master/sql/upgrades/160.sql
[2] https://forge.softwareheritage.org/source/swh-storage/browse/master/sql/upgrades/161.sql
[3] P747
[4] those scripts can be interrupted and rerun if needed:
postgres@belvedere $ psql -p 5433 softwareheritage > \i 160-v4.1.sql ... postgres@belvedere $ psql -p 5433 softwareheritage > \i 160-v4.2.sql ... postgres@belvedere $ psql -p 5433 softwareheritage > \i 160-v4.3.sql