hook into activerecord at lower level to benefit from its caching behavior