Create extension to cache pyramid_royal REST resources

It's quite noisy code and probably coupled quite closely to royal, but it doesn't doesn't need any change to royal. If we do find a way to make royal easier to extend, this could be simplified quite a lot.