This:
- documents what this method is about in the code (only in documentation so far)
- adds a missing test on the cli `swh db version` to check this behaves appropriately
- will allow to clean up duplicated code in existing backends (storage, indexer) [2] [3]
- will allow to fix the backends which are missing the appropriate methods (scrubber,scheduler
scheduler[4], vaultscrubber, see [1]'s descriptionvault, see [1]'s description for details...)
Related to T4228
Depends on D7943 (revert of [1])
This is the proper fix instead of [1].
[1] D7907.
[2] https://forge.softwareheritage.org/source/swh-storage/browse/master/swh/storage/postgresql/storage.py$208-211
[3] https://forge.softwareheritage.org/source/swh-indexer/browse/master/swh/indexer/storage/__init__.py$155-157
[4] https://forge.softwareheritage.org/source/swh-scheduler/browse/master/swh/scheduler/backend.py$76-78