Some hacks to get the cache working with postres