Uniter context reinstate settings caches

So, a few PRs ago I broke relation settings caching. This reinstates it, but under the aegis of the context factory rather than the Uniter.

It's not yet finished, because I need to gut and rewrite all the relation-based tests in the context package, *but* all the uniter tests are passing again and I'd like a pre-review of the logic while I work on the tests, so I can get this merged (ie fixed) ASAP.