We need a way to do integration tests of the vault, and integrate them with monitoring+QA. It's not trivial to do so because we need a way to invalidate the vault cache everytime we cook the test object.
Description
Description
Event Timeline
Comment Actions
We want to test the end-to-end functionalities of the vault. Various use cases should hence be tested:
- requesting cooking of an object not in cache (this is the hard part @seirl was referring to)
- requesting the download of an object in cache (this is easier, but should be tested nonetheless)
- requesting the download of an object not in cache
- requesting what's the current status of an object being cooked (or already done, or never requested)
a way to make it (1) simpler might be to have a blacklist of objects that should never be cached, for instance, a specific snapshot and/or dir of our helloworld repo
Comment Actions
It would also be possible to add a parameter to force the recooking of an object, which would be more flexible to do a variety of tests on random "known" objects. This might require some thought about whether that would be a public option or not, and if not, how we would restrict its access.
Comment Actions
We have an icinga plugin implementing some of this: https://forge.softwareheritage.org/source/swh-icinga-plugins/browse/master/swh/icinga_plugins/vault.py